Decomped DefenderAbilityIsActive

This commit is contained in:
AnonymousRandomPerson 2025-09-20 22:23:01 -04:00
parent 43a1379025
commit b8e95f9fab
26 changed files with 229 additions and 348 deletions

View File

@ -2,24 +2,24 @@
.public AbilityIsActiveVeneer
.public CASTFORM_WEATHER_ATTRIBUTE_TABLE
.public DUNGEON_PTR
.public DefenderAbilityIsActive__022F96CC
.public DungeonRandInt
.public EntityIsValid__022F7364
.public GetAbility
.public GetApparentWeather
.public GetMoveTypeForMonster
.public GetType
.public IsMonster__022F9720
.public IsSecretBazaarNpcBehavior
.public IsSecretFloor
.public LogMessageByIdWithPopupCheckUser
.public LogMessageByIdWithPopupCheckUserTarget
.public LowerSpeed
.public MonsterIsType
.public ov10_022C4C6E
.public ov10_022C4C70
.public ov29_022E6260
.public ov29_022E647C
.public SetPreprocessorArgsIdVal
.public SubstitutePlaceholderStringTags
.public TryEndStatusWithAbility
.public WEATHER_BALL_TYPE_TABLE
.public ov10_022C4C6E
.public ov10_022C4C70
.public ov29_022E6260
.public ov29_022E647C

View File

@ -1,7 +1,6 @@
#pragma once
.public AbilityIsActive
.public DefenderAbilityIsActive__02301A0C
.public GetApparentWeather
.public IsExperienceLocked
.public IsMonster__02301A60
.public LogMessageByIdWithPopupCheckUserTarget
.public SubstitutePlaceholderStringTags

View File

@ -1,6 +1,5 @@
#pragma once
.public AbilityIsActiveVeneer
.public abs
.public ActivateMotorDrive
.public AddExpSpecial
.public AdvanceFrame
@ -11,14 +10,15 @@
.public ChangeDungeonMusic
.public ChangeMonsterAnimation
.public DAMAGE_STRING_IDS
.public DisplayAnimatedNumbers
.public DUNGEON_PTR
.public DefenderAbilityIsActive__0230A940
.public DisplayAnimatedNumbers
.public DungeonRandOutcome__022EAB20
.public EndCurseClassStatus
.public EndInvisibleClassStatus
.public EntityIsValid__02308FBC
.public ExclusiveItemEffectIsActive__0230A9B8
.public ExclusiveItemEffectIsActiveWithLogging
.public ExclusiveItemEffectIsActive__0230A9B8
.public FreeOtherWrappedMonsters
.public GetActiveTeamMember
.public GetDirectionTowardsPosition
@ -30,7 +30,6 @@
.public IsBlinded
.public IsCurrentMissionType
.public IsExperienceLocked
.public IsMonster__0230A994
.public IsMonsterIdInNormalRangeVeneer
.public IsSecretBazaarNpcBehavior
.public IsSpecialStoryAlly
@ -42,6 +41,30 @@
.public LogMessageByIdWithPopupCheckUserTarget
.public MoveMonsterToPos
.public MusicTableIdxToMusicId
.public PlayEffectAnimationEntity
.public RecruitCheck
.public RemoveHolderForItemInBag
.public RestorePpAllMovesSetFlags
.public RestoreRandomMovePP
.public SET_DAMAGE_STATUS_DAMAGE
.public SetMessageLogPreprocessorArgsNumberVal
.public SetMonsterFlag2
.public SetPokemonBattled
.public ShouldDisplayEntityWrapper
.public SpawnDroppedItemWrapper
.public SubInitMonster
.public SubstitutePlaceholderStringTags
.public TYPE_DAMAGE_NEGATING_EXCLUSIVE_ITEM_EFFECTS
.public TryEndPetrifiedOrSleepStatus
.public TryIncreaseHp
.public TryRecruit
.public TrySpawnEnemyItemDrop
.public UpdateAiTargetPos
.public UpdateEntityPixelPos
.public UpdateShopkeeperModeAfterAttack
.public UpdateStatusIconFlags
.public UpdateTrapsVisibility
.public abs
.public ov10_022BDC68
.public ov10_022BDE50
.public ov10_022BF964
@ -95,27 +118,4 @@
.public ov29_02353234
.public ov29_023535D4
.public ov29_0237CA6C
.public PlayEffectAnimationEntity
.public RecruitCheck
.public RemoveHolderForItemInBag
.public RestorePpAllMovesSetFlags
.public RestoreRandomMovePP
.public SET_DAMAGE_STATUS_DAMAGE
.public SetMessageLogPreprocessorArgsNumberVal
.public SetMonsterFlag2
.public SetPokemonBattled
.public ShouldDisplayEntityWrapper
.public SpawnDroppedItemWrapper
.public sub_0204AF00
.public SubInitMonster
.public SubstitutePlaceholderStringTags
.public TryEndPetrifiedOrSleepStatus
.public TryIncreaseHp
.public TryRecruit
.public TrySpawnEnemyItemDrop
.public TYPE_DAMAGE_NEGATING_EXCLUSIVE_ITEM_EFFECTS
.public UpdateAiTargetPos
.public UpdateEntityPixelPos
.public UpdateShopkeeperModeAfterAttack
.public UpdateStatusIconFlags
.public UpdateTrapsVisibility

