Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Create a Reset exception class so we can work with it.
- # It would otherwise first be declared when F12 is pressed
- class Reset < Exception; end
- # Check if the last exception is a Reset exception
- if $!.is_a?(Reset)
- # Name of the game executable (game.exe, game.ini, game.rgssad)
- command = 'Game'
- # Add command line argument so the debug capabilities are kept in Test play
- command += ' debug' if $DEBUG # XP
- command += ' test' if $TEST # VX
- # Opens the game executable in a new thread
- Thread.new{system command}
- # Exits this thread
- exit
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement