Class: GTS::SearchMethod

Inherits:
GamePlay::BaseCleanUpdate show all
Defined in:
scripts/01450 Systems/09000 GTS/09000 GTS.rb

Overview

GTS Search Method Selection

Direct Known Subclasses

Scene, WantedDataScene

Constant Summary

Constants inherited from GamePlay::BaseCleanUpdate

GamePlay::BaseCleanUpdate::AIU_KEY2METHOD

Constants inherited from GamePlay::Base

GamePlay::Base::DEFAULT_TRANSITION, GamePlay::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 GamePlay::DisplayMessage

GamePlay::DisplayMessage::MESSAGE_ERROR, GamePlay::DisplayMessage::MESSAGE_PROCESS_ERROR

Instance Attribute Summary

Attributes inherited from GamePlay::Base

#__last_scene, #__result_process, #running, #viewport

Attributes included from GamePlay::DisplayMessage

#message_window

Instance Method Summary collapse

Methods inherited from GamePlay::BaseCleanUpdate

#automatic_input_update, #update

Methods inherited from GamePlay::Base

#add_disposable, #call_scene, #dispose, #find_parent, #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 GamePlay::DisplayMessage

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

Constructor Details

#initializeSearchMethod

Create the new SearchMethod object



211
212
213
214
215
# File 'scripts/01450 Systems/09000 GTS/09000 GTS.rb', line 211

def initialize
  super
  @index = 0
  @max_index = 3
end

Instance Method Details

#update_inputs

Update the inputs



218
219
220
221
222
223
224
225
226
227
228
229
230
231
# File 'scripts/01450 Systems/09000 GTS/09000 GTS.rb', line 218

def update_inputs
  if index_changed(:@index, :UP, :DOWN, @max_index)
    update_selector
  elsif Input.trigger?(:B)
    $game_system.se_play($data_system.cancel_se)
    @running = false
  elsif Input.trigger?(:A)
    $game_system.se_play($data_system.decision_se)
    do_command
  else
    return true
  end
  return false
end