View File

@ -1,5 +1,5 @@
#pragma once
.public AbilityIsActiveVeneer
.public DefenderAbilityIsActive__02311B94
.public EntityIsValid__023118B4
.public ExclusiveItemEffectIsActiveWithLogging
.public InflictSleepStatusSingle
@ -7,8 +7,8 @@
.public IsProtectedFromNegativeStatus
.public ItemIsActive__02311BF8
.public LogMessageByIdWithPopupCheckUserTarget
.public ov29_022E3E74
.public ov29_02304A48
.public SafeguardIsActive
.public SubstitutePlaceholderStringTags
.public TryActivateQuickFeet
.public ov29_022E3E74
.public ov29_02304A48

View File

@ -9,6 +9,7 @@
.public BuildMoveTargetList
.public CalcStatusDuration
.public CanMonsterUseMove
.public DefenderAbilityIsActive__02322D64
.public DungeonRandInt
.public EndFrozenClassStatus
.public EndLeechSeedClassStatus
@ -24,15 +25,15 @@
.public GetMoveNbStrikes
.public GetNaturePowerVariant
.public GravityIsActive
.public INTIMIDATOR_ACTIVATION_CHANCE
.public InitMove
.public InitMoveCheckId
.public INTIMIDATOR_ACTIVATION_CHANCE
.public IqSkillIsEnabled
.public Is2TurnsMove
.public IsChargingTwoTurnMove
.public IsFloorOver
.public IsMonster__02322DB8
.public IsMonsterSleeping
.public IsMonster__02322DB8
.public IsTrappingMove
.public LogMessageByIdWithPopupCheckUser
.public LogMessageWithPopupCheckUser
@ -42,6 +43,30 @@
.public MonsterCannotAttack
.public NATURE_POWER_TABLE
.public NIGHTMARE_TURN_RANGE
.public ResetTriggerFlags
.public SLEEP_TURN_RANGE
.public SetPreprocessorArgsIdVal
.public SetPreprocessorArgsStringToName
.public StringFromId
.public SubstitutePlaceholderStringTags
.public TryInflictBlinkerStatus
.public TryInflictBurnStatus
.public TryInflictConfusedStatus
.public TryInflictConstrictionStatus
.public TryInflictCringeStatus
.public TryInflictFrozenStatus
.public TryInflictInfatuatedStatus
.public TryInflictInvisibleStatus
.public TryInflictNightmareStatus
.public TryInflictParalysisStatus
.public TryInflictPausedStatus
.public TryInflictPerishSongStatus
.public TryInflictPoisonedStatus
.public TryInflictShadowHoldStatus
.public TryInflictSleepStatus
.public TrySealMove
.public TryWarp
.public UpdateAiTargetPos
.public ov10_022BFD6C
.public ov10_022C4584
.public ov10_022C4714
@ -62,28 +87,4 @@
.public ov29_02344B9C
.public ov29_0235370C
.public ov29_0237CA68
.public ResetTriggerFlags
.public SetPreprocessorArgsIdVal
.public SetPreprocessorArgsStringToName
.public SLEEP_TURN_RANGE
.public StringFromId
.public sub_0201D1B0
.public SubstitutePlaceholderStringTags
.public TryInflictBlinkerStatus
.public TryInflictBurnStatus
.public TryInflictConfusedStatus
.public TryInflictConstrictionStatus
.public TryInflictCringeStatus
.public TryInflictFrozenStatus
.public TryInflictInfatuatedStatus
.public TryInflictInvisibleStatus
.public TryInflictNightmareStatus
.public TryInflictParalysisStatus
.public TryInflictPausedStatus
.public TryInflictPerishSongStatus
.public TryInflictPoisonedStatus
.public TryInflictShadowHoldStatus
.public TryInflictSleepStatus
.public TrySealMove
.public TryWarp
.public UpdateAiTargetPos

View File

@ -1,18 +1,11 @@
#pragma once
.public AbilityIsActiveVeneer
.public abs
.public ApplyDamageAndEffects
.public CalcDamage
.public CanAttackInDirection
.public CanLayTrap
.public CanSeeTarget
.public CeilFixedPoint
.public Conversion2IsActive
.public DisplayAnimatedNumbers
.public DUNGEON_PTR
.public DefenderAbilityIsActive__02332A0C
.public DisplayAnimatedNumbers
.public EntityIsValid__0232E840
.public EntityIsValid__02333FAC
.public GetApparentWeather
.public GetDamageSourceWrapper
.public GetDirectionTowardsPosition
.public GetMessageLogPreprocessorArgs
@ -20,20 +13,12 @@
.public GetMoveCritChance
.public GetMovePower
.public GetMoveTypeForMonster
.public GetTileAtEntity
.public IsCurrentFixedRoomBossFight
.public IsTileGround
.public LogMessageByIdQuietCheckUserTarget
.public LogMessageByIdWithPopupCheckUserTarget
.public MirrorMoveIsActive
.public MistIsActive
.public MonsterHasNegativeStatus
.public MonsterHasQuarterHp
.public MonsterIsType
.public MoveHitCheck
.public ov10_022C6322
.public SetPreprocessorArgsStringToName
.public ShouldDisplayEntityWrapper
.public abs
.public ov29_022E576C
.public ov29_02304A48
.public ov29_0230D088
.public SetPreprocessorArgsStringToName
.public ShouldDisplayEntityWrapper

View File

@ -428,51 +428,3 @@ _022F96C4: .word WEATHER_BALL_TYPE_TABLE
_022F96C8: .word 0x00000C19
#endif
arm_func_end TryActivateTraceAndColorChange
arm_func_start DefenderAbilityIsActive__022F96CC
DefenderAbilityIsActive__022F96CC: ; 0x022F96CC
#ifdef JAPAN
stmdb sp!, {r4, r5, r6, lr}
mov r6, r0
mov r5, r1
mov r4, r2
cmp r6, r5
#else
stmdb sp!, {r3, r4, r5, r6, r7, lr}
mov r7, r0
mov r6, r1
mov r5, r2
mov r4, r3
cmp r7, r6
#endif
beq _022F9710
bl IsMonster__022F9720
cmp r0, #0
#ifdef JAPAN
beq _022F9710
mov r0, r6
#else
cmpne r4, #0
beq _022F9710
mov r0, r7
#endif
mov r1, #0x53
bl AbilityIsActiveVeneer
cmp r0, #0
movne r0, #0
#ifdef JAPAN
ldmneia sp!, {r4, r5, r6, pc}
_022F9710:
mov r0, r5
mov r1, r4
bl AbilityIsActiveVeneer
ldmia sp!, {r4, r5, r6, pc}
#else
ldmneia sp!, {r3, r4, r5, r6, r7, pc}
_022F9710:
mov r0, r6
mov r1, r5
bl AbilityIsActiveVeneer
ldmia sp!, {r3, r4, r5, r6, r7, pc}
#endif
arm_func_end DefenderAbilityIsActive__022F96CC

View File

