document some of the use move functions

This commit is contained in:
DizzyEggg
2024-10-25 17:30:31 +02:00
parent 5d9b14d5e2
commit 4c4ec10806
10 changed files with 812 additions and 810 deletions

View File

@@ -1441,7 +1441,7 @@ _0806798E:
mov r1, r10
movs r2, 0
movs r3, 0
bl sub_8055FA0
bl TryUseChosenMove
adds r0, r5, 0
bl EntityExists
lsls r0, 24

View File

@@ -166,7 +166,7 @@ _080733FC:
movs r1, 0
movs r2, 0
movs r3, 0x1
bl sub_8055FA0
bl TryUseChosenMove
movs r5, 0x1
b _08073456
.align 2, 0
@@ -378,7 +378,7 @@ _0807359C:
movs r1, 0
movs r2, 0
movs r3, 0x1
bl sub_8055FA0
bl TryUseChosenMove
ldr r2, _08073608
adds r1, r6, r2
ldrb r0, [r1]

View File

@@ -437,7 +437,7 @@ enum ExpMultiplier
{
EXP_HALVED, // 0.5x when fainting a mon with only the regular attack and no moves
EXP_REGULAR, // 1x
EXP_BOOSTED, // 1.5x so far use not found, but most likely linked moves ; to be confirmed once more code is decompiled
EXP_BOOSTED, // 1.5x when using linked moves
};
static inline bool8 ExpMultiplierChanged(EntityInfo *info)

View File

@@ -107,7 +107,7 @@ extern bool8 sub_805B668(Entity *pokemon, Entity *target, Move *move, s32 param_
extern bool8 sub_805B910(Entity *pokemon, Entity *target, Move *move, s32 param_4);
extern bool8 sub_805B808(Entity *pokemon, Entity *target, Move *move, s32 param_4);
extern bool8 sub_805A408(Entity *pokemon, Entity *target, Move *move, s32 param_4);
extern bool8 sub_8055620(Entity *pokemon, Entity *target, Move *move, s32 param_4);
extern bool8 HandleRegularDamagingMove(Entity *pokemon, Entity *target, Move *move, s32 param_4);
extern bool8 sub_8059050(Entity *pokemon, Entity *target, Move *move, s32 param_4);
// Todo: move this data to some better place once the file structure is better understood
@@ -225,7 +225,7 @@ const struct CalledMove gMetronomeCalledMoves[METRONOME_AVAILABLE_CALLED_MOVES]
// These correspond to dungeon's tileset id
const struct CalledMove gNaturePowerCalledMoves[] =
{
{MOVE_SURF, sub_8055620},
{MOVE_SURF, HandleRegularDamagingMove},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_SHADOW_BALL, sub_80583D8},
@@ -233,35 +233,35 @@ const struct CalledMove gNaturePowerCalledMoves[] =
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_EARTHQUAKE, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_EARTHQUAKE, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_EARTHQUAKE, sub_8055620},
{MOVE_EARTHQUAKE, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_RAZOR_LEAF, sub_8055620},
{MOVE_RAZOR_LEAF, HandleRegularDamagingMove},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_RAZOR_LEAF, sub_8055620},
{MOVE_RAZOR_LEAF, sub_8055620},
{MOVE_RAZOR_LEAF, HandleRegularDamagingMove},
{MOVE_RAZOR_LEAF, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_ROCK_SLIDE, sub_8057C88},
@@ -269,38 +269,38 @@ const struct CalledMove gNaturePowerCalledMoves[] =
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_EARTHQUAKE, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_EARTHQUAKE, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_SURF, sub_8055620},
{MOVE_SURF, HandleRegularDamagingMove},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_EARTHQUAKE, sub_8055620},
{MOVE_EARTHQUAKE, HandleRegularDamagingMove},
{MOVE_BUBBLEBEAM, sub_8058580},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_SHADOW_BALL, sub_80583D8},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_STUN_SPORE, sub_8059050},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_RAZOR_LEAF, sub_8055620},
{MOVE_RAZOR_LEAF, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, sub_8057C88},
{MOVE_SWIFT, sub_8055620},
{MOVE_SWIFT, sub_8055620},
{MOVE_SURF, sub_8055620},
{MOVE_SURF, sub_8055620},
{MOVE_ROCK_SLIDE, sub_8055620},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SWIFT, HandleRegularDamagingMove},
{MOVE_SURF, HandleRegularDamagingMove},
{MOVE_SURF, HandleRegularDamagingMove},
{MOVE_ROCK_SLIDE, HandleRegularDamagingMove},
};
//

