End Scene call with direct hotkey [resolved]

Started by ojp2010, August 30, 2010, 05:07:11 pm

Previous topic - Next topic

ojp2010

August 30, 2010, 05:07:11 pm Last Edit: September 01, 2010, 09:51:37 pm by ojp2010
I am using a Mouse Map Menu script to call scenes from the map with direct hotkeys, however, I can't close the scenes and return to the Map_Scene. I know that I will need to edit the Scene scripts to be able to close with direct hotkeys. Can anyone point me in the right direction in and where in the script I should edit that in? I don't want to play around with RMX default scripts without knowing exactly what and where I need to edit and change. Thank you for any help.  

cyclope

August 30, 2010, 06:59:23 pm #1 Last Edit: August 30, 2010, 07:03:50 pm by cyclope
look in the scenes where it says Scene_Menu and change it to Scene_Map. exammple: in Scene_Equip in line 148 it says this
          $scene = Scene_Menu.new(2)
change it to
          $scene = Scene_Map.new
Things I Hate

1. People who point at their wrist asking for the time... I know where my watch is pal, where the hell is yours? Do I point at my crotch when I ask where the toilet is?

2. People who are willing to get off their a** to search the entire room for the TV remote because they refuse to walk to the TV and change the channel manually.

3. When people say "Oh you just want to have your cake and eat it too". Damn Right! What good is cake if you can't eat it?

4. When people say "it's always the last place you look". Of course it is. Why the hell would you keep looking after you've found it? Do people do this? Who and where are they?

5. When people say while watching a film, "did ya see that?" No Loser, I paid $12 to come to the cinema and stare at the damn floor!

6. People who ask "Can I ask you a question?"... Didn't give me a choice there, did ya sunshine?

ojp2010

Quote from: cyclope on August 30, 2010, 06:59:23 pm
look in the scenes where it says Scene_Menu and change it to Scene_Map. exammple: in Scene_Equip in line 148 it says this
          $scene = Scene_Menu.new(2)
change it to
          $scene = Scene_Map.new



I did that, I am sorry I don't believe my explanation was clear. I want to be able to close the scene with a direct hotkey like a player has Scene_Item open and hit 'I' and the scene closes and returns them to the scene_map. Sorry that I wasn't to clear before.

Wizered67

look for the line
if Input.trigger?(Input::B)

in Scene_Item and change it to
if Input.trigger?(Input::Key['I'])


That should do the trick.

ojp2010

Quote from: Wizered67 on August 30, 2010, 09:00:35 pm
look for the line
if Input.trigger?(Input::B)

in Scene_Item and change it to
if Input.trigger?(Input::Key['I'])


That should do the trick.


I am getting an error when I do that, although the screen does flash to the Scene for like 1 second before bugging out. I am using Mouse Map Menu Script, which has a direct hotkey call scene ability which I am using to call the scenes, but it doesn't close them.

Spoiler: ShowHide


Wizered67

Did you use the exact line I posted and NOT Input.trigger?(Input::I)? (You have to put the Key['I'])

ojp2010

Quote from: Wizered67 on August 30, 2010, 10:38:51 pm
Did you use the exact line I posted and NOT Input.trigger?(Input::I)? (You have to put the Key['I'])


I did:(

Spoiler: ShowHide
Quoteend
  #--------------------------------------------------------------------------
  # * Frame Update (when item window is active)
  #--------------------------------------------------------------------------
  def update_item
    # If B button was pressed
    if Input.trigger?(Input::['I'])
      # Play cancel SE
      $game_system.se_play($data_system.cancel_se)
      # Switch to menu screen
      $scene = Scene_Map.new
      return
    end


Spoiler: ShowHide



Wizered67

Your forgetting the Key infront of it. It shoudl be Input.trigger?(Input::Key['I'])

ojp2010

Quote from: Wizered67 on August 31, 2010, 12:03:45 am
Your forgetting the Key infront of it. It shoudl be Input.trigger?(Input::Key['I'])


fu(k m3 :/ thanks. O.o