@ -125,51 +125,3 @@ _02301A08: .word 0x00000976
_02301A08: .word 0x00000C37
#endif
arm_func_end LeafGuardIsActive
arm_func_start DefenderAbilityIsActive__02301A0C
DefenderAbilityIsActive__02301A0C: ; 0x02301A0C
#ifdef JAPAN
stmdb sp!, {r4, r5, r6, lr}
mov r6, r0
mov r5, r1
mov r4, r2
cmp r6, r5
#else
stmdb sp!, {r3, r4, r5, r6, r7, lr}
mov r7, r0
mov r6, r1
mov r5, r2
mov r4, r3
cmp r7, r6
#endif
beq _02301A50
bl IsMonster__02301A60
cmp r0, #0
#ifdef JAPAN
beq _02301A50
mov r0, r6
#else
cmpne r4, #0
beq _02301A50
mov r0, r7
#endif
mov r1, #0x53
bl AbilityIsActive
cmp r0, #0
movne r0, #0
#ifdef JAPAN
ldmneia sp!, {r4, r5, r6, pc}
_02301A50:
mov r0, r5
mov r1, r4
bl AbilityIsActive
ldmia sp!, {r4, r5, r6, pc}
#else
ldmneia sp!, {r3, r4, r5, r6, r7, pc}
_02301A50:
mov r0, r6
mov r1, r5
bl AbilityIsActive
ldmia sp!, {r3, r4, r5, r6, r7, pc}
#endif
arm_func_end DefenderAbilityIsActive__02301A0C

View File

@ -3514,51 +3514,3 @@ _0230B3A8: .word 0x02353E40
_0230A938: .word ov10_022C593C
_0230A93C: .word ov29_0237CA6C
arm_func_end ApplyDamage
arm_func_start DefenderAbilityIsActive__0230A940
DefenderAbilityIsActive__0230A940: ; 0x0230A940
#ifdef JAPAN
stmdb sp!, {r4, r5, r6, lr}
mov r6, r0
mov r5, r1
mov r4, r2
cmp r6, r5
#else
stmdb sp!, {r3, r4, r5, r6, r7, lr}
mov r7, r0
mov r6, r1
mov r5, r2
mov r4, r3
cmp r7, r6
#endif
beq _0230A984
bl IsMonster__0230A994
cmp r0, #0
#ifdef JAPAN
beq _0230A984
mov r0, r6
#else
cmpne r4, #0
beq _0230A984
mov r0, r7
#endif
mov r1, #0x53
bl AbilityIsActiveVeneer
cmp r0, #0
movne r0, #0
#ifdef JAPAN
ldmneia sp!, {r4, r5, r6, pc}
_0230A984:
mov r0, r5
mov r1, r4
bl AbilityIsActiveVeneer
ldmia sp!, {r4, r5, r6, pc}
#else
ldmneia sp!, {r3, r4, r5, r6, r7, pc}
_0230A984:
mov r0, r6
mov r1, r5
bl AbilityIsActiveVeneer
ldmia sp!, {r3, r4, r5, r6, r7, pc}
#endif
arm_func_end DefenderAbilityIsActive__0230A940

View File

@ -216,36 +216,3 @@ _02311B88: .word 0x00000DA6 + IS_PROTECTED_FROM_SLEEP_CLASS_STATUS_OFFSET
_02311B8C: .word 0x00000DB1 + IS_PROTECTED_FROM_SLEEP_CLASS_STATUS_OFFSET
_02311B90: .word 0x00000DC2 + IS_PROTECTED_FROM_SLEEP_CLASS_STATUS_OFFSET
arm_func_end IsProtectedFromSleepClassStatus
arm_func_start DefenderAbilityIsActive__02311B94
DefenderAbilityIsActive__02311B94: ; 0x02311B94
stmdb sp!, {r3, r4, r5, lr}
mov r5, r1
mov r4, r2
cmp r0, r5
beq _02311BE8
cmp r0, #0
moveq r1, #0
beq _02311BC8
ldr r1, [r0]
cmp r1, #1
moveq r1, #1
movne r1, #0
and r1, r1, #0xff
_02311BC8:
cmp r1, #0
#ifndef JAPAN
cmpne r3, #0
#endif
beq _02311BE8
mov r1, #0x53
bl AbilityIsActiveVeneer
cmp r0, #0
movne r0, #0
ldmneia sp!, {r3, r4, r5, pc}
_02311BE8:
mov r0, r5
mov r1, r4
bl AbilityIsActiveVeneer
ldmia sp!, {r3, r4, r5, pc}
arm_func_end DefenderAbilityIsActive__02311B94

