StudioBlue
Sponsor
So not really super-custom, more like additions to the Scene and Update methods:
Two problems.
First, when I choose "Load Game", the game keeps playing the Gameover ME when the loaded map loads. Is there a way around that?
Second, does anyone know of a good way to 'Continue', where-in the player is restored to a location of MapID, X, and Y, facing down and with the correct music, etc playing? I will store the MapID, X, and Y in three different variables.
Thanks in advance!
Code:
#==============================================================================
# ** Scene_Gameover
#------------------------------------------------------------------------------
# This class performs game over screen processing.
#==============================================================================
class Scene_Gameover
#--------------------------------------------------------------------------
# * Main Processing
#--------------------------------------------------------------------------
def main
# Make game over graphic
@sprite = Sprite.new
@sprite.bitmap = RPG::Cache.gameover($data_system.gameover_name)
# Stop BGM and BGS
$game_system.bgm_play(nil)
$game_system.bgs_play(nil)
# Play game over ME
$game_system.me_play($data_system.gameover_me)
# Execute transition
Graphics.transition(120)
# Pre-Command Loop
loop do
Graphics.update
Input.update
if Input.trigger?(Input::C)
break
end
end
# Make command window
s1 = "Continue"
s2 = "Load Game"
s3 = "Quit"
@command_window = Window_Command.new(192, [s1, s2, s3])
@command_window.back_opacity = 160
@command_window.x = 320 - @command_window.width / 2
@command_window.y = 288
# 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 game over graphic
@sprite.bitmap.dispose
@sprite.dispose
# Execute transition
Graphics.transition(40)
# Prepare for transition
Graphics.freeze
# If battle test
if $BTEST
$scene = nil
end
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
# Update command window
@command_window.update
# If C button was pressed
if Input.trigger?(Input::C)
# Branch by command window cursor position
case @command_window.index
when 0 # Continue
$game_system.se_play($data_system.decision_se)
$scene = Scene_Load.new
when 1 # Load Game
$game_system.se_play($data_system.decision_se)
$scene = Scene_Load.new
when 2 # Quit to Title
$game_system.se_play($data_system.decision_se)
$scene = Scene_Title.new
end
end
end
end
Two problems.
First, when I choose "Load Game", the game keeps playing the Gameover ME when the loaded map loads. Is there a way around that?
Second, does anyone know of a good way to 'Continue', where-in the player is restored to a location of MapID, X, and Y, facing down and with the correct music, etc playing? I will store the MapID, X, and Y in three different variables.
Thanks in advance!