View File

@@ -112,7 +112,7 @@ extern void sub_806F370(Entity *pokemon, Entity *r1, u32, u32, u8 *, u8, s32, u3
extern s32 sub_8042520(Entity *);
Entity *sub_80696FC(Entity *);
extern void sub_806A7E8(EntityInfo *, s32);
extern u32 sub_8055640(struct Entity *, struct Entity *, struct Move *, u32, u32);
extern u32 HandleDamagingMove(struct Entity *, struct Entity *, struct Move *, u32, u32);
void StunSeedItemAction(Entity *, Entity *);
void MaxElixirAction(Entity *, Entity *);
@@ -485,7 +485,7 @@ void sub_80482FC(Entity *pokemon, Entity *target, u32 pp, u8 param_4)
InitPokemonMove(&move, MOVE_PROJECTILE);
move.PP = pp;
sub_8055640(pokemon, target, &move, 0x100, param_4);
HandleDamagingMove(pokemon, target, &move, 0x100, param_4);
}
void sub_8048340(Entity *pokemon, Entity *target, u32 r2)

View File

@@ -50,7 +50,7 @@ extern void sub_80420B8(Entity *pokemon);
extern void sub_8041C4C(Entity *pokemon, u32 r1);
extern void sub_805E804(void);
extern void sub_80838EC(u8 *a);
extern bool8 sub_8055FA0(struct Entity *, u32, u32, u32, u32, struct Move *);
extern bool8 TryUseChosenMove(struct Entity *, u32, u32, u32, u32, struct Move *);
extern bool8 sub_8045888(Entity *);
extern void nullsub_97(Entity *entity);
extern void sub_805EE30(void);
@@ -598,7 +598,7 @@ void sub_8074094(Entity *entity)
UseAttack(NULL);
InitPokemonMove(&bideMove, MOVE_BIDE_2);
bideMove.moveFlags |= MOVE_FLAG_LAST_USED;
sub_8055FA0(entity, 0, 0, 0, 0, &bideMove);
TryUseChosenMove(entity, 0, 0, 0, 0, &bideMove);
if (!EntityExists(entity) || sub_8044B28())
return;
entityInfo->unkA0 = 0;

View File