View File

@ -1845,51 +1845,3 @@ _02322D58: .word ov29_0235370C
_02322D5C: .word 0x00000EA9 + OV29_02322374_DATA_OFFSET
_02322D60: .word 0x000001F6
arm_func_end ov29_02322374
arm_func_start DefenderAbilityIsActive__02322D64
DefenderAbilityIsActive__02322D64: ; 0x02322D64
#ifdef JAPAN
stmdb sp!, {r4, r5, r6, lr}
mov r6, r0
mov r5, r1
mov r4, r2
cmp r6, r5
#else
stmdb sp!, {r3, r4, r5, r6, r7, lr}
mov r7, r0
mov r6, r1
mov r5, r2
mov r4, r3
cmp r7, r6
#endif
beq _02322DA8
bl IsMonster__02322DB8
cmp r0, #0
#ifdef JAPAN
beq _02322DA8
mov r0, r6
#else
cmpne r4, #0
beq _02322DA8
mov r0, r7
#endif
mov r1, #0x53
bl AbilityIsActiveVeneer
cmp r0, #0
movne r0, #0
#ifdef JAPAN
ldmneia sp!, {r4, r5, r6, pc}
_02322DA8:
mov r0, r5
mov r1, r4
bl AbilityIsActiveVeneer
ldmia sp!, {r4, r5, r6, pc}
#else
ldmneia sp!, {r3, r4, r5, r6, r7, pc}
_02322DA8:
mov r0, r6
mov r1, r5
bl AbilityIsActiveVeneer
ldmia sp!, {r3, r4, r5, r6, r7, pc}
#endif
arm_func_end DefenderAbilityIsActive__02322D64

View File

@ -1,41 +1,8 @@
.include "asm/macros.inc"
.include "overlay_29_02332A0C.inc"
.include "overlay_29_02332A70.inc"
.text
arm_func_start DefenderAbilityIsActive__02332A0C
DefenderAbilityIsActive__02332A0C: ; 0x02332A0C
stmdb sp!, {r3, r4, r5, lr}
mov r5, r1
mov r4, r2
cmp r0, r5
beq _02332A60
cmp r0, #0
moveq r1, #0
beq _02332A40
ldr r1, [r0]
cmp r1, #1
moveq r1, #1
movne r1, #0
and r1, r1, #0xff
_02332A40:
cmp r1, #0
#ifndef JAPAN
cmpne r3, #0
#endif
beq _02332A60
mov r1, #0x53
bl AbilityIsActiveVeneer
cmp r0, #0
movne r0, #0
ldmneia sp!, {r3, r4, r5, pc}
_02332A60:
mov r0, r5
mov r1, r4
bl AbilityIsActiveVeneer
ldmia sp!, {r3, r4, r5, pc}
arm_func_end DefenderAbilityIsActive__02332A0C
arm_func_start DoMoveDamageInlined
DoMoveDamageInlined: ; 0x02332A70
stmdb sp!, {r3, r4, r5, r6, r7, r8, sb, lr}

View File

@ -3,6 +3,12 @@
#include "dungeon_mode.h"
// Checks if a defender has an active ability that isn't disabled by an attacker's Mold Breaker.
#ifdef JAPAN
bool8 DefenderAbilityIsActive__022F96CC(struct entity *attacker, struct entity *defender, enum ability_id ability_id);
#else
bool8 DefenderAbilityIsActive__022F96CC(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled);
#endif
// Checks if an entity is a monster (entity type 1).
bool8 IsMonster__022F9720(struct entity *entity);

View File

@ -3,6 +3,12 @@
#include "dungeon_mode.h"
// Checks if a defender has an active ability that isn't disabled by an attacker's Mold Breaker.
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02301A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id);
#else
bool8 DefenderAbilityIsActive__02301A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled);
#endif
// Checks if an entity is a monster (entity type 1).
bool8 IsMonster__02301A60(struct entity *entity);

View File

