souldragon19
Member
I'm a newbie at RGSS, I've been looking over the terms and such, but I don't think I understand them fully.
I was trying to script a small script that would Open up a menu, when I pressed a certain key.
When I went in-game, and pressed the button, the menu didn't show. Can anyone help me with the problem? Here's the code.
I was trying to script a small script that would Open up a menu, when I pressed a certain key.
When I went in-game, and pressed the button, the menu didn't show. Can anyone help me with the problem? Here's the code.
Code:
#-------------------------------------------------------------------------------
# I wanna Script
#-------------------------------------------------------------------------------
class Scene_Window
#-------------------------------------------------------------------------------
# Define the Menu's
#-------------------------------------------------------------------------------
def initialize(menu_index = 0)
@menu_index = menu_index
end
#-------------------------------------------------------------------------------
def main
s1 = "I"
s2 = "Wanna"
s3 = "SCRIPT"
@command_window = Window_Command.new(160, [s1, s2, s3,])
@command_window.index = @menu_index
@command_window.dispose
end
#----------------------------------------------------------------------------
def update
# Update windows
@command_window.update
# If command window is active: call update_command
if @command_window.active
update_command
return
end
#---------------------------------------------------------------------------
def update_command
if Input.trigger?(Input::J)
$game_system.se_play($data_system.cancel_se)
$scene = Scene_Window.new
return
end
end
end
end