Trait eos_rs::api::dungeon_mode::DungeonMonsterRead
source · pub trait DungeonMonsterRead: Sealed {
Show 59 methods
// Provided methods
fn is_special_story_ally(&self) -> bool { ... }
fn is_experience_locked(&self) -> bool { ... }
fn is_holding_item(&self, item_id: ItemId) -> bool { ... }
fn has_low_health(&self) -> bool { ... }
fn gastro_acid_status(&self) -> bool { ... }
fn is_ability_active(&self, ability_id: AbilityId) -> bool { ... }
fn is_ability_active_any_entity(&self, ability_id: AbilityId) -> bool { ... }
fn has_type(&self, type_id: MonsterTypeId) -> bool { ... }
fn is_iq_skill_enabled(&self, iq_skill_id: IqSkillId) -> bool { ... }
fn is_defender_ability_active(
&self,
defender: &DungeonEntity,
defender_ability_id: AbilityId,
own_ability_is_active: bool
) -> bool { ... }
fn is_exclusive_item_effect_active(
&self,
effect_id: ExclusiveItemEffectId
) -> bool { ... }
fn get_type_matchup(
&self,
defender: &DungeonEntity,
target_type_index: TargetTypeIndex,
attack_type: MonsterTypeId
) -> Option<DungeonTypeMatchup> { ... }
fn calc_damage(
&self,
defender: &DungeonEntity,
attack_type: MonsterTypeId,
attack_power: i32,
crit_chance: i32,
damage_out: &mut damage_data,
damage_multiplier: I24F8,
move_id: MoveId,
param_9: i32
) { ... }
unsafe fn calc_recoil_damage_fixed(
&self,
fixed_damage: i32,
param_3: undefined4,
damage_out: &mut damage_data,
move_id: MoveId,
attack_type: MonsterTypeId,
param_7: i16,
message_type: undefined4,
param_9: undefined4,
param_10: undefined4
) { ... }
unsafe fn calc_damage_fixed(
&self,
defender: &DungeonEntity,
fixed_damage: i32,
param_4: undefined4,
damage_out: &mut damage_data,
attack_type: MonsterTypeId,
move_category: MoveCategory,
param_8: i16,
message_type: undefined4,
param_10: undefined4,
param_11: undefined4
) { ... }
unsafe fn calc_damage_fixed_no_category(
&self,
defender: &DungeonEntity,
fixed_damage: i32,
param_4: undefined4,
damage_out: &mut damage_data,
attack_type: MonsterTypeId,
param_7: i16,
message_type: undefined4,
param_9: undefined4,
param_10: undefined4
) { ... }
unsafe fn calc_damage_fixed_wrapper(
&self,
defender: &DungeonEntity,
fixed_damage: i32,
param_4: undefined4,
damage_out: &mut damage_data,
attack_type: MonsterTypeId,
move_category: MoveCategory,
param_8: i16,
param_9: undefined4,
param_10: undefined4,
param_11: undefined4
) { ... }
fn calc_damage_projectile(
&self,
defender: &DungeonEntity,
used_move: &Move,
move_power: i32,
damage_multiplier: I24F8,
item_id: ItemId
) -> i32 { ... }
fn calc_damage_final(
&self,
defender: &DungeonEntity,
used_move: &Move,
damage_out: &mut damage_data,
faint_reason: faint_reason
) -> i32 { ... }
fn can_target_entity(&self, target: &DungeonEntity) -> bool { ... }
fn can_target_position(&self, target: &position) -> bool { ... }
fn is_aura_bow_active(&self) -> bool { ... }
fn get_exclusive_item_offense_boost(
&self,
move_category: MoveCategory
) -> i32 { ... }
fn get_exclusive_item_defense_boost(
&self,
move_category: MoveCategory
) -> i32 { ... }
fn has_conditional_ground_immunity(&self) -> bool { ... }
fn get_move_target_and_range(
&self,
the_move: &Move,
is_ai: bool
) -> MoveTargetAndRange { ... }
fn get_apparent_weather(&self) -> Option<Weather> { ... }
fn has_held_item(&self, item_id: ItemId) -> bool { ... }
fn get_move_power(&self, the_move: &Move) -> i32 { ... }
fn get_personality_index(&self) -> i32 { ... }
fn calc_status_duration(&self, turn_range: &[u16; 2], effects: bool) -> i32 { ... }
fn get_number_of_attacks(&self) -> i32 { ... }
fn is_levitating(&self) -> bool { ... }
fn is_type_affected_by_gravity(&self, type_id: type_id) -> bool { ... }
fn has_type_affected_by_gravity(&self, type_id: type_id) -> bool { ... }
fn is_conversion2_active(&self) -> Option<Conversion2Status> { ... }
fn get_move_type_if_used_by_self(&self, the_move: &Move) -> MonsterTypeId { ... }
fn get_sleep_animation_id(&self) -> u8 { ... }
fn is_blinded(&self, check_held_item: bool) -> bool { ... }
fn should_monster_run_away(&self) -> bool { ... }
unsafe fn should_monster_run_away_variation(&self, param: undefined) -> bool { ... }
unsafe fn should_monster_run_away_variation_outlaw_check(
&self,
param: undefined
) -> bool { ... }
fn should_head_to_stairs(&self) -> bool { ... }
fn has_status_that_prevents_acting(&self) -> bool { ... }
fn is_cornered(&self) -> bool { ... }
fn can_attack_in_direction(&self, direction: Direction) -> bool { ... }
fn ai_obstruction_in_direction(&self, direction: Direction) -> Option<bool> { ... }
fn can_see_invisible_monsters(&self) -> bool { ... }
fn has_dropeye_status(&self) -> bool { ... }
fn is_target_eligible(
&self,
move_ai_range: MoveTargetAndRange,
target: &DungeonEntity,
the_move: &Move,
check_all_conditions: bool
) -> bool { ... }
fn can_use_move(&self, the_move: &Move, extra_checks: bool) -> bool { ... }
unsafe fn can_ai_use_move_unchecked(
&self,
move_index: i32,
extra_checks: bool
) -> bool { ... }
fn can_ai_use_move(&self, move_index: u8, extra_checks: bool) -> bool { ... }
fn status_checker_check(&self, the_move: &Move) -> bool { ... }
fn get_monster_apparent_id(&self, current_id: MonsterSpeciesId) -> i32 { ... }
unsafe fn get_monster_name(&self, output: *mut c_char) { ... }
fn is_target_recruited(&self, target: &DungeonEntity) -> bool { ... }
fn is_satisfying_scenario_condition_to_spawn(&self) -> bool { ... }
fn is_in_spawn_list(&self, spawn_list: &mut undefined) -> bool { ... }
}
Expand description
Trait for DungeonMonsterRef
and DungeonMonsterMut
(read operations).
Important safety note
Please see the safety note of DungeonEntity
. It also applies to this trait.
Provided Methods§
sourcefn is_special_story_ally(&self) -> bool
fn is_special_story_ally(&self) -> bool
Checks if the monster is a special story ally.
This is a hard-coded check that looks at the monster’s “Joined At” field.
If the value is in the range [
crate::api::dungeons::DungeonId::DUNGEON_JOINED_AT_BIDOOF
,
crate::api::dungeons::DungeonId::DUNGEON_DUMMY_0xE3
], this check will return true.
sourcefn is_experience_locked(&self) -> bool
fn is_experience_locked(&self) -> bool
Checks if the monster does not gain experience.
This basically just inverts IsSpecialStoryAlly, with the exception of also checking for
the “Joined At” field being crate::api::dungeons::DungeonId::DUNGEON_CLIENT
.
sourcefn is_holding_item(&self, item_id: ItemId) -> bool
fn is_holding_item(&self, item_id: ItemId) -> bool
Checks if the monster is holding a certain item that isn’t disabled by Klutz.
sourcefn has_low_health(&self) -> bool
fn has_low_health(&self) -> bool
Checks if the monster is at low health (below 25% rounded down).
sourcefn gastro_acid_status(&self) -> bool
fn gastro_acid_status(&self) -> bool
Checks if the monster has the Gastro Acid status.
fn is_ability_active(&self, ability_id: AbilityId) -> bool
fn is_ability_active_any_entity(&self, ability_id: AbilityId) -> bool
sourcefn has_type(&self, type_id: MonsterTypeId) -> bool
fn has_type(&self, type_id: MonsterTypeId) -> bool
Checks if the monster has a given type.
sourcefn is_iq_skill_enabled(&self, iq_skill_id: IqSkillId) -> bool
fn is_iq_skill_enabled(&self, iq_skill_id: IqSkillId) -> bool
Checks if the monster has a certain IQ skill enabled.
sourcefn is_defender_ability_active(
&self,
defender: &DungeonEntity,
defender_ability_id: AbilityId,
own_ability_is_active: bool
) -> bool
fn is_defender_ability_active( &self, defender: &DungeonEntity, defender_ability_id: AbilityId, own_ability_is_active: bool ) -> bool
Checks if a defender has an active ability that isn’t disabled by an attacker’s (self) Mold Breaker.
sourcefn is_exclusive_item_effect_active(
&self,
effect_id: ExclusiveItemEffectId
) -> bool
fn is_exclusive_item_effect_active( &self, effect_id: ExclusiveItemEffectId ) -> bool
Checks if a certain exclusive item effect is active for the monster.
sourcefn get_type_matchup(
&self,
defender: &DungeonEntity,
target_type_index: TargetTypeIndex,
attack_type: MonsterTypeId
) -> Option<DungeonTypeMatchup>
fn get_type_matchup( &self, defender: &DungeonEntity, target_type_index: TargetTypeIndex, attack_type: MonsterTypeId ) -> Option<DungeonTypeMatchup>
Gets the type matchup for a given combat interaction. Attacker is self. Note that the actual monster’s types on the attacker and defender are not used; the entities are only used to check conditions. The actual type matchup table lookup is done solely using the attack and target type parameters.
This factors in some conditional effects like exclusive items, statuses, etc.
sourcefn calc_damage(
&self,
defender: &DungeonEntity,
attack_type: MonsterTypeId,
attack_power: i32,
crit_chance: i32,
damage_out: &mut damage_data,
damage_multiplier: I24F8,
move_id: MoveId,
param_9: i32
)
fn calc_damage( &self, defender: &DungeonEntity, attack_type: MonsterTypeId, attack_power: i32, crit_chance: i32, damage_out: &mut damage_data, damage_multiplier: I24F8, move_id: MoveId, param_9: i32 )
Probably the damage calculation function. The result seems to get written to the unknown struct behind the pointer provided by damage_out, param_9 is also unknown.
The signature of this method WILL change once we figure out what the parameters are.
sourceunsafe fn calc_recoil_damage_fixed(
&self,
fixed_damage: i32,
param_3: undefined4,
damage_out: &mut damage_data,
move_id: MoveId,
attack_type: MonsterTypeId,
param_7: i16,
message_type: undefined4,
param_9: undefined4,
param_10: undefined4
)
unsafe fn calc_recoil_damage_fixed( &self, fixed_damage: i32, param_3: undefined4, damage_out: &mut damage_data, move_id: MoveId, attack_type: MonsterTypeId, param_7: i16, message_type: undefined4, param_9: undefined4, param_10: undefined4 )
Appears to calculate recoil damage to the monster.
This function wraps Self::calc_damage_fixed
using the monster as both the attacker and
the defender, after doing some basic checks (like if the monster is already at 0 HP)
and applying a boost from the Reckless ability if applicable.
Some parameters are unknown.
The result seems to get written to the unknown struct behind the pointer provided by
damage_out, some other parameters are also unknown.
The signature of this method WILL change once we figure out what the parameters are.
Safety
The caller must make sure the undefined params are valid for this function.
sourceunsafe fn calc_damage_fixed(
&self,
defender: &DungeonEntity,
fixed_damage: i32,
param_4: undefined4,
damage_out: &mut damage_data,
attack_type: MonsterTypeId,
move_category: MoveCategory,
param_8: i16,
message_type: undefined4,
param_10: undefined4,
param_11: undefined4
)
unsafe fn calc_damage_fixed( &self, defender: &DungeonEntity, fixed_damage: i32, param_4: undefined4, damage_out: &mut damage_data, attack_type: MonsterTypeId, move_category: MoveCategory, param_8: i16, message_type: undefined4, param_10: undefined4, param_11: undefined4 )
Appears to calculate damage from a fixed-damage effect. The result seems to get written to the unknown struct behind the pointer provided by damage_out, some other parameters are also unknown.
The signature of this method WILL change once we figure out what the parameters are.
Safety
The caller must make sure the undefined params are valid for this function.
sourceunsafe fn calc_damage_fixed_no_category(
&self,
defender: &DungeonEntity,
fixed_damage: i32,
param_4: undefined4,
damage_out: &mut damage_data,
attack_type: MonsterTypeId,
param_7: i16,
message_type: undefined4,
param_9: undefined4,
param_10: undefined4
)
unsafe fn calc_damage_fixed_no_category( &self, defender: &DungeonEntity, fixed_damage: i32, param_4: undefined4, damage_out: &mut damage_data, attack_type: MonsterTypeId, param_7: i16, message_type: undefined4, param_9: undefined4, param_10: undefined4 )
A wrapper around Self::calc_damage_fixed
with the move category
set to MoveCategory::None
.
The signature of this method WILL change once we figure out what the parameters are.
Safety
The caller must make sure the undefined params are valid for this function.
sourceunsafe fn calc_damage_fixed_wrapper(
&self,
defender: &DungeonEntity,
fixed_damage: i32,
param_4: undefined4,
damage_out: &mut damage_data,
attack_type: MonsterTypeId,
move_category: MoveCategory,
param_8: i16,
param_9: undefined4,
param_10: undefined4,
param_11: undefined4
)
unsafe fn calc_damage_fixed_wrapper( &self, defender: &DungeonEntity, fixed_damage: i32, param_4: undefined4, damage_out: &mut damage_data, attack_type: MonsterTypeId, move_category: MoveCategory, param_8: i16, param_9: undefined4, param_10: undefined4, param_11: undefined4 )
A wrapper (with potential side effects…?) around Self::calc_damage_fixed
.
The signature of this method WILL change once we figure out what the parameters are.
Safety
The caller must make sure the undefined params are valid for this function.
sourcefn calc_damage_projectile(
&self,
defender: &DungeonEntity,
used_move: &Move,
move_power: i32,
damage_multiplier: I24F8,
item_id: ItemId
) -> i32
fn calc_damage_projectile( &self, defender: &DungeonEntity, used_move: &Move, move_power: i32, damage_multiplier: I24F8, item_id: ItemId ) -> i32
Appears to calculate damage from a variable-damage projectile.
One of param_5
or param_6
is probably the output struct.
The signature of this method WILL change once we figure out what the parameters are.
sourcefn calc_damage_final(
&self,
defender: &DungeonEntity,
used_move: &Move,
damage_out: &mut damage_data,
faint_reason: faint_reason
) -> i32
fn calc_damage_final( &self, defender: &DungeonEntity, used_move: &Move, damage_out: &mut damage_data, faint_reason: faint_reason ) -> i32
Last function called by DungeonEffectsEmitter::deal_damage
to determine the final
damage dealt by the move.
The result of this call is the return value of DealDamage.
Arguments
attacker
- attacker pointerdefender
- defender pointerthe_move
- pointer to move datadamage_out
- struct containing info about the damage calculationfaint_reason
- faint reason
sourcefn can_target_entity(&self, target: &DungeonEntity) -> bool
fn can_target_entity(&self, target: &DungeonEntity) -> bool
Checks if a monster can target another entity when controlled by the AI.
More specifically, it checks if the target is invisible, if the user can see invisible
monsters, if the user is blinded and if the target position is in sight from the position
of the user (this last check is done by calling is_position_in_sight
with the user’s and the target’s position).
sourcefn can_target_position(&self, target: &position) -> bool
fn can_target_position(&self, target: &position) -> bool
Checks if a monster can target a position. This function just calls
is_position_in_sight
using the position of the user as the origin.
sourcefn is_aura_bow_active(&self) -> bool
fn is_aura_bow_active(&self) -> bool
Checks if a monster is holding an aura bow that isn’t disabled by Klutz.
sourcefn get_exclusive_item_offense_boost(&self, move_category: MoveCategory) -> i32
fn get_exclusive_item_offense_boost(&self, move_category: MoveCategory) -> i32
Gets the exclusive item boost for attack/special attack for a monster. Panics if the move category is not physical or special.
sourcefn get_exclusive_item_defense_boost(&self, move_category: MoveCategory) -> i32
fn get_exclusive_item_defense_boost(&self, move_category: MoveCategory) -> i32
Gets the exclusive item boost for defense/special defense for a monster. Panics if the move category is not physical or special.
sourcefn has_conditional_ground_immunity(&self) -> bool
fn has_conditional_ground_immunity(&self) -> bool
Checks if a monster is currently immune to Ground-type moves for reasons other than typing and ability.
This includes checks for Gravity and Magnet Rise.
sourcefn get_move_target_and_range(
&self,
the_move: &Move,
is_ai: bool
) -> MoveTargetAndRange
fn get_move_target_and_range( &self, the_move: &Move, is_ai: bool ) -> MoveTargetAndRange
Gets the move target-and-range field when used by a given entity.
The fourth field in the returned tuple seems unused. The values in the returned tuple are None, if they are invalid (or we don’t know them yet).
See Move::get_target_and_range
for more information.
sourcefn get_apparent_weather(&self) -> Option<Weather>
fn get_apparent_weather(&self) -> Option<Weather>
Get the weather, as experienced by the monster.
sourcefn has_held_item(&self, item_id: ItemId) -> bool
fn has_held_item(&self, item_id: ItemId) -> bool
Checks if the monster has a certain held item.
sourcefn get_move_power(&self, the_move: &Move) -> i32
fn get_move_power(&self, the_move: &Move) -> i32
Gets the power of a move, factoring in Ginseng/Space Globe boosts.
sourcefn get_personality_index(&self) -> i32
fn get_personality_index(&self) -> i32
Note: unverified, ported from Irdkwia’s notes
sourcefn calc_status_duration(&self, turn_range: &[u16; 2], effects: bool) -> i32
fn calc_status_duration(&self, turn_range: &[u16; 2], effects: bool) -> i32
Seems to calculate the duration of a volatile status on a monster.
Returns the number of turns for the status condition.
Arguments
turn_range
- lower & higher ends of the turn rangeeffects
- flag for whether or not to factor in the Self Curer IQ skill and the Natural Cure ability
sourcefn get_number_of_attacks(&self) -> i32
fn get_number_of_attacks(&self) -> i32
Returns the number of attacks that a monster can do in one turn (1 or 2).
Checks for the abilities Swift Swim, Chlorophyll, Unburden, and for exclusive items.
sourcefn is_levitating(&self) -> bool
fn is_levitating(&self) -> bool
Checks if a monster is levitating (has the effect of Levitate and Gravity is not active)
sourcefn is_type_affected_by_gravity(&self, type_id: type_id) -> bool
fn is_type_affected_by_gravity(&self, type_id: type_id) -> bool
Checks if Gravity is active and that the given type is affected (i.e., Flying type).
sourcefn has_type_affected_by_gravity(&self, type_id: type_id) -> bool
fn has_type_affected_by_gravity(&self, type_id: type_id) -> bool
Checks if Gravity is active and that this monster is of an affected type (i.e., Flying type).
sourcefn is_conversion2_active(&self) -> Option<Conversion2Status>
fn is_conversion2_active(&self) -> Option<Conversion2Status>
Checks if the monster is under the effect of Conversion 2 (its type was changed). Returns
None
if the value is invalid.
sourcefn get_move_type_if_used_by_self(&self, the_move: &Move) -> MonsterTypeId
fn get_move_type_if_used_by_self(&self, the_move: &Move) -> MonsterTypeId
Check the type of a move when used by a certain monster. Accounts for special cases such as Hidden Power, Weather Ball, the regular attack…
sourcefn get_sleep_animation_id(&self) -> u8
fn get_sleep_animation_id(&self) -> u8
Returns the animation id to be applied to a monster that has the sleep, napping, nightmare or bide status.
sourcefn is_blinded(&self, check_held_item: bool) -> bool
fn is_blinded(&self, check_held_item: bool) -> bool
Returns true if the monster has the blinded status, or if it is not the leader and is holding Y-Ray Specs.
sourcefn should_monster_run_away(&self) -> bool
fn should_monster_run_away(&self) -> bool
Checks if a monster should run away from other monsters.
sourceunsafe fn should_monster_run_away_variation(&self, param: undefined) -> bool
unsafe fn should_monster_run_away_variation(&self, param: undefined) -> bool
Calls Self::should_monster_run_away
and returns its result.
It also calls another function if the result was true.
Safety
The caller must make sure the undefined params are valid for this function.
sourceunsafe fn should_monster_run_away_variation_outlaw_check(
&self,
param: undefined
) -> bool
unsafe fn should_monster_run_away_variation_outlaw_check( &self, param: undefined ) -> bool
Calls Self::should_monster_run_away_variation
. If the result is true, returns true.
Otherwise, returns true only if the monster’s behavior field is equal to
ffi::monster_behavior::BEHAVIOR_FLEEING_OUTLAW
.
Safety
The caller must make sure the undefined params are valid for this function.
sourcefn should_head_to_stairs(&self) -> bool
fn should_head_to_stairs(&self) -> bool
Checks if this monster should try to reach the stairs when controlled by the AI.
sourcefn has_status_that_prevents_acting(&self) -> bool
fn has_status_that_prevents_acting(&self) -> bool
Returns true if the monster has any status problem that prevents it from acting.
sourcefn is_cornered(&self) -> bool
fn is_cornered(&self) -> bool
True if ths monster is cornered (it can’t move in any direction)
sourcefn can_attack_in_direction(&self, direction: Direction) -> bool
fn can_attack_in_direction(&self, direction: Direction) -> bool
Returns whether a monster can attack in a given direction.
The check fails if the destination tile is impassable, contains a monster that isn’t of
type DungeonEntityType::Monster
or if the monster can’t directly move
from the current tile into the destination tile.
sourcefn ai_obstruction_in_direction(&self, direction: Direction) -> Option<bool>
fn ai_obstruction_in_direction(&self, direction: Direction) -> Option<bool>
Returns whether the AI could not move the monster in the specified direction.
Accounts for walls, other monsters on the target position and IQ skills that might prevent a monster from moving into a specific location, such as House Avoider, Trap Avoider or Lava Evader.
Returns a None
if there are no obstructions. If there are, the Some
contains a boolean,
that is true if the way is blocked by another entity.
sourcefn can_see_invisible_monsters(&self) -> bool
fn can_see_invisible_monsters(&self) -> bool
Returns whether this monster can see other invisible monsters.
To be precise, this function returns true if the monster is holding Goggle Specs or if it
has the status ffi::status_id::STATUS_EYEDROPS
.
sourcefn has_dropeye_status(&self) -> bool
fn has_dropeye_status(&self) -> bool
Returns whether a certain monster is under the effect of ffi::status_id::STATUS_DROPEYE
.
sourcefn is_target_eligible(
&self,
move_ai_range: MoveTargetAndRange,
target: &DungeonEntity,
the_move: &Move,
check_all_conditions: bool
) -> bool
fn is_target_eligible( &self, move_ai_range: MoveTargetAndRange, target: &DungeonEntity, the_move: &Move, check_all_conditions: bool ) -> bool
Checks if a given target is eligible to be targeted by the AI with a certain move.
If check_all_conditions
is true
check all the possible MoveAiCondition
values,
false to only check for MoveAiCondition::Random
(if the move has a different
ai condition, the result will be false
).
Panics if any field in the MoveTargetAndRange
is None or the conversion into the ffi
type fails for any other reason.
sourcefn can_use_move(&self, the_move: &Move, extra_checks: bool) -> bool
fn can_use_move(&self, the_move: &Move, extra_checks: bool) -> bool
Checks if a monster can use the given move. Will always return true for the regular attack.
Will return false if the move if the flag Move::f_disabled
is true, if the flag
Move::f_sealed
is true.
If extra_checks
is true check whether the move is out of PP, whether it can be used under
the taunted status and whether the encore status prevents using the move.
sourceunsafe fn can_ai_use_move_unchecked(
&self,
move_index: i32,
extra_checks: bool
) -> bool
unsafe fn can_ai_use_move_unchecked( &self, move_index: i32, extra_checks: bool ) -> bool
Checks if an AI-controlled monster can use a move.
Will return false if the any of the flags Move::f_exists
,
Move::f_subsequent_in_link_chain
or Move::f_disabled
is true. The function does not
check if the flag Move::f_enabled_for_ai
is set.
This function also returns true if the call to Self::can_use_move
is true.
The function contains a loop that is supposed to check other moves after the specified one,
but the loop breaks after it finds a move that isn’t linked, which is always true given the
checks in place at the start of the function.
If extra_checks
is true check whether the move is out of PP, whether it can be used under
the taunted status and whether the encore status prevents using the move.
Safety
The caller must make sure the move index is not out of bounds (normally 0-3).
sourcefn can_ai_use_move(&self, move_index: u8, extra_checks: bool) -> bool
fn can_ai_use_move(&self, move_index: u8, extra_checks: bool) -> bool
Checked version of Self::can_ai_use_move_unchecked
, that panics if the move index
is > 3.
sourcefn status_checker_check(&self, the_move: &Move) -> bool
fn status_checker_check(&self, the_move: &Move) -> bool
Determines if using a given move against its intended targets would be redundant because all of them already have the effect caused by said move.
Returns true if it makes sense to use the move, false if it would be redundant given the effects it causes and the effects that all the targets already have.
sourcefn get_monster_apparent_id(&self, current_id: MonsterSpeciesId) -> i32
fn get_monster_apparent_id(&self, current_id: MonsterSpeciesId) -> i32
Note: unverified, ported from Irdkwia’s notes
sourceunsafe fn get_monster_name(&self, output: *mut c_char)
unsafe fn get_monster_name(&self, output: *mut c_char)
Note: unverified, ported from Irdkwia’s notes
Safety
It’s unknown what size the string passed in must be.
sourcefn is_target_recruited(&self, target: &DungeonEntity) -> bool
fn is_target_recruited(&self, target: &DungeonEntity) -> bool
Note: unverified, ported from Irdkwia’s notes
sourcefn is_satisfying_scenario_condition_to_spawn(&self) -> bool
fn is_satisfying_scenario_condition_to_spawn(&self) -> bool
Note: unverified, ported from Irdkwia’s notes
sourcefn is_in_spawn_list(&self, spawn_list: &mut undefined) -> bool
fn is_in_spawn_list(&self, spawn_list: &mut undefined) -> bool
Note: unverified, ported from Irdkwia’s notes
Safety
The caller must make sure the undefined params are valid for this function.