Class: GamePlay::RSEClock

Inherits:
StateMachine show all
Includes:
GamePlay::RSEClockHelpers::Logic, GamePlay::RSEClockHelpers::Questions, GamePlay::RSEClockHelpers::UI
Defined in:
docs/4_Systems_400_RSE_Clock.rb

Overview

Scene asking the player to provide the time

How to use:

  1. Set time with no initial time

call_scene(GamePlay::RSEClock) { |scene| @time = "#{scene.hour}:#{scene.minute}"}
  1. Set time with initial time

call_scene(GamePlay::RSEClock, hour, minute) { |scene| @time = "#{scene.hour}:#{scene.minute}"}

Constant Summary collapse

STATE_UPDATE_METHODS =

Constant holding all the update method to call depending on the state

{init: :update_init, choice: :update_choice, inc_min: :update_inc_min, dec_min: :update_dec_min, wait: :update_wait, confirmation: :update_confirmation, out: :update_out}

Constants inherited from Base

Base::DEFAULT_TRANSITION, Base::DEFAULT_TRANSITION_PARAMETER

Constants included from Input

Input::ALIAS_KEYS, Input::AXIS_MAPPING, Input::AXIS_SENSITIVITY, Input::DEAD_ZONE, Input::Keyboard, Input::Keys, Input::NON_TRIGGER_ZONE, Input::REPEAT_COOLDOWN, Input::REPEAT_SPACE

Constants included from DisplayMessage

DisplayMessage::MESSAGE_ERROR, DisplayMessage::MESSAGE_PROCESS_ERROR

Instance Attribute Summary

Attributes included from GamePlay::RSEClockHelpers::Logic

#hour, #minute

Attributes inherited from Base

#__last_scene, #__result_process, #running, #viewport

Attributes included from DisplayMessage

#message_window

Method Summary

Methods included from GamePlay::RSEClockHelpers::Logic

#initialize

Methods inherited from StateMachine

#update

Methods inherited from Base

#add_disposable, #call_scene, #dispose, #find_parent, #initialize, #main, #return_to_scene, #snap_to_bitmap, #update, #visible, #visible=

Methods included from Input

dir4, dir8, get_text, joy_axis_position, press?, register_events, released?, repeat?, swap_states, trigger?

Methods included from DisplayMessage

#can_display_message_be_called?, #close_message_window, #display_message, #display_message_and_wait, #message_class, #message_processing?, #message_visible, #message_visible=