@@ -60,7 +60,7 @@ extern void sub_8057588(Entity *, u32);
extern void sub_806A1B0(Entity *);
extern Item *sub_8044D90(Entity *, s32, u32);
extern bool8 sub_8044D40(ActionContainer *, u32);
extern bool8 sub_8055FA0(struct Entity *, u32, u32, u32, u32, struct Move *);
extern bool8 TryUseChosenMove(struct Entity *, u32, u32, u32, u32, struct Move *);
extern void sub_8045BF8(u8 *, struct Item *);
extern void sub_8044DF0(struct Entity *, u32, u32);
extern void sub_8071DA4(struct Entity *);
@@ -1046,11 +1046,11 @@ void HandleUseOrbAction(Entity *pokemon)
move.moveFlags |= MOVE_FLAG_SET;
move.moveFlags |= MOVE_FLAG_ENABLED_FOR_AI;
move.PP = 10;
sub_8055FA0(pokemon, 0, IVar5.id, 0, 0, &move);
TryUseChosenMove(pokemon, 0, IVar5.id, 0, 0, &move);
r4 = FALSE;
}
else {
r4 = sub_8055FA0(pokemon, 0, IVar5.id, 0, 0, &move);
r4 = TryUseChosenMove(pokemon, 0, IVar5.id, 0, 0, &move);
}
}
else {

File diff suppressed because it is too large Load Diff

View File

@@ -211,7 +211,7 @@ bool8 sub_8057308(Entity *pokemon, s32 chance);
bool8 sub_80571F0(Entity * pokemon, Move *move);
extern void sub_806F370(Entity *r0, Entity *r1, u32, u32, u8 *, u8, s32, u32, u32, u32);
extern u32 sub_8055640(Entity *, Entity *, Move *, u32, u32);
extern u32 HandleDamagingMove(Entity *, Entity *, Move *, u32, u32);
u8 sub_8057620(u32 param_1);
extern s16 sub_8094828(u16, u8);
extern void DealDamageToEntity(Entity *, s32, u32, u32);
@@ -342,7 +342,7 @@ bool8 sub_8057634(Entity *pokemon, Entity *target, Move *move, s32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon, target, gUnknown_80F4DB4)) {
LowerDefenseStageTarget(pokemon, target, gUnknown_8106A4C, 1, 1, FALSE);
@@ -358,7 +358,7 @@ bool8 sub_805768C(Entity *pokemon, Entity *target, Move *move, s32 param_4)
flag = FALSE;
gUnknown_202F21C++;
if (sub_8055640(pokemon, target, move, gUnknown_8106A54[gUnknown_202F21C], param_4) == 0)
if (HandleDamagingMove(pokemon, target, move, gUnknown_8106A54[gUnknown_202F21C], param_4) == 0)
gUnknown_202F220 = 1;
else
flag = TRUE;
@@ -407,7 +407,7 @@ bool8 DigMoveAction(Entity * pokemon, Entity * target, Move *move, s32 param_4)
}
else {
if (MoveMatchesChargingStatus(pokemon,move)) {
sub_8055640(pokemon,target,move,gUnknown_80F4F68,param_4);
HandleDamagingMove(pokemon,target,move,gUnknown_80F4F68,param_4);
sub_8079764(pokemon);
}
else {
@@ -461,7 +461,7 @@ bool32 sub_80578FC(Entity *pokemon, Entity *target, Move * move, u32 param_4)
bool32 flag;
flag = FALSE;
if (sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target, gUnknown_80F4DB6)) {
LowerMovementSpeedTarget(pokemon, target, 1, FALSE);
@@ -601,7 +601,7 @@ bool8 SnoreMoveAction(Entity *pokemon, Entity *target, Move * move, u32 param_4)
flag = FALSE;
if (IsSleeping(pokemon)) {
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4E0A)) {
CringeStatusTarget(pokemon,target,FALSE);
@@ -625,7 +625,7 @@ bool8 sub_8057C88(Entity *pokemon, Entity *target, Move * move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4DF6)) {
CringeStatusTarget(pokemon,target,FALSE);
@@ -660,7 +660,7 @@ bool8 WhirlpoolMoveAction(Entity * pokemon, Entity * target, Move * move, u32 pa
if (chargeStatus == STATUS_DIVING) {
uVar3 = 0x200;
}
if (sub_8055640(pokemon,target,move,uVar3,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,uVar3,param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4E08)) {
SqueezedStatusTarget(pokemon,target,0x3b,FALSE);
@@ -727,7 +727,7 @@ bool8 sub_8057E6C(Entity *pokemon, Entity *target, Move *move, u32 param_4)
flag = FALSE;
entityInfo = pokemon->info;
SendThawedMessage(pokemon,target);
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if (sub_8057308(pokemon, 0)) {
entityInfo->unk155 = 1;
@@ -741,7 +741,7 @@ bool8 sub_8057ED0(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4E04))
{
@@ -768,7 +768,7 @@ bool8 sub_8057F7C(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4E02))
{
@@ -869,7 +869,7 @@ bool8 sub_805816C(Entity *pokemon, Entity *target, Move *move, u32 param_4)
flag = FALSE;
SendThawedMessage(pokemon, target);
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DB8))
{
@@ -885,7 +885,7 @@ bool8 sub_80581D0(Entity *pokemon, Entity *target, Move *move, u32 param_4)
flag = FALSE;
SendThawedMessage(pokemon, target);
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DBA))
{
@@ -917,7 +917,7 @@ bool8 sub_8058270(Entity *pokemon, Entity *target, Move *move, u32 param_4)
r3 = 1;
if((u8)(target->info->charging.chargingStatus - 7) <= 1)
r3 = 2;
flag = sub_8055640(pokemon,target,move,r3 << 8,param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,r3 << 8,param_4) ? TRUE : FALSE;
return flag;
}
@@ -944,7 +944,7 @@ bool8 RazorWindMoveAction(Entity * pokemon, Entity * target, Move * move, u32 pa
bool8 flag;
if (MoveMatchesChargingStatus(pokemon,move)) {
flag = sub_8055640(pokemon,target,move,gUnknown_80F4F50,param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F4F50,param_4) ? TRUE : FALSE;
sub_8079764(pokemon);
}
else {
@@ -981,7 +981,7 @@ bool8 sub_80583D8(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DC2))
{
@@ -996,7 +996,7 @@ bool8 sub_8058430(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DEE))
{
@@ -1011,7 +1011,7 @@ bool8 sub_8058478(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DE6))
{
@@ -1050,7 +1050,7 @@ bool8 sub_8058548(Entity *pokemon, Entity *target, Move *move, u32 param_4)
r5 = 0x80 << 1;
if((pokemon->info->nonVolatile.nonVolatileStatus) != STATUS_NONE)
r5 = gUnknown_80F4F6C;
flag = sub_8055640(pokemon,target,move,r5,param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,r5,param_4) ? TRUE : FALSE;
return flag;
}
@@ -1059,7 +1059,7 @@ bool8 sub_8058580(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DD4))
{
@@ -1080,7 +1080,7 @@ bool8 BrickBreakMoveAction(Entity *pokemon, Entity *target, Move *move, u32 para
flag = TRUE;
}
flag |= (sub_8055640(pokemon,target,move,0x100,param_4) != 0);
flag |= (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0);
return flag;
}
@@ -1089,7 +1089,7 @@ bool8 sub_8058638(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, 0))
{
@@ -1104,7 +1104,7 @@ bool8 FocusPunchMoveAction(Entity * pokemon, Entity * target, Move * move, u32 p
bool8 flag;
if (MoveMatchesChargingStatus(pokemon,move)) {
flag = sub_8055640(pokemon,target,move,gUnknown_80F4F54,param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F4F54,param_4) ? TRUE : FALSE;
sub_8079764(pokemon);
}
else {
@@ -1123,7 +1123,7 @@ bool8 sub_80586DC(Entity * pokemon, Entity * target, Move * move, u32 param_4)
EntityInfo *entityInfo;
hasLiquidOoze = HasAbility(target, ABILITY_LIQUID_OOZE);
uVar3 = sub_8055640(pokemon,target,move,0x100,param_4);
uVar3 = HandleDamagingMove(pokemon,target,move,0x100,param_4);
flag = uVar3 != 0 ? TRUE : FALSE;
if (flag && sub_8057308(pokemon, 0)) {
newHP = uVar3 / 2;
@@ -1164,7 +1164,7 @@ bool8 sub_8058770(Entity * pokemon, Entity * target, Move * move, u32 param_4)
index = 3;
}
flag = sub_8055640(pokemon,target,move,gUnknown_80F51A4[index],param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F51A4[index],param_4) ? TRUE : FALSE;
return flag;
}
@@ -1173,11 +1173,11 @@ bool8 sub_80587E8(Entity * pokemon, Entity * target, Move * move, u32 param_4)
bool8 flag;
if (target->info->nonVolatile.nonVolatileStatus == STATUS_PARALYSIS) {
flag = sub_8055640(pokemon,target,move,0x80 << 2,param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,0x80 << 2,param_4) ? TRUE : FALSE;
SendNonVolatileEndMessage(pokemon, target);
}
else {
flag = sub_8055640(pokemon,target,move,0x80 << 1,param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,0x80 << 1,param_4) ? TRUE : FALSE;
}
return flag;
}
@@ -1211,7 +1211,7 @@ bool8 sub_80588A8(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 sub_80588B8(Entity *pokemon, Entity *target, Move *move, u32 param_4)
{
bool8 flag = FALSE;
if(sub_8055640(pokemon, target, move, 0x80 << 1, param_4) != 0)
if(HandleDamagingMove(pokemon, target, move, 0x80 << 1, param_4) != 0)
{
flag = TRUE;
if(sub_8057308(pokemon, 0))
@@ -1227,7 +1227,7 @@ bool8 sub_80588F4(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
EntityInfo *entityInfo = target->info;
flag = sub_8055640(pokemon, target, move, GetWeight(entityInfo->apparentID), param_4) != 0 ? TRUE: FALSE;
flag = HandleDamagingMove(pokemon, target, move, GetWeight(entityInfo->apparentID), param_4) != 0 ? TRUE: FALSE;
return flag;
}
@@ -1238,7 +1238,7 @@ bool8 sub_8058930(Entity *pokemon, Entity *target, Move *move, u32 param_4)
EntityInfo *entityInfo;
s32 index1;
s32 index2;
if(sub_8055640(pokemon, target, move, 0x80 << 1, param_4) != 0)
if(HandleDamagingMove(pokemon, target, move, 0x80 << 1, param_4) != 0)
{
flag = TRUE;
if(sub_8057308(pokemon, gUnknown_80F4DD6))
@@ -1272,7 +1272,7 @@ bool8 sub_8058A08(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 sub_8058A18(Entity *pokemon, Entity *target, Move *move, u32 param_4)
{
bool8 flag = FALSE;
if(sub_8055640(pokemon, target, move, 0x80 << 1, param_4) != 0)
if(HandleDamagingMove(pokemon, target, move, 0x80 << 1, param_4) != 0)
{
flag = TRUE;
if(sub_8057308(pokemon, 0))
@@ -1302,7 +1302,7 @@ bool8 SkyAttackMoveAction(Entity *pokemon, Entity *target, Move *move, u32 param
if(MoveMatchesChargingStatus(pokemon, move))
{
if (sub_8055640(pokemon, target, move, gUnknown_80F4F4C, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, gUnknown_80F4F4C, param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DF4))
CringeStatusTarget(pokemon, target, FALSE);
@@ -1321,7 +1321,7 @@ bool8 sub_8058B3C(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DBC))
{
@@ -1337,7 +1337,7 @@ bool8 sub_8058B84(Entity *pokemon, Entity *target, Move *move, u32 param_4)
EntityInfo *entityInfo;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, pokemon, gUnknown_80F4DD0))
{
@@ -1366,7 +1366,7 @@ bool8 sub_8058C00(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DF8))
{
@@ -1398,7 +1398,7 @@ bool8 sub_8058C98(Entity *pokemon, Entity *target, Move *move, u32 param_4, u32
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_5) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_5) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DC0))
{
@@ -1411,7 +1411,7 @@ bool8 sub_8058C98(Entity *pokemon, Entity *target, Move *move, u32 param_4, u32
bool8 sub_8058CEC(Entity *pokemon, Entity *target, Move *move, u32 param_4)
{
bool8 flag = FALSE;
if(sub_8055640(pokemon, target, move, 0x80 << 1, param_4) != 0)
if(HandleDamagingMove(pokemon, target, move, 0x80 << 1, param_4) != 0)
{
flag = TRUE;
if(sub_8057308(pokemon, 0))
@@ -1449,7 +1449,7 @@ bool8 sub_8058D44(Entity * pokemon, Entity * target, Move * move, u32 param_4)
index = 3;
}
flag = sub_8055640(pokemon,target,move,gUnknown_80F51B4[index],param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F51B4[index],param_4) ? TRUE : FALSE;
return flag;
}
@@ -1485,7 +1485,7 @@ bool8 sub_8058E5C(Entity *pokemon, Entity *target, Move *move, s32 param_4)
bool8 flag;
flag = FALSE;
if ((sub_8055640(pokemon, target, move, 0x80 << 1, param_4) != 0) && (EntityExists(pokemon))) {
if ((HandleDamagingMove(pokemon, target, move, 0x80 << 1, param_4) != 0) && (EntityExists(pokemon))) {
iVar2 = pokemon->info->maxHPStat;
if (iVar2 < 0) {
iVar2 = iVar2 + 7;
@@ -1521,7 +1521,7 @@ bool32 sub_8058F04(Entity *pokemon, Entity *target, Move *move, s32 param_4)
if (entityInfo->charging.chargingStatus == STATUS_DIGGING) {
iVar3 = 2;
}
flag = sub_8055640(pokemon,target,move,iVar3 << 8,param_4);
flag = HandleDamagingMove(pokemon,target,move,iVar3 << 8,param_4);
if (flag != 0) {
flag = TRUE;
}
@@ -1551,7 +1551,7 @@ bool8 sub_8058FBC(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DE4))
{
@@ -1584,7 +1584,7 @@ bool8 sub_8059080(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DE8))
{
@@ -1629,7 +1629,7 @@ bool8 sub_8059190(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DEA))
{
@@ -1654,7 +1654,7 @@ bool8 sub_80591E4(Entity *pokemon, Entity *target, Move *move, s32 param_4)
flag = FALSE;
hasLiquidOoze = HasAbility(target, ABILITY_LIQUID_OOZE);
iVar3 = sub_8055640(pokemon,target,move,0x100,param_4);
iVar3 = HandleDamagingMove(pokemon,target,move,0x100,param_4);
if (iVar3 != 0) {
iVar4 = iVar3 / 2;
if (iVar4 < 1) {
@@ -1752,7 +1752,7 @@ bool8 sub_8059424(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DF0))
{
@@ -1768,7 +1768,7 @@ bool8 sub_805946C(Entity * pokemon,Entity * target,Move * move,u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if ((!HasAbility(pokemon, ABILITY_ROCK_HEAD)) && (sub_8057308(pokemon,0) != 0)) {
HP = pokemon->info->maxHPStat;
@@ -1807,7 +1807,7 @@ bool8 sub_8059540(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DC4))
{
@@ -1828,7 +1828,7 @@ bool8 sub_80595A0(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DE0))
{
@@ -1868,7 +1868,7 @@ bool8 SolarBeamMoveAction(Entity * pokemon,Entity * target,Move * move,u32 param
if (((weather == WEATHER_SANDSTORM) || (weather == WEATHER_RAIN)) || weather == WEATHER_HAIL) {
movePower /= 2;
}
weather = sub_8055640(pokemon,target,move,movePower,param_4) != 0 ? TRUE : FALSE;
weather = HandleDamagingMove(pokemon,target,move,movePower,param_4) != 0 ? TRUE : FALSE;
sub_8079764(pokemon);
}
else {
@@ -1894,7 +1894,7 @@ bool8 FlyMoveAction(Entity * pokemon, Entity * target, Move * move, u32 param_4)
flag = FALSE;
if (MoveMatchesChargingStatus(pokemon,move)) {
flag = sub_8055640(pokemon,target,move,gUnknown_80F4F5C,param_4) != 0 ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F4F5C,param_4) != 0 ? TRUE : FALSE;
sub_8079764(pokemon);
}
else {
@@ -1919,7 +1919,7 @@ bool8 DiveMoveAction(Entity * pokemon, Entity * target, Move * move, u32 param_4
TryDisplayDungeonLoggableMessage3(pokemon,target,*gUnknown_80FD128);
}
else if (MoveMatchesChargingStatus(pokemon,move)) {
flag = sub_8055640(pokemon,target,move,gUnknown_80F4F64,param_4) != 0 ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F4F64,param_4) != 0 ? TRUE : FALSE;
sub_8079764(pokemon);
}
else {
@@ -1934,7 +1934,7 @@ bool8 sub_80598CC(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4E00))
{
@@ -1960,7 +1960,7 @@ bool8 sub_8059928(Entity * pokemon,Entity * target,Move * move,u32 param_4)
if ((u8)(target->info->charging.chargingStatus - 7) <= 1){
iVar2 = 2;
}
if (sub_8055640(pokemon,target,move,iVar2 << 8,param_4) != 0)
if (HandleDamagingMove(pokemon,target,move,iVar2 << 8,param_4) != 0)
{
flag = TRUE;
if(sub_805727C(pokemon,target,gUnknown_80F4DEC) != 0) {
@@ -1975,7 +1975,7 @@ bool8 sub_8059988(Entity * pokemon,Entity * target,Move * move,u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
gUnknown_202F218 = 1;
}
@@ -2138,7 +2138,7 @@ bool8 sub_8059D00(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DE2))
{
@@ -2159,7 +2159,7 @@ bool8 sub_8059D58(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, 0))
{
@@ -2192,7 +2192,7 @@ bool8 sub_8059DC4(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DCA))
{
@@ -2207,7 +2207,7 @@ bool8 sub_8059E0C(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DBE))
{
@@ -2228,7 +2228,7 @@ bool8 sub_8059E54(Entity * pokemon,Entity * target,Move * move,u32 param_4,u8 pa
flag = FALSE;
if (param_5 == 0) {
flag = sub_8055640(pokemon,target,move,0x100,param_4) != 0 ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0 ? TRUE : FALSE;
}
if (!flag) {
moveType = GetMoveTypeForMonster(pokemon,move);
@@ -2252,7 +2252,7 @@ bool8 sub_8059F38(Entity * pokemon,Entity * target,Move * move,u32 param_4)
flag = FALSE;
if (MoveMatchesChargingStatus(pokemon, move)) {
if (sub_8055640(pokemon, target, move, gUnknown_80F4F60, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, gUnknown_80F4F60, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon, target, gUnknown_80F4DCC) != 0) {
ParalyzeStatusTarget(pokemon, target, FALSE);
@@ -2278,7 +2278,7 @@ bool8 sub_8059FC8(Entity * pokemon,Entity * target,Move * move,u32 param_4,u8 pa
flag = FALSE;
if (param_5 == 0) {
flag = sub_8055640(pokemon,target,move,0x200,param_4) != 0 ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,0x200,param_4) != 0 ? TRUE : FALSE;
}
if (!flag) {
moveType = GetMoveTypeForMonster(pokemon,move);
@@ -2301,7 +2301,7 @@ bool8 TriAttackMoveAction(Entity * pokemon, Entity * target, Move *move, u32 par
bool8 flag;
flag = FALSE;
if(sub_8055640(pokemon, target, move, 0x100, param_4))
if(HandleDamagingMove(pokemon, target, move, 0x100, param_4))
{
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DFC))
@@ -2385,7 +2385,7 @@ bool8 sub_805A210(Entity * pokemon, Entity * target, Move *move, u32 param_4)
bool8 flag;
gUnknown_202F210++;
flag = sub_8055640(pokemon, target, move, gUnknown_202F210 << 8, param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon, target, move, gUnknown_202F210 << 8, param_4) ? TRUE : FALSE;
return flag;
}
@@ -2408,7 +2408,7 @@ bool8 sub_805A258(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, 0))
{
@@ -2448,7 +2448,7 @@ bool8 SurfMoveAction(Entity *pokemon, Entity *target, Move *move, u32 param_4)
{
uVar2 = 0x100;
}
if(sub_8055640(pokemon,target,move,uVar2,param_4) != 0)
if(HandleDamagingMove(pokemon,target,move,uVar2,param_4) != 0)
flag = TRUE;
return flag;
}
@@ -2502,7 +2502,7 @@ bool8 sub_805A408(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DF2))
{
@@ -2525,7 +2525,7 @@ bool8 sub_805A464(Entity *pokemon, Entity *target, Move *move, u32 param_4)
Position pos;
flag = FALSE;
if (sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_8057308(pokemon, 0) != 0) {
if (!EntityExists(target)) {
@@ -2582,7 +2582,7 @@ bool8 sub_805A568(Entity * pokemon, Entity * target, Move *move, u32 param_4)
{
bool8 flag;
flag = sub_8055640(pokemon, target, move, 0x100, param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon, target, move, 0x100, param_4) ? TRUE : FALSE;
return flag;
}
@@ -2592,7 +2592,7 @@ bool8 TickleMoveAction(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool32 flag;
flag = FALSE;
if (sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if (HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,pokemon,0) != 0) {
stat = gUnknown_8106A4C;
@@ -2609,7 +2609,7 @@ bool8 sub_805A5E8(Entity *pokemon, Entity *target, Move *move, u32 stat, u32 par
bool32 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_5) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_5) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,pokemon,gUnknown_80F4DD2) != 0) {
entityInfo = pokemon->info;
@@ -2626,7 +2626,7 @@ bool8 SpitUpMoveAction(Entity *pokemon, Entity *target, Move *move, u32 param_4)
stockpileStage = &pokemon->info->stockpileStage;
if (*stockpileStage != 0) {
sub_8055640(pokemon,target,move,*stockpileStage << 8,param_4);
HandleDamagingMove(pokemon,target,move,*stockpileStage << 8,param_4);
*stockpileStage = 0;
}
else {
@@ -2640,7 +2640,7 @@ bool8 sub_805A688(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, 0))
{
@@ -2854,7 +2854,7 @@ bool8 SecretPowerMoveAction(Entity * pokemon, Entity * target, Move *move, u32 p
bool8 flag;
flag = FALSE;
if ( sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if ( HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4E06) != 0) {
switch(gSecretPowerTable[gDungeon->tileset]) {
@@ -2897,7 +2897,7 @@ bool8 sub_805AC90(Entity * pokemon, Entity * target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if ( sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if ( HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4DFA) != 0) {
ConfuseStatusTarget(pokemon, target, FALSE);
@@ -2969,7 +2969,7 @@ bool8 sub_805AE3C(Entity *pokemon, Entity *target, Move *move, u32 param_4)
bool8 flag;
SendThawedMessage(pokemon, target);
flag = sub_8055640(pokemon,target,move,0x80 << 2,param_4) != 0 ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,0x80 << 2,param_4) != 0 ? TRUE : FALSE;
return flag;
}
@@ -2978,7 +2978,7 @@ bool8 sub_805AE74(Entity * pokemon, Entity * target, Move *move, u32 param_4)
bool8 flag;
flag = FALSE;
if ( sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if ( HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4DDA) != 0) {
LowerDefenseStageTarget(pokemon, target, gUnknown_8106A4C, 1, 1, FALSE);
@@ -2993,7 +2993,7 @@ bool8 sub_805AECC(Entity * pokemon, Entity * target, Move *move, u32 param_4)
flag = FALSE;
SendThawedMessage(pokemon, target);
if ( sub_8055640(pokemon, target, move, 0x100, param_4) != 0) {
if ( HandleDamagingMove(pokemon, target, move, 0x100, param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4DFE) != 0) {
BurnedStatusTarget(pokemon, target, 0, FALSE);

View File

@@ -59,7 +59,7 @@ extern s16 sub_803D970(u32);
extern bool8 sub_806AA0C(s32, u32);
extern void sub_806BB6C(Entity *, s32);
extern void sub_807E254(Entity *, Entity *, u32);
extern u32 sub_8055640(Entity *, Entity *, Move *, u32, u32);
extern u32 HandleDamagingMove(Entity *, Entity *, Move *, u32, u32);
extern void sub_806A6E8(Entity *);
extern u8 sub_8069D18(Position *);
extern u8 sub_804AD34(Position *);
@@ -170,7 +170,7 @@ bool8 sub_805AFA4(Entity * pokemon, Entity * target, Move *move, u32 param_4)
index = 3;
}
flag = sub_8055640(pokemon,target,move,gUnknown_80F51C4[index],param_4) ? TRUE : FALSE;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F51C4[index],param_4) ? TRUE : FALSE;
return flag;
}
@@ -198,7 +198,7 @@ bool8 sub_805B074(Entity * pokemon, Entity * target, Move *move, s32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4DC6) != 0) {
PoisonedStatusTarget(pokemon,target,FALSE);
@@ -259,7 +259,7 @@ bool8 sub_805B17C(Entity * pokemon, Entity * target, Move *move, s32 param_4)
uVar4 = 0x7e;
}
}
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4E08) != 0) {
SqueezedStatusTarget(pokemon,target,uVar4,0);
@@ -354,7 +354,7 @@ bool8 sub_805B324(Entity * pokemon,Entity * target,Move *move, s32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target,gUnknown_80F4DD8) != 0) {
LowerAttackStageTarget(pokemon,target,gUnknown_8106A50,1,1,0);
@@ -371,7 +371,7 @@ bool8 DestinyBondMoveAction(Entity * pokemon,Entity * target,Move *move, s32 par
bool8 sub_805B388(Entity * pokemon,Entity * target,Move *move, s32 param_4)
{
return (sub_8055640(pokemon,target,move,0x100,param_4)) ? TRUE : FALSE;
return (HandleDamagingMove(pokemon,target,move,0x100,param_4)) ? TRUE : FALSE;
}
bool8 MirrorCoatMoveAction(Entity * pokemon,Entity * target,Move *move, s32 param_4)
@@ -390,7 +390,7 @@ bool8 sub_805B3B4(Entity * pokemon,Entity * target,Move *move, s32 param_4)
bool8 sub_805B3E0(Entity * pokemon,Entity * target,Move *move, s32 param_4)
{
sub_8055640(pokemon,target,move,0x100,param_4);
HandleDamagingMove(pokemon,target,move,0x100,param_4);
return TRUE;
}
@@ -400,7 +400,7 @@ bool8 sub_805B3FC(Entity * pokemon,Entity * target,Move *move, s32 param_4, s32
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_5) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_5) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,pokemon,gUnknown_80F4DCE) != 0) {
entityInfo = pokemon->info;
@@ -513,7 +513,7 @@ bool8 sub_805B668(Entity * pokemon, Entity * target, Move *move, s32 param_4)
flag = FALSE;
hasLiquidOoze = HasAbility(target, ABILITY_LIQUID_OOZE);
if (IsSleeping(target)) {
iVar3 = sub_8055640(pokemon,target,move,0x100,param_4);
iVar3 = HandleDamagingMove(pokemon,target,move,0x100,param_4);
if (iVar3 != 0) {
flag = TRUE;
newHP = iVar3 / 2;
@@ -606,7 +606,7 @@ bool8 SkullBashMoveAction(Entity * pokemon, Entity * target, Move * move, s32 pa
bool8 flag;
if (MoveMatchesChargingStatus(pokemon,move)) {
flag = sub_8055640(pokemon,target,move,gUnknown_80F4F58,param_4) != 0 ? 1 : 0;
flag = HandleDamagingMove(pokemon,target,move,gUnknown_80F4F58,param_4) != 0 ? 1 : 0;
sub_8079764(pokemon);
}
else {
@@ -621,7 +621,7 @@ bool8 sub_805B910(Entity * pokemon, Entity * target, Move * move, s32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if(sub_805727C(pokemon, target, gUnknown_80F4DDC))
{
@@ -638,7 +638,7 @@ bool8 sub_805B968(Entity * pokemon, Entity * target, Move * move, s32 param_4)
bool8 flag;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if (sub_8057308(pokemon,0) != 0) {
entityHP = pokemon->info->maxHPStat;
@@ -693,7 +693,7 @@ bool8 sub_805BA50(Entity * pokemon, Entity * target, Move *move, s32 param_4)
Item *targetItem;
flag = FALSE;
if (sub_8055640(pokemon,target,move,0x100,param_4) != 0) {
if (HandleDamagingMove(pokemon,target,move,0x100,param_4) != 0) {
flag = TRUE;
if (sub_805727C(pokemon,target, 0) != 0) {
iVar2 = pokemon->info;