Class: Battle::Logic
Overview
Logic part of Pokemon Battle
This class helps to access to the battle information & to process some part of the battle
Defined Under Namespace
Classes: AbilityChangeHandler, BattleEndHandler, BattleInfo, CatchHandler, ChangeHandlerBase, DamageHandler, EndTurnHandler, ExpHandler, FTerrainChangeHandler, FleeHandler, ItemChangeHandler, MegaEvolve, StatChangeHandler, StatusChangeHandler, SwitchHandler, TransformHandler, WeatherChangeHandler
Constant Summary collapse
- MOVE_PRIORITY_OFFSET =
Constant giving an offset for the move priority : In RH moves start their priority from 0 (-7) and end at 14 (+7)
-7 # Priority of pursuit when a switch will occur
- PURSUIT_PRIORITY =
Priority of pursuit when a switch will occur
7
- MEGA_PRIORITY =
Priority of MEGA
8
- OTHER_PRIORITY =
Priority of other things
6
- ITEM_PRIORITY_BOOST_IN_PRIORITY =
List of move first handler by item held
{quick_claw: :check_priority_trigger_quick_claw, custap_berry: :check_priority_trigger_custap_berry}
- ABILITY_PRIORITY_BOOST_IN_PRIORITY =
List of move first handler by ability
{quick_draw: :check_priority_trigger_quick_draw}
- VAL_0_25 =
Value that contains 0.25
0.25
- CRITICAL_RATES =
List of critical rates according to the current critical count
{0 => 0, 1 => 6_250, 2 => 12_500, 3 => 50_000}
- NO_CRITICAL_ABILITIES =
List of ability preventing the critical hit from happening
%i[battle_armor shell_armor]
- UNCONDITIONAL_CRITICAL_ITEMS =
List of items that unconditionally improve critical rate
%i[razor_claw scope_lens]
Instance Attribute Summary collapse
-
#actions ⇒ Array<Actions::Base>
List of the current actions to proccess during the scene.
-
#bags ⇒ Array<Array<PFM::Bag>>
readonly
Bags of each banks.
-
#ball_fetch_on_field ⇒ Array<PFM::PokemonBattler>
All the Pokemon with Ball Fetch on the field sorted by decreasing speed when the player fails the capture.
-
#bank_effects ⇒ Array<Effects::EffectsHandler>
readonly
Get the bank effects.
- #battle_info ⇒ Battle::Logic::BattleInfo readonly
-
#battle_result ⇒ Integer
0 : Victory, 1 : Flee, 2 : Defeat, -1 : undef.
-
#current_action ⇒ Actions::Base
readonly
Currently played action.
-
#debug_end_of_battle
If the battle is in debug and forcing the end of it.
-
#evolve_request ⇒ Array<PFM::PokemonBattler>
readonly
Get the evolve requests.
-
#field_terrain ⇒ Symbol
Get or set the current field terrain type.
-
#generic_rng ⇒ Random
readonly
Get the generic rng.
-
#mega_evolve ⇒ MegaEvolve
readonly
Get the Mega Evolve helper.
-
#messages ⇒ Array<Array>
readonly
List of messages to send to an interpreter (AI/Scene).
-
#move_accuracy_rng ⇒ Random
readonly
Get the move accuracy rng.
-
#move_critical_rng ⇒ Random
readonly
Get the move critical rng.
-
#move_damage_rng ⇒ Random
readonly
Get the move damage rng.
-
#position_effects ⇒ Array<Array<Battle::Effects::EffectsHandler>>
readonly
Get the position effects.
-
#scene ⇒ Battle::Scene
readonly
Get the scene used to instanciate this Logic instance.
-
#switch_request ⇒ Array<Hash>
readonly
Get the switch requests.
-
#terrain_effects ⇒ Effects::EffectsHandler
readonly
Get the terrain effects.
-
#turn_actions ⇒ Array<Actions::Base>
List of all actions that occurs within the current turn.
Instance Method Summary collapse
-
#ability_change_handler ⇒ Battle::Logic::AbilityChangeHandler
Get the ability change handler.
-
#add_actions(actions)
Add actions to process in the next step.
-
#add_bank_effect(effect)
Add an effect on a bank.
-
#add_position_effect(effect)
Add an effect on a position.
-
#adjacent_allies_of(pokemon) ⇒ Array<PFM::PokemonBattler>
Return the adjacent allies.
-
#adjacent_foes_of(pokemon) ⇒ Array<PFM::PokemonBattler>
Return the adjacent foes.
-
#alive_battlers(bank) ⇒ Array<PFM::PokemonBattler>
Return all the alive battler of a bank.
-
#alive_battlers_without_check(bank) ⇒ Array<PFM::PokemonBattler>
Return all the alive battler of a bank but don’t check can_fight?.
-
#all_alive_battlers ⇒ Array<PFM::PokemonBattler>
Return all alive battlers.
-
#all_battlers {|battler| ... } ⇒ Enumerable<PFM::PokemonBattler>
Iterate through all battlers.
-
#allies_of(pokemon, check_adjacent = false) ⇒ Array<PFM::PokemonBattler>
Return the allies (excluding the pokemon).
-
#any_field_ability_active?(db_symbol) ⇒ Array<PFM::PokemonBattler>
Check active abilities on the field.
-
#bank_count ⇒ Integer
Return the number of bank in the current battle.
-
#battle_end_handler ⇒ Battle::Logic::BattleEndHandler
Get the battle end handler.
-
#battle_phase_end
Function that distribute the exp to all Pokemon and switch dead pokemon.
-
#battle_phase_end_caught
Function that process the battle end when Pokemon was caught.
-
#battle_phase_exp
Function that test the experience distribution.
-
#battle_phase_switch_execute(who:, with: nil)
Function that executes the switch request.
-
#battle_phase_switch_exp_check
Function that process the switches and give exp.
-
#battler(bank, position) ⇒ PFM::PokemonBattler?
Return the battler of a bank.
-
#battler_attacks_after?(battler, other) ⇒ Boolean
Test if the battler attacks after another.
-
#battler_attacks_before?(battler, other) ⇒ Boolean
Test if the battler attacks before another.
-
#battler_attacks_first?(battler) ⇒ Boolean
Test if the battler attacks first.
-
#battler_attacks_last?(battler) ⇒ Boolean
Test if the battler attacks last.
-
#battler_count(bank) ⇒ Integer
Return the number of battler (alive) in one bank.
-
#calc_critical_count(user, target, initial_critical_count) ⇒ Integer
Calculate the critical count (to get the right critical propability).
-
#calc_critical_count_item(user) ⇒ Boolean
Tell if the user has an item that increase the critical count.
-
#calc_critical_hit(user, target, initial_critical_count) ⇒ Boolean
Calculate if the current action will be a critical hit.
-
#can_battle_continue? ⇒ Boolean
Tell if the battle can continue.
-
#can_battler_be_replaced?(who) ⇒ Boolean
Test if the battler can be replaced.
-
#catch_handler ⇒ Battle::Logic::CatchHandler
Get the catch handler.
-
#damage_handler ⇒ Battle::Logic::DamageHandler
Get a new damage handler.
-
#delete_dead_effects
Delete all the dead effect by updating counters & removing them.
-
#each_effects(*pokemons) {|| ... } ⇒ Array<Effects::EffectBase>, ...
Execute a block on each effect depending on what to select as effect.
-
#end_turn_handler ⇒ Battle::Logic::EndTurnHandler
Get a new switch handler.
-
#exp_handler ⇒ Battle::Logic::ExpHandler
Get the exp handler.
-
#field_terrain_effect ⇒ Effects::FieldTerrain
Get the field terrain effect.
-
#flee_handler ⇒ Battle::Logic::FleeHandler
Get the flee handler.
-
#foes_of(pokemon, check_adjacent = false) ⇒ Array<PFM::PokemonBattler>
Return the foes.
-
#force_sort_actions(&block)
Sort the actions.
-
#fterrain_change_handler ⇒ Battle::Logic::FTerrainChangeHandler
Get a new field terrain change handler.
-
#initialize(scene) ⇒ Logic
constructor
Create a new Logic instance.
-
#item_change_handler ⇒ Battle::Logic::ItemChangeHandler
Get a new item change handler.
-
#load_battlers
Load the battlers from the battle infos.
-
#load_rng(seeds = Hash.new(Random.new_seed))
Load the RNG for the battle logic.
-
#perform_next_action ⇒ Boolean
Execute the next action.
-
#request_switch(who, with)
Add a switch request.
-
#rng_seeds ⇒ Hash{ Symbol => Integer }
Get the current RNG Seeds.
-
#sort_actions
Sort the actions.
-
#stat_change_handler ⇒ Battle::Logic::StatChangeHandler
Get a new stat change handler.
-
#status_change_handler ⇒ Battle::Logic::StatusChangeHandler
Get a new item change handler.
-
#switch_bank_effects(bank1, bank2)
Switch bank effects.
-
#switch_battlers(who, with)
Switch two pokemon (logically).
-
#switch_handler ⇒ Battle::Logic::SwitchHandler
Get a new switch handler.
-
#to_s
(also: #inspect)
Safe to_s & inspect.
-
#trainer_battlers ⇒ Array<PFM::PokemonBattler>
List all the trainer Pokemon.
-
#transform_handler ⇒ Battle::Logic::TransformHandler
Get the transform handler.
-
#update_battler_turn_count
Update the turn count of all alive battler.
-
#weather_change_handler ⇒ Battle::Logic::WeatherChangeHandler
Get a new weather change handler.
-
#weather_effect ⇒ Effects::Weather
Get the weather effect.
Constructor Details
#initialize(scene) ⇒ Logic
Create a new Logic instance
52 53 |
# File 'docs/5_Battle_04_Logic.rb', line 52 def initialize(scene) end |
Instance Attribute Details
#actions ⇒ Array<Actions::Base>
Returns list of the current actions to proccess during the scene.
9 10 11 |
# File 'docs/5_Battle_04_Logic.rb', line 9 def actions @actions end |
#bags ⇒ Array<Array<PFM::Bag>> (readonly)
Returns bags of each banks.
18 19 20 |
# File 'docs/5_Battle_04_Logic.rb', line 18 def bags @bags end |
#ball_fetch_on_field ⇒ Array<PFM::PokemonBattler>
All the Pokemon with Ball Fetch on the field sorted by decreasing speed when the player fails the capture
49 50 51 |
# File 'docs/5_Battle_04_Logic.rb', line 49 def ball_fetch_on_field @ball_fetch_on_field end |
#bank_effects ⇒ Array<Effects::EffectsHandler> (readonly)
Get the bank effects
391 392 393 |
# File 'docs/5_Battle_04_Logic.rb', line 391 def bank_effects @bank_effects end |
#battle_info ⇒ Battle::Logic::BattleInfo (readonly)
20 21 22 |
# File 'docs/5_Battle_04_Logic.rb', line 20 def battle_info @battle_info end |
#battle_result ⇒ Integer
0 : Victory, 1 : Flee, 2 : Defeat, -1 : undef
16 17 18 |
# File 'docs/5_Battle_04_Logic.rb', line 16 def battle_result @battle_result end |
#current_action ⇒ Actions::Base (readonly)
Returns currently played action.
11 12 13 |
# File 'docs/5_Battle_04_Logic.rb', line 11 def current_action @current_action end |
#debug_end_of_battle
If the battle is in debug and forcing the end of it
46 47 48 |
# File 'docs/5_Battle_04_Logic.rb', line 46 def debug_end_of_battle @debug_end_of_battle end |
#evolve_request ⇒ Array<PFM::PokemonBattler> (readonly)
Get the evolve requests
23 24 25 |
# File 'docs/5_Battle_04_Logic.rb', line 23 def evolve_request @evolve_request end |
#field_terrain ⇒ Symbol
Get or set the current field terrain type
397 398 399 |
# File 'docs/5_Battle_04_Logic.rb', line 397 def field_terrain @field_terrain end |
#generic_rng ⇒ Random (readonly)
Get the generic rng
44 45 46 |
# File 'docs/5_Battle_04_Logic.rb', line 44 def generic_rng @generic_rng end |
#mega_evolve ⇒ MegaEvolve (readonly)
Get the Mega Evolve helper
26 27 28 |
# File 'docs/5_Battle_04_Logic.rb', line 26 def mega_evolve @mega_evolve end |
#messages ⇒ Array<Array> (readonly)
Returns list of messages to send to an interpreter (AI/Scene).
7 8 9 |
# File 'docs/5_Battle_04_Logic.rb', line 7 def @messages end |
#move_accuracy_rng ⇒ Random (readonly)
Get the move accuracy rng
41 42 43 |
# File 'docs/5_Battle_04_Logic.rb', line 41 def move_accuracy_rng @move_accuracy_rng end |
#move_critical_rng ⇒ Random (readonly)
Get the move critical rng
38 39 40 |
# File 'docs/5_Battle_04_Logic.rb', line 38 def move_critical_rng @move_critical_rng end |
#move_damage_rng ⇒ Random (readonly)
Get the move damage rng
35 36 37 |
# File 'docs/5_Battle_04_Logic.rb', line 35 def move_damage_rng @move_damage_rng end |
#position_effects ⇒ Array<Array<Battle::Effects::EffectsHandler>> (readonly)
Get the position effects
394 395 396 |
# File 'docs/5_Battle_04_Logic.rb', line 394 def position_effects @position_effects end |
#scene ⇒ Battle::Scene (readonly)
Get the scene used to instanciate this Logic instance
32 33 34 |
# File 'docs/5_Battle_04_Logic.rb', line 32 def scene @scene end |
#switch_request ⇒ Array<Hash> (readonly)
Get the switch requests
29 30 31 |
# File 'docs/5_Battle_04_Logic.rb', line 29 def switch_request @switch_request end |
#terrain_effects ⇒ Effects::EffectsHandler (readonly)
Get the terrain effects
388 389 390 |
# File 'docs/5_Battle_04_Logic.rb', line 388 def terrain_effects @terrain_effects end |
#turn_actions ⇒ Array<Actions::Base>
Returns list of all actions that occurs within the current turn.
13 14 15 |
# File 'docs/5_Battle_04_Logic.rb', line 13 def turn_actions @turn_actions end |
Instance Method Details
#ability_change_handler ⇒ Battle::Logic::AbilityChangeHandler
Get the ability change handler
371 372 |
# File 'docs/5_Battle_04_Logic.rb', line 371 def ability_change_handler end |
#add_actions(actions)
Add actions to process in the next step
218 219 |
# File 'docs/5_Battle_04_Logic.rb', line 218 def add_actions(actions) end |
#add_bank_effect(effect)
Add an effect on a bank
412 413 |
# File 'docs/5_Battle_04_Logic.rb', line 412 def add_bank_effect(effect) end |
#add_position_effect(effect)
Add an effect on a position
408 409 |
# File 'docs/5_Battle_04_Logic.rb', line 408 def add_position_effect(effect) end |
#adjacent_allies_of(pokemon) ⇒ Array<PFM::PokemonBattler>
Return the adjacent allies
99 100 |
# File 'docs/5_Battle_04_Logic.rb', line 99 def adjacent_allies_of(pokemon) end |
#adjacent_foes_of(pokemon) ⇒ Array<PFM::PokemonBattler>
Return the adjacent foes
88 89 |
# File 'docs/5_Battle_04_Logic.rb', line 88 def adjacent_foes_of(pokemon) end |
#alive_battlers(bank) ⇒ Array<PFM::PokemonBattler>
Return all the alive battler of a bank
110 111 |
# File 'docs/5_Battle_04_Logic.rb', line 110 def alive_battlers(bank) end |
#alive_battlers_without_check(bank) ⇒ Array<PFM::PokemonBattler>
Return all the alive battler of a bank but don’t check can_fight?
115 116 |
# File 'docs/5_Battle_04_Logic.rb', line 115 def alive_battlers_without_check(bank) end |
#all_alive_battlers ⇒ Array<PFM::PokemonBattler>
Return all alive battlers
119 120 |
# File 'docs/5_Battle_04_Logic.rb', line 119 def all_alive_battlers end |
#all_battlers {|battler| ... } ⇒ Enumerable<PFM::PokemonBattler>
Iterate through all battlers
162 163 |
# File 'docs/5_Battle_04_Logic.rb', line 162 def all_battlers end |
#allies_of(pokemon, check_adjacent = false) ⇒ Array<PFM::PokemonBattler>
Return the allies (excluding the pokemon)
105 106 |
# File 'docs/5_Battle_04_Logic.rb', line 105 def allies_of(pokemon, check_adjacent = false) end |
#any_field_ability_active?(db_symbol) ⇒ Array<PFM::PokemonBattler>
Check active abilities on the field
175 176 |
# File 'docs/5_Battle_04_Logic.rb', line 175 def any_field_ability_active?(db_symbol) end |
#bank_count ⇒ Integer
Return the number of bank in the current battle
60 61 |
# File 'docs/5_Battle_04_Logic.rb', line 60 def bank_count end |
#battle_end_handler ⇒ Battle::Logic::BattleEndHandler
Get the battle end handler
375 376 |
# File 'docs/5_Battle_04_Logic.rb', line 375 def battle_end_handler end |
#battle_phase_end
Function that distribute the exp to all Pokemon and switch dead pokemon
302 303 |
# File 'docs/5_Battle_04_Logic.rb', line 302 def battle_phase_end end |
#battle_phase_end_caught
Function that process the battle end when Pokemon was caught
316 317 |
# File 'docs/5_Battle_04_Logic.rb', line 316 def battle_phase_end_caught end |
#battle_phase_exp
Function that test the experience distribution
305 306 |
# File 'docs/5_Battle_04_Logic.rb', line 305 def battle_phase_exp end |
#battle_phase_switch_execute(who:, with: nil)
Function that executes the switch request
313 314 |
# File 'docs/5_Battle_04_Logic.rb', line 313 def battle_phase_switch_execute(who:, with: nil) end |
#battle_phase_switch_exp_check
Function that process the switches and give exp
308 309 |
# File 'docs/5_Battle_04_Logic.rb', line 308 def battle_phase_switch_exp_check end |
#battler(bank, position) ⇒ PFM::PokemonBattler?
Return the battler of a bank
78 79 |
# File 'docs/5_Battle_04_Logic.rb', line 78 def battler(bank, position) end |
#battler_attacks_after?(battler, other) ⇒ Boolean
Test if the battler attacks after another
142 143 |
# File 'docs/5_Battle_04_Logic.rb', line 142 def battler_attacks_after?(battler, other) end |
#battler_attacks_before?(battler, other) ⇒ Boolean
Test if the battler attacks before another
136 137 |
# File 'docs/5_Battle_04_Logic.rb', line 136 def battler_attacks_before?(battler, other) end |
#battler_attacks_first?(battler) ⇒ Boolean
Test if the battler attacks first
147 148 |
# File 'docs/5_Battle_04_Logic.rb', line 147 def battler_attacks_first?(battler) end |
#battler_attacks_last?(battler) ⇒ Boolean
Test if the battler attacks last
152 153 |
# File 'docs/5_Battle_04_Logic.rb', line 152 def battler_attacks_last?(battler) end |
#battler_count(bank) ⇒ Integer
Return the number of battler (alive) in one bank
83 84 |
# File 'docs/5_Battle_04_Logic.rb', line 83 def battler_count(bank) end |
#calc_critical_count(user, target, initial_critical_count) ⇒ Integer
Calculate the critical count (to get the right critical propability)
291 292 |
# File 'docs/5_Battle_04_Logic.rb', line 291 def calc_critical_count(user, target, initial_critical_count) end |
#calc_critical_count_item(user) ⇒ Boolean
Tell if the user has an item that increase the critical count
298 299 |
# File 'docs/5_Battle_04_Logic.rb', line 298 def calc_critical_count_item(user) end |
#calc_critical_hit(user, target, initial_critical_count) ⇒ Boolean
Calculate if the current action will be a critical hit
282 283 |
# File 'docs/5_Battle_04_Logic.rb', line 282 def calc_critical_hit(user, target, initial_critical_count) end |
#can_battle_continue? ⇒ Boolean
Tell if the battle can continue
64 65 |
# File 'docs/5_Battle_04_Logic.rb', line 64 def can_battle_continue? end |
#can_battler_be_replaced?(who) ⇒ Boolean
Test if the battler can be replaced
167 168 |
# File 'docs/5_Battle_04_Logic.rb', line 167 def can_battler_be_replaced?(who) end |
#catch_handler ⇒ Battle::Logic::CatchHandler
Get the catch handler
367 368 |
# File 'docs/5_Battle_04_Logic.rb', line 367 def catch_handler end |
#damage_handler ⇒ Battle::Logic::DamageHandler
Get a new damage handler
343 344 |
# File 'docs/5_Battle_04_Logic.rb', line 343 def damage_handler end |
#delete_dead_effects
Delete all the dead effect by updating counters & removing them
415 416 |
# File 'docs/5_Battle_04_Logic.rb', line 415 def delete_dead_effects end |
#each_effects(*pokemons) {|| ... } ⇒ Array<Effects::EffectBase>, ...
This returns an enumerator if no block is given
If the block returns a Symbol, this methods returns this symbol immediately without processing the other effects
Execute a block on each effect depending on what to select as effect
404 405 |
# File 'docs/5_Battle_04_Logic.rb', line 404 def each_effects(*pokemons) end |
#end_turn_handler ⇒ Battle::Logic::EndTurnHandler
Get a new switch handler
351 352 |
# File 'docs/5_Battle_04_Logic.rb', line 351 def end_turn_handler end |
#exp_handler ⇒ Battle::Logic::ExpHandler
Get the exp handler
379 380 |
# File 'docs/5_Battle_04_Logic.rb', line 379 def exp_handler end |
#field_terrain_effect ⇒ Effects::FieldTerrain
Get the field terrain effect
423 424 |
# File 'docs/5_Battle_04_Logic.rb', line 423 def field_terrain_effect end |
#flee_handler ⇒ Battle::Logic::FleeHandler
Get the flee handler
363 364 |
# File 'docs/5_Battle_04_Logic.rb', line 363 def flee_handler end |
#foes_of(pokemon, check_adjacent = false) ⇒ Array<PFM::PokemonBattler>
Return the foes
94 95 |
# File 'docs/5_Battle_04_Logic.rb', line 94 def foes_of(pokemon, check_adjacent = false) end |
#force_sort_actions(&block)
Sort the actions
230 231 |
# File 'docs/5_Battle_04_Logic.rb', line 230 def force_sort_actions(&block) end |
#fterrain_change_handler ⇒ Battle::Logic::FTerrainChangeHandler
Get a new field terrain change handler
359 360 |
# File 'docs/5_Battle_04_Logic.rb', line 359 def fterrain_change_handler end |
#item_change_handler ⇒ Battle::Logic::ItemChangeHandler
Get a new item change handler
335 336 |
# File 'docs/5_Battle_04_Logic.rb', line 335 def item_change_handler end |
#load_battlers
Load the battlers from the battle infos
122 123 |
# File 'docs/5_Battle_04_Logic.rb', line 122 def load_battlers end |
#load_rng(seeds = Hash.new(Random.new_seed))
Load the RNG for the battle logic
68 69 |
# File 'docs/5_Battle_04_Logic.rb', line 68 def load_rng(seeds = Hash.new(Random.new_seed)) end |
#perform_next_action ⇒ Boolean
Execute the next action
222 223 |
# File 'docs/5_Battle_04_Logic.rb', line 222 def perform_next_action end |
#request_switch(who, with)
Add a switch request
127 128 |
# File 'docs/5_Battle_04_Logic.rb', line 127 def request_switch(who, with) end |
#rng_seeds ⇒ Hash{ Symbol => Integer }
Get the current RNG Seeds
72 73 |
# File 'docs/5_Battle_04_Logic.rb', line 72 def rng_seeds end |
#sort_actions
The last action in the stack is the first action to pop out from the stack
Sort the actions
226 227 |
# File 'docs/5_Battle_04_Logic.rb', line 226 def sort_actions end |
#stat_change_handler ⇒ Battle::Logic::StatChangeHandler
Get a new stat change handler
331 332 |
# File 'docs/5_Battle_04_Logic.rb', line 331 def stat_change_handler end |
#status_change_handler ⇒ Battle::Logic::StatusChangeHandler
Get a new item change handler
339 340 |
# File 'docs/5_Battle_04_Logic.rb', line 339 def status_change_handler end |
#switch_bank_effects(bank1, bank2)
Switch bank effects
428 429 |
# File 'docs/5_Battle_04_Logic.rb', line 428 def switch_bank_effects(bank1, bank2) end |
#switch_battlers(who, with)
Switch two pokemon (logically)
157 158 |
# File 'docs/5_Battle_04_Logic.rb', line 157 def switch_battlers(who, with) end |
#switch_handler ⇒ Battle::Logic::SwitchHandler
Get a new switch handler
347 348 |
# File 'docs/5_Battle_04_Logic.rb', line 347 def switch_handler end |
#to_s Also known as: inspect
Safe to_s & inspect
55 56 |
# File 'docs/5_Battle_04_Logic.rb', line 55 def to_s end |
#trainer_battlers ⇒ Array<PFM::PokemonBattler>
List all the trainer Pokemon
171 172 |
# File 'docs/5_Battle_04_Logic.rb', line 171 def trainer_battlers end |
#transform_handler ⇒ Battle::Logic::TransformHandler
Get the transform handler
383 384 |
# File 'docs/5_Battle_04_Logic.rb', line 383 def transform_handler end |
#update_battler_turn_count
Update the turn count of all alive battler
130 131 |
# File 'docs/5_Battle_04_Logic.rb', line 130 def update_battler_turn_count end |
#weather_change_handler ⇒ Battle::Logic::WeatherChangeHandler
Get a new weather change handler
355 356 |
# File 'docs/5_Battle_04_Logic.rb', line 355 def weather_change_handler end |
#weather_effect ⇒ Effects::Weather
Get the weather effect
419 420 |
# File 'docs/5_Battle_04_Logic.rb', line 419 def weather_effect end |