Class: Scene_End

Inherits:
Scene_MenuBase show all
Defined in:
Scene_End.rb

Overview

** Scene_End


This class performs game over screen processing.

Instance Method Summary (collapse)

Methods inherited from Scene_MenuBase

#create_help_window, #dispose_background, #next_actor, #on_actor_change, #prev_actor, #terminate

Methods inherited from Scene_Base

#check_gameover, #create_main_viewport, #dispose_all_windows, #dispose_main_viewport, #fadeout_all, #main, #perform_transition, #post_start, #return_scene, #scene_changing?, #terminate, #transition_speed, #update, #update_all_windows, #update_basic

Instance Method Details

- (Object) close_command_window


  • Close Command Window




41
42
43
44
# File 'Scene_End.rb', line 41

def close_command_window
  @command_window.close
  update until @command_window.close?
end

- (Object) command_shutdown


  • Shut Down

    Command




56
57
58
59
60
# File 'Scene_End.rb', line 56

def command_shutdown
  close_command_window
  fadeout_all
  SceneManager.exit
end

- (Object) command_to_title


  • Go to Title

    Command




48
49
50
51
52
# File 'Scene_End.rb', line 48

def command_to_title
  close_command_window
  fadeout_all
  SceneManager.goto(Scene_Title)
end

- (Object) create_background


  • Create Background




25
26
27
28
# File 'Scene_End.rb', line 25

def create_background
  super
  @background_sprite.tone.set(0, 0, 0, 128)
end

- (Object) create_command_window


  • Create Command Window




32
33
34
35
36
37
# File 'Scene_End.rb', line 32

def create_command_window
  @command_window = Window_GameEnd.new
  @command_window.set_handler(:to_title, method(:command_to_title))
  @command_window.set_handler(:shutdown, method(:command_shutdown))
  @command_window.set_handler(:cancel,   method(:return_scene))
end

- (Object) pre_terminate


  • Pre-Termination Processing




18
19
20
21
# File 'Scene_End.rb', line 18

def pre_terminate
  super
  close_command_window
end

- (Object) start


  • Start Processing




11
12
13
14
# File 'Scene_End.rb', line 11

def start
  super
  create_command_window
end