@ -3,6 +3,12 @@
#include "dungeon_mode.h"
// Checks if a defender has an active ability that isn't disabled by an attacker's Mold Breaker.
#ifdef JAPAN
bool8 DefenderAbilityIsActive__0230A940(struct entity *attacker, struct entity *defender, enum ability_id ability_id);
#else
bool8 DefenderAbilityIsActive__0230A940(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled);
#endif
// Checks if an entity is a monster (entity type 1).
bool8 IsMonster__0230A994(struct entity *entity);
// Checks if a monster is a team member under the effects of a certain exclusive item effect.

View File

@ -3,6 +3,12 @@
#include "dungeon_mode.h"
// Checks if a defender has an active ability that isn't disabled by an attacker's Mold Breaker.
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02311B94(struct entity *attacker, struct entity *defender, enum ability_id ability_id);
#else
bool8 DefenderAbilityIsActive__02311B94(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled);
#endif
// Checks if a monster is holding a certain item that isn't disabled by Klutz.
bool8 ItemIsActive__02311BF8(struct entity *entity, enum item_id item_id);

View File

@ -3,6 +3,12 @@
#include "dungeon_mode.h"
// Checks if a defender has an active ability that isn't disabled by an attacker's Mold Breaker.
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02322D64(struct entity *attacker, struct entity *defender, enum ability_id ability_id);
#else
bool8 DefenderAbilityIsActive__02322D64(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled);
#endif
// Checks if an entity is a monster (entity type 1).
bool8 IsMonster__02322DB8(struct entity *entity);

View File

@ -5,5 +5,11 @@
// Checks if a monster is a team member under the effects of a certain exclusive item effect.
bool8 ExclusiveItemEffectIsActive__023329E8(struct entity *entity, enum exclusive_item_effect_id effect_id);
// Checks if a defender has an active ability that isn't disabled by an attacker's Mold Breaker.
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02332A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id);
#else
bool8 DefenderAbilityIsActive__02332A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled);
#endif
#endif //PMDSKY_OVERLAY_29_023329E8_H

View File

@ -564,7 +564,7 @@ Overlay OVY_29
Object src/overlay_29_0232E840.o
Object asm/overlay_29_0232E864.o
Object src/overlay_29_023329E8.o
Object asm/overlay_29_02332A0C.o
Object asm/overlay_29_02332A70.o
Object src/move_checks.o
Object src/weather.o
Object asm/overlay_29_02334D58.o

View File

@ -3,6 +3,7 @@
#include "dungeon_pokemon_attributes.h"
#include "dungeon_util_static.h"
#include "overlay_29_02308FBC.h"
#include "overlay_29_0230A994.h"
#include "overlay_29_02318A4C.h"
#include "weather.h"
@ -14,11 +15,6 @@ enum flash_fire_status {
FLASH_FIRE_STATUS_NOT_MAXED = 2
};
#ifdef JAPAN
extern bool8 DefenderAbilityIsActive__0230A940(struct entity *attacker, struct entity *defender, enum ability_id ability_id);
#else
extern bool8 DefenderAbilityIsActive__0230A940(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled);
#endif
extern enum flash_fire_status FlashFireShouldActivate(struct entity *attacker, struct entity *defender);
extern enum type_matchup GetTypeMatchup(struct entity *attacker, struct entity *defender, s16 target_type_idx, enum type_id attack_type);
extern bool8 LevitateIsActive(struct entity* entity);

View File

