mirror of
https://github.com/pret/pmd-sky.git
synced 2026-03-21 17:25:15 -05:00
Decomped MonsterHasLeechSeedStatus
This commit is contained in:
parent
fec6c0b961
commit
25cdaadd1e
|
|
@ -1,19 +1,8 @@
|
|||
.include "asm/macros.inc"
|
||||
.include "overlay_29_02300588.inc"
|
||||
.include "overlay_29_023005A4.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start MonsterHasLeechSeedStatus
|
||||
MonsterHasLeechSeedStatus: ; 0x02300588
|
||||
ldr r0, [r0, #0xb4]
|
||||
ldrb r0, [r0, #0xe0]
|
||||
cmp r0, #1
|
||||
moveq r0, #1
|
||||
movne r0, #0
|
||||
and r0, r0, #0xff
|
||||
bx lr
|
||||
arm_func_end MonsterHasLeechSeedStatus
|
||||
|
||||
arm_func_start MonsterHasWhifferStatus
|
||||
MonsterHasWhifferStatus: ; 0x023005A4
|
||||
ldr r0, [r0, #0xb4]
|
||||
|
|
@ -15,5 +15,6 @@ bool8 MonsterHasImmobilizingStatus(struct entity *monster);
|
|||
bool8 MonsterHasAttackInterferingStatus(struct entity *monster);
|
||||
// Checks if a monster has one of the non-self-inflicted statuses in the "curse" group, which loosely includes status conditions that interfere with the monster's skills or ability to do things: STATUS_CURSED, STATUS_DECOY, STATUS_GASTRO_ACID, STATUS_HEAL_BLOCK, STATUS_EMBARGO.
|
||||
bool8 MonsterHasSkillInterferingStatus(struct entity *monster);
|
||||
bool8 MonsterHasLeechSeedStatus(struct entity *monster);
|
||||
|
||||
#endif //PMDSKY_DUNGEON_LOGIC_0_H
|
||||
|
|
|
|||
|
|
@ -174,6 +174,20 @@ struct curse_class_status {
|
|||
u8 curse_damage_countdown;
|
||||
};
|
||||
|
||||
struct leech_seed_class_status {
|
||||
u8 leech_seed; // 0x0: STATUS_LEECH_SEED if 1
|
||||
// 0x4: Used to track the statuses::statuses_unique_id of the relevant monster for
|
||||
// statuses like Leech Seed and Destiny Bond.
|
||||
u32 statuses_applier_id;
|
||||
// 0x8: Index into entity_table_hdr::monster_slot_ptrs in the dungeon that the user
|
||||
// (drainer) is held.
|
||||
u8 leech_seed_source_monster_index;
|
||||
u8 leech_seed_turns; // 0x9: Turns left for the status in statuses::leech_seed
|
||||
// 0xA: Turns left until residual damage for the status in statuses::leech_seed, if applicable.
|
||||
// Behaves weirdly without an afflictor
|
||||
u8 leech_seed_damage_countdown;
|
||||
};
|
||||
|
||||
struct long_toss_class_status {
|
||||
u8 status; // 0x0: STATUS_LONG_TOSS if 1
|
||||
};
|
||||
|
|
@ -296,21 +310,7 @@ struct monster {
|
|||
struct bide_class_status bide_class_status; // 0xD2
|
||||
struct reflect_class_status reflect_class_status; // 0xD5
|
||||
struct curse_class_status curse_class_status; // 0xD8
|
||||
u8 leech_seed; // 0xE0: STATUS_LEECH_SEED if 1
|
||||
u8 field_0xe1;
|
||||
u8 field_0xe2;
|
||||
u8 field_0xe3;
|
||||
// 0xE4: Used to track the statuses::statuses_unique_id of the relevant monster for
|
||||
// statuses like Leech Seed and Destiny Bond.
|
||||
u32 statuses_applier_id;
|
||||
// 0xE8: Index into entity_table_hdr::monster_slot_ptrs in the dungeon that the user
|
||||
// (drainer) is held.
|
||||
u8 leech_seed_source_monster_index;
|
||||
u8 leech_seed_turns; // 0xE9: Turns left for the status in statuses::leech_seed
|
||||
// 0xEA: Turns left until residual damage for the status in statuses::leech_seed, if applicable.
|
||||
// Behaves weirdly without an afflictor
|
||||
u8 leech_seed_damage_countdown;
|
||||
u8 field_0xEB;
|
||||
struct leech_seed_class_status leech_seed_class_status; // 0xE0
|
||||
u8 sure_shot; // 0xEC: STATUS_SURE_SHOT if 1
|
||||
u8 sure_shot_turns; // 0xED: Turns left for the status in statuses::sure_shot
|
||||
struct long_toss_class_status long_toss_class_status; // 0xEE
|
||||
|
|
|
|||
2
main.lsf
2
main.lsf
|
|
@ -297,7 +297,7 @@ Overlay OVY_29
|
|||
Object src/overlay_29_023000E4.o
|
||||
Object asm/overlay_29_02300108.o
|
||||
Object src/dungeon_logic_0.o
|
||||
Object asm/overlay_29_02300588.o
|
||||
Object asm/overlay_29_023005A4.o
|
||||
Object src/dungeon_logic.o
|
||||
Object asm/overlay_29_023007A8.o
|
||||
Object src/dungeon_capabilities.o
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
#include "dungeon_logic_0.h"
|
||||
#include "dungeon_util_static.h"
|
||||
|
||||
extern bool8 MonsterHasLeechSeedStatus(struct entity *monster);
|
||||
extern bool8 MonsterHasWhifferStatus(struct entity *monster);
|
||||
extern bool8 IsMonsterVisuallyImpaired(struct entity *monster, bool8 check_held_item);
|
||||
extern bool8 IsMonsterMuzzled(struct entity *monster);
|
||||
|
|
|
|||
|
|
@ -57,3 +57,8 @@ bool8 MonsterHasSkillInterferingStatus(struct entity *monster)
|
|||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
bool8 MonsterHasLeechSeedStatus(struct entity *monster)
|
||||
{
|
||||
return GetEntInfo(monster)->leech_seed_class_status.leech_seed == STATUS_LEECH_SEED_LEECH_SEED;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user