Main Menu
  • Welcome to The RPG Maker Resource Kit.

A little help ? [RESOLVED] =D

Started by Snailer, April 01, 2007, 05:25:16 PM

0 Members and 1 Guest are viewing this topic.

Snailer

HEllo !!
I just did some modification to the menu in RMXP but i have a black stroke at the side and I am wondering if i could make it transparent with some script so I can see my game behind my menu :D
Any help much appreciated :D

Its in regular Rpg maker XP not PK edition

Falcon

Use:
@spriteset = $Spriteset_Map.new

Or something similar to that.

Snailer

#2
I dont need the sprite I mean that i can see the map behind my menu

WAit..
WHY WAS THIS IN SPAM !?
I am 100% sure i posted it in Scipts :S
Someone messing with posts :D ?

:)

Watch out for: HaloOfTheSun

Snailer

April fools is so confusing me !
Anyway Someone can help me ?

Falcon

Clearly you have no idea how the fuck Ruby works, I do, @spriteset = Spriteset_Map.new is the code you want.

Snailer

Where do I put it ?
Because it doesnt work

Falcon

Main I believe.

Just check another CMSs code to find it if that doesn't work.

Snailer

No doesnt work Either..
And checking a CMS is not very helpful also because its thrown together with other codes and i cant figure it out
Can someone help me ? :(

Snailer


modern algebra

No, somebody does have the code. That person's name is Darklord. @spriteset = $Spriteset_Map.new is the correct code. I am not a talented scripter, but if you put that under def main in your menu script, it ought to work.

Snailer

I have tryd to put it everywhere but it doesnt work :(

Irock

Well, it has to go somewhere. Darklord makes custom menu systems, you know.

modern algebra

Quote from: Snailer on April 02, 2007, 04:28:42 PM
I have tryd to put it everywhere but it doesnt work :(

That's simply not true. Upload your script and I will put it in if you like.

Snailer

Alright.


#==============================================================================
# ** Scene_Menu
#------------------------------------------------------------------------------
#  This class performs menu screen processing.
#==============================================================================

class Scene_Menu
  #--------------------------------------------------------------------------
  # * Object Initialization
  #     menu_index : command cursor's initial position
  #--------------------------------------------------------------------------
  def initialize(menu_index = 0)  # 0
    @menu_index = menu_index
  end
  #--------------------------------------------------------------------------
  # * Main Processing
  #--------------------------------------------------------------------------
  def main
    # Make command window
    s1 = $data_system.words.item
    s2 = $data_system.words.skill
    s3 = $data_system.words.equip
    s4 = "Status"
    s5 = "Save"
    s6 = "End Game"
    @command_window = Window_Command.new(160, [s1, s2, s3, s4, s5, s6])
    @command_window.x = 15
    @command_window.y = 230
    @command_window.index = @menu_index
    # If number of party members is 0
    if $game_party.actors.size == 0
      # Disable items, skills, equipment, and status
      @command_window.disable_item(0)
      @command_window.disable_item(1)
      @command_window.disable_item(2)
      @command_window.disable_item(3)
    end
    # If save is forbidden
    if $game_system.save_disabled
      # Disable save
      @command_window.disable_item(4)
    end
    # Make play time window
    @playtime_window = Window_PlayTime.new
    @playtime_window.x = 300  # 0
    @playtime_window.y = 240
    # Make steps window
    @steps_window = Window_Steps.new
    @steps_window.x = 300 # 0
    @steps_window.y = 320
    # Make gold window
    @gold_window = Window_Gold.new
    @gold_window.x = 300 # 0
    @gold_window.y = 416
    # Make status window
    @status_window = Window_MenuStatus.new
    @status_window.x = 0 # 160
    @status_window.y = 0 #0
    # Execute transition
    Graphics.transition
    # Main loop
    loop do
      # Update game screen
      Graphics.update
      # Update input information
      Input.update
      # Frame update
      update
      # Abort loop if screen is changed
      if $scene != self
        break
      end
    end
    # Prepare for transition
    Graphics.freeze
    # Dispose of windows
    @command_window.dispose
    @playtime_window.dispose
    @steps_window.dispose
    @gold_window.dispose
    @status_window.dispose
  end
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update
    # Update windows
    @command_window.update
    @playtime_window.update
    @steps_window.update
    @gold_window.update
    @status_window.update
    # If command window is active: call update_command
    if @command_window.active
      update_command
      return
    end
    # If status window is active: call update_status
    if @status_window.active
      update_status
      return
    end
  end
  #--------------------------------------------------------------------------
  # * Frame Update (when command window is active)
  #--------------------------------------------------------------------------
  def update_command
    # If B button was pressed
    if Input.trigger?(Input::B)
      # Play cancel SE
      $game_system.se_play($data_system.cancel_se)
      # Switch to map screen
      $scene = Scene_Map.new
      return
    end
    # If C button was pressed
    if Input.trigger?(Input::C)
      # If command other than save or end game, and party members = 0
      if $game_party.actors.size == 0 and @command_window.index < 4
        # Play buzzer SE
        $game_system.se_play($data_system.buzzer_se)
        return
      end
      # Branch by command window cursor position
      case @command_window.index
      when 0  # item
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Switch to item screen
        $scene = Scene_Item.new
      when 1  # skill
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Make status window active
        @command_window.active = false
        @status_window.active = true
        @status_window.index = 0
      when 2  # equipment
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Make status window active
        @command_window.active = false
        @status_window.active = true
        @status_window.index = 0
      when 3  # status
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Make status window active
        @command_window.active = false
        @status_window.active = true
        @status_window.index = 0
      when 4  # save
        # If saving is forbidden
        if $game_system.save_disabled
          # Play buzzer SE
          $game_system.se_play($data_system.buzzer_se)
          return
        end
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Switch to save screen
        $scene = Scene_Save.new
      when 5  # end game
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Switch to end game screen
        $scene = Scene_End.new
      end
      return
    end
  end
  #--------------------------------------------------------------------------
  # * Frame Update (when status window is active)
  #--------------------------------------------------------------------------
  def update_status
    # If B button was pressed
    if Input.trigger?(Input::B)
      # Play cancel SE
      $game_system.se_play($data_system.cancel_se)
      # Make command window active
      @command_window.active = true
      @status_window.active = false
      @status_window.index = -1
      return
    end
    # If C button was pressed
    if Input.trigger?(Input::C)
      # Branch by command window cursor position
      case @command_window.index
      when 1  # skill
        # If this actor's action limit is 2 or more
        if $game_party.actors[@status_window.index].restriction >= 2
          # Play buzzer SE
          $game_system.se_play($data_system.buzzer_se)
          return
        end
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Switch to skill screen
        $scene = Scene_Skill.new(@status_window.index)
      when 2  # equipment
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Switch to equipment screen
        $scene = Scene_Equip.new(@status_window.index)
      when 3  # status
        # Play decision SE
        $game_system.se_play($data_system.decision_se)
        # Switch to status screen
        $scene = Scene_Status.new(@status_window.index)
      end
      return
    end
  end
end



modern algebra

Oh? Sorry, my bad. The code is @spriteset = Spriteset_Map.new, it doesn't have the $  :-[

Anyway, just put it in at line 19, right under def main. Also, you might want to change the x position of your command window or something. It's underneath the main part of the menu.

Snailer

Thanks alot !
Ima + rep you :D

And also I'm only going to have 2 party members in this game so it wont need anything major change
Also I will try to set the X to something nice :D

Thanks again !

:)

Solved? Add [RESOLVED] to topic title
Watch out for: HaloOfTheSun