@ -1,6 +1,24 @@
#include "overlay_29_022F9720.h"
#include "dungeon_pokemon_attributes.h"
#include "dungeon_util_static.h"
#ifdef JAPAN
bool8 DefenderAbilityIsActive__022F96CC(struct entity *attacker, struct entity *defender, enum ability_id ability_id)
#else
bool8 DefenderAbilityIsActive__022F96CC(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled)
#endif
{
if (attacker != defender &&
IsMonster__022F9720(attacker) &&
#ifndef JAPAN
attacker_ability_enabled &&
#endif
AbilityIsActiveVeneer(attacker, ABILITY_MOLD_BREAKER))
return FALSE;
return AbilityIsActiveVeneer(defender, ability_id);
}
bool8 IsMonster__022F9720(struct entity *entity)
{
if (entity == NULL)

View File

@ -1,5 +1,23 @@
#include "overlay_29_02301A60.h"
#include "dungeon_util_static.h"
#include "dungeon_pokemon_attributes.h"
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02301A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id)
#else
bool8 DefenderAbilityIsActive__02301A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled)
#endif
{
if (attacker != defender &&
IsMonster__02301A60(attacker) &&
#ifndef JAPAN
attacker_ability_enabled &&
#endif
AbilityIsActive(attacker, ABILITY_MOLD_BREAKER))
return FALSE;
return AbilityIsActive(defender, ability_id);
}
bool8 IsMonster__02301A60(struct entity *entity)
{

View File

@ -1,7 +1,25 @@
#include "overlay_29_0230A994.h"
#include "dungeon_pokemon_attributes.h"
#include "dungeon_util_static.h"
#include "exclusive_item.h"
#ifdef JAPAN
bool8 DefenderAbilityIsActive__0230A940(struct entity *attacker, struct entity *defender, enum ability_id ability_id)
#else
bool8 DefenderAbilityIsActive__0230A940(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled)
#endif
{
if (attacker != defender &&
IsMonster__0230A994(attacker) &&
#ifndef JAPAN
attacker_ability_enabled &&
#endif
AbilityIsActiveVeneer(attacker, ABILITY_MOLD_BREAKER))
return FALSE;
return AbilityIsActiveVeneer(defender, ability_id);
}
bool8 IsMonster__0230A994(struct entity *entity)
{
if (entity == NULL)

View File

@ -1,6 +1,31 @@
#include "overlay_29_02311BF8.h"
#include "dungeon_items.h"
#include "dungeon_pokemon_attributes.h"
#include "dungeon_util_static.h"
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02311B94(struct entity *attacker, struct entity *defender, enum ability_id ability_id)
#else
bool8 DefenderAbilityIsActive__02311B94(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled)
#endif
{
if (attacker != defender)
{
bool8 is_monster;
if (attacker == NULL)
is_monster = FALSE;
else
is_monster = GetEntityType(attacker) == ENTITY_MONSTER;
if (is_monster &&
#ifndef JAPAN
attacker_ability_enabled &&
#endif
AbilityIsActiveVeneer(attacker, ABILITY_MOLD_BREAKER))
return FALSE;
}
return AbilityIsActiveVeneer(defender, ability_id);
}
bool8 ItemIsActive__02311BF8(struct entity *entity, enum item_id item_id)
{

View File

@ -1,6 +1,24 @@
#include "overlay_29_02322DB8.h"
#include "dungeon_pokemon_attributes.h"
#include "dungeon_util_static.h"
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02322D64(struct entity *attacker, struct entity *defender, enum ability_id ability_id)
#else
bool8 DefenderAbilityIsActive__02322D64(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled)
#endif
{
if (attacker != defender &&
IsMonster__02322DB8(attacker) &&
#ifndef JAPAN
attacker_ability_enabled &&
#endif
AbilityIsActiveVeneer(attacker, ABILITY_MOLD_BREAKER))
return FALSE;
return AbilityIsActiveVeneer(defender, ability_id);
}
bool8 IsMonster__02322DB8(struct entity *entity)
{
if (entity == NULL)

View File

@ -1,4 +1,5 @@
#include "overlay_29_023329E8.h"
#include "dungeon_pokemon_attributes.h"
#include "dungeon_util_static.h"
#include "exclusive_item.h"
@ -10,3 +11,27 @@ bool8 ExclusiveItemEffectIsActive__023329E8(struct entity *entity, enum exclusiv
return FALSE;
}
#ifdef JAPAN
bool8 DefenderAbilityIsActive__02332A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id)
#else
bool8 DefenderAbilityIsActive__02332A0C(struct entity *attacker, struct entity *defender, enum ability_id ability_id, bool8 attacker_ability_enabled)
#endif
{
if (attacker != defender)
{
bool8 is_monster;
if (attacker == NULL)
is_monster = FALSE;
else
is_monster = GetEntityType(attacker) == ENTITY_MONSTER;
if (is_monster &&
#ifndef JAPAN
attacker_ability_enabled &&
#endif
AbilityIsActiveVeneer(attacker, ABILITY_MOLD_BREAKER))
return FALSE;
}
return AbilityIsActiveVeneer(defender, ability_id);
}