mirror of
https://github.com/pret/pmd-red.git
synced 2026-08-28 03:34:22 -05:00
move function externs to dungeon_damage.h
This commit is contained in:
@@ -9,5 +9,10 @@ s32 WeightWeakTypePicker(Entity *user, Entity *target, u8 moveType);
|
||||
void CalcDamage(Entity *attacker, Entity *target, u8 moveType, s32 movePower, s32 critChance, struct DamageStruct *dmgStruct, s24_8 arg8, u16 moveId, bool8 arg_10);
|
||||
void sub_806F2BC(Entity *attacker, Entity *target, u8 moveType, s32 a2, struct DamageStruct *dmgStruct);
|
||||
void DealDamageToEntity(Entity *entity, s32 dmg, s32 r6, s32 r4);
|
||||
void sub_806F370(Entity *pokemon, Entity *target, s32 dmg, s32 giveExp, bool8 *tookNoDamage, u8 moveType, s16 arg_8, s32 residualDmgType, s32 arg_10, s32 arg_14);
|
||||
void SetShopkeeperAggression(Entity *pokemon, Entity *target);
|
||||
void sub_806F480(Entity *pokemon, bool8 attackEnemies);
|
||||
u8 sub_806F4A4(Entity *pokemon, u8 type);
|
||||
s32 sub_806F62C(int param_1);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -26,12 +26,12 @@
|
||||
#include "dungeon_items.h"
|
||||
#include "dungeon_strings.h"
|
||||
#include "dungeon_pos_data.h"
|
||||
#include "dungeon_damage.h"
|
||||
|
||||
void sub_804EB30();
|
||||
bool8 ExposeTrap(s32 x, s32 y);
|
||||
void sub_807EC28(u32);
|
||||
u8 IsFloorOver(void);
|
||||
extern void sub_806F370(Entity *pokemon, Entity *target, u32, u32, u8 *, u8 moveType, s32, u32, u32, u32);
|
||||
void sub_80421AC(Entity * pokemon, Entity * target);
|
||||
void sub_807BB78(Entity *pokemon);
|
||||
extern void UpdateCamera(u32);
|
||||
|
||||
@@ -31,13 +31,13 @@
|
||||
#include "dungeon_util_1.h"
|
||||
#include "effect_data.h"
|
||||
#include "dungeon_pos_data.h"
|
||||
#include "dungeon_damage.h"
|
||||
|
||||
// Unknown dungeon file. File split is correct.
|
||||
|
||||
extern const u8 *gPtrFeralFoundItemMessage[];
|
||||
|
||||
extern void sub_803ED30(u8, Entity *pokemon, u8, u8);
|
||||
extern u32 sub_806F62C(u32);
|
||||
extern void PlaySoundEffect(u32);
|
||||
|
||||
void EntityUpdateStatusSprites(Entity *entity);
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#include "constants/ability.h"
|
||||
#include "structs/str_dungeon.h"
|
||||
#include "dungeon_logic.h"
|
||||
#include "dungeon_move.h"
|
||||
#include "pokemon_types.h"
|
||||
#include "dungeon_message.h"
|
||||
#include "string_format.h"
|
||||
@@ -43,7 +44,6 @@ extern void sub_807F43C(Entity *, Entity *);
|
||||
extern void sub_8041B18(Entity *pokemon);
|
||||
extern void sub_8041B90(Entity *pokemon);
|
||||
extern void sub_8041D00(Entity *pokemon, Entity *target);
|
||||
extern void SetShopkeeperAggression(Entity *, Entity *);
|
||||
extern void sub_8042238(Entity *pokemon, Entity *target);
|
||||
extern void sub_803ED30(s32, Entity *r0, u8, s32);
|
||||
extern bool8 sub_806A458(Entity *);
|
||||
@@ -55,11 +55,9 @@ extern void sub_8042A24(Entity *r0);
|
||||
extern void sub_806A390(Entity *r0);
|
||||
extern void sub_8078084(Entity * pokemon);
|
||||
extern void sub_800DBBC(void);
|
||||
extern void SpawnDroppedItemWrapper(Entity *, DungeonPos *, Item *);
|
||||
extern bool8 DoEnemiesEvolveWhenKOed(u8 dungeon);
|
||||
extern bool8 sub_806FA5C(Entity *, Entity *, struct unkStruct_8069D4C *);
|
||||
extern void EntityUpdateStatusSprites(Entity *);
|
||||
extern void sub_806F500(void);
|
||||
extern void PointCameraToMonster(Entity *);
|
||||
extern void sub_8041B74(Entity *pokemon);
|
||||
extern void sub_8041B5C(Entity *pokemon);
|
||||
@@ -72,8 +70,6 @@ extern void sub_804298C(Entity *);
|
||||
extern void sub_80428EC(Entity *);
|
||||
extern void ResetMonEntityData(EntityInfo *, u32);
|
||||
|
||||
extern u8 gUnknown_202F221;
|
||||
|
||||
extern const s32 gUnknown_8106A4C;
|
||||
extern const u8 *const gUnknown_8100548;
|
||||
extern const u8 *const gUnknown_80FD46C;
|
||||
@@ -87,9 +83,8 @@ extern const s16 gUnknown_810AC62;
|
||||
|
||||
static bool8 HandleDealingDamageInternal(Entity *attacker, Entity *target, struct DamageStruct *r5, bool32 isFalseSwipe, bool32 giveExp, s16 arg4_, s32 arg8);
|
||||
static bool8 sub_806E100(s48_16 *param_1, Entity *pokemon, Entity *target, u8 type, DamageStruct *dmgStruct);
|
||||
|
||||
void DealDamageToEntity(Entity *entity, s32 dmg, s32 r6, s32 r4);
|
||||
void sub_806F63C(Entity *param_1);
|
||||
static void sub_806F500(void);
|
||||
static void sub_806F63C(Entity *param_1);
|
||||
|
||||
static const u32 gUnknown_8106EFC[] = { 0, 0 };
|
||||
static const s48_16 gUnknown_8106F04 = { 0x0, 0x10000 };
|
||||
@@ -1566,20 +1561,15 @@ void SetShopkeeperAggression(Entity *pokemon, Entity *target)
|
||||
}
|
||||
}
|
||||
|
||||
void sub_806F480(Entity *pokemon, u8 r1)
|
||||
void sub_806F480(Entity *pokemon, bool8 attackEnemies)
|
||||
{
|
||||
EntityInfo *info;
|
||||
EntityInfo *info = GetEntInfo(pokemon);
|
||||
|
||||
info = GetEntInfo(pokemon);
|
||||
|
||||
if(info->shopkeeper != SHOPKEEPER_MODE_NORMAL)
|
||||
{
|
||||
if(r1)
|
||||
{
|
||||
if (info->shopkeeper != SHOPKEEPER_MODE_NORMAL) {
|
||||
if (attackEnemies) {
|
||||
info->shopkeeper = SHOPKEEPER_MODE_ATTACK_ENEMIES;
|
||||
}
|
||||
else
|
||||
{
|
||||
else {
|
||||
info->shopkeeper = SHOPKEEPER_MODE_ATTACK_TEAM;
|
||||
}
|
||||
}
|
||||
@@ -1590,21 +1580,19 @@ u8 sub_806F4A4(Entity *pokemon, u8 type)
|
||||
EntityInfo *info = GetEntInfo(pokemon);
|
||||
s32 index;
|
||||
|
||||
if(MonsterIsType(pokemon, TYPE_GHOST))
|
||||
{
|
||||
if(type == TYPE_NORMAL || type == TYPE_FIGHTING)
|
||||
if(!info->exposed)
|
||||
if (MonsterIsType(pokemon, TYPE_GHOST)) {
|
||||
if (type == TYPE_NORMAL || type == TYPE_FIGHTING)
|
||||
if (!info->exposed)
|
||||
return FALSE;
|
||||
}
|
||||
for(index = 0; index < 2; index++)
|
||||
{
|
||||
if(gTypeEffectivenessChart[type][info->types[index]] == EFFECTIVENESS_IMMUNE)
|
||||
for (index = 0; index < 2; index++) {
|
||||
if (gTypeEffectivenessChart[type][info->types[index]] == EFFECTIVENESS_IMMUNE)
|
||||
return FALSE;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void sub_806F500(void)
|
||||
static void sub_806F500(void)
|
||||
{
|
||||
struct unkStruct_Dungeon134_sub *temp;
|
||||
|
||||
@@ -1662,11 +1650,9 @@ s32 sub_806F62C(int param_1)
|
||||
return gUnknown_8106F7C[param_1];
|
||||
}
|
||||
|
||||
void sub_806F63C(Entity *param_1)
|
||||
static void sub_806F63C(Entity *param_1)
|
||||
{
|
||||
UnkDungeonGlobal_unk181E8_sub *temp;
|
||||
|
||||
temp = &gDungeon->unk181e8;
|
||||
UnkDungeonGlobal_unk181E8_sub *temp = &gDungeon->unk181e8;
|
||||
|
||||
if (temp->cameraTarget == param_1) {
|
||||
PointCameraToMonster(temp->cameraTarget);
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
#include "code_803E724.h"
|
||||
#include "dungeon_data.h"
|
||||
#include "dungeon_logic.h"
|
||||
#include "dungeon_damage.h"
|
||||
|
||||
extern u8 *gUnknown_80F89F4[];
|
||||
extern u8 *gUnknown_80FB580[];
|
||||
@@ -76,7 +77,6 @@ extern void sub_804245C(Entity *, Item *);
|
||||
extern u8 sub_8072938(Entity *, u16);
|
||||
extern void sub_8072008(Entity *pokemon, Entity *r1, u32 r2, u8 r3, u32);
|
||||
extern void LevelDownTarget(Entity *pokemon, Entity *r1, u32 r2);
|
||||
extern void sub_806F370(Entity *pokemon, Entity *r1, u32, u32, u8 *, u8, s32, u32, u32, u32);
|
||||
extern s32 sub_8042520(Entity *);
|
||||
Entity *sub_80696FC(Entity *);
|
||||
extern void DisplayMsgIfNewIqSkillLearned(EntityInfo *, s32);
|
||||
@@ -124,7 +124,6 @@ void DoomSeedItemAction(Entity *, Entity *);
|
||||
void sub_80482FC(Entity *, Entity *, u32, u8);
|
||||
|
||||
extern void EnemyEvolution(Entity *);
|
||||
extern void SetShopkeeperAggression(Entity *, Entity *);
|
||||
extern void SpawnDroppedItemWrapper(Entity *, DungeonPos *, Item *);
|
||||
extern void sub_806A6E8(Entity *);
|
||||
extern void sub_8042390(Entity *, Item *);
|
||||
|
||||
@@ -67,8 +67,6 @@ extern void sub_8041B48(Entity *pokemon);
|
||||
extern void sub_8041BA8(Entity *pokemon);
|
||||
extern void sub_8042950(Entity *r0);
|
||||
|
||||
extern void SetShopkeeperAggression(Entity *, Entity *);
|
||||
|
||||
extern const s32 gUnknown_8106A50;
|
||||
extern const s32 gUnknown_8106A4C;
|
||||
|
||||
|
||||
@@ -21,7 +21,6 @@ extern u8 DisplayActions(Entity *);
|
||||
extern void sub_805E804(void);
|
||||
void TryPointCameraToMonster(Entity *pokemon, u8 param_2);
|
||||
extern void nullsub_93(DungeonPos *);
|
||||
extern void sub_806F370(Entity *pokemon, Entity *target, u32, u32, u8 *, u8 moveType, s32, u32, u32, u32);
|
||||
extern void sub_807EC28(bool8);
|
||||
extern void sub_806A5B8(Entity *);
|
||||
|
||||
|
||||
@@ -26,8 +26,8 @@
|
||||
#include "dungeon_items.h"
|
||||
#include "dungeon_strings.h"
|
||||
#include "dungeon_engine.h"
|
||||
#include "dungeon_damage.h"
|
||||
|
||||
extern void sub_806F370(Entity *pokemon, Entity *target, u32, u32, u8 *, u8 moveType, s32, u32, u32, u32);
|
||||
extern void sub_804216C(Entity *pokemon, Entity *target, u32 r2);
|
||||
extern void sub_804218C(Entity *pokemon, Entity *target);
|
||||
|
||||
|
||||
@@ -39,10 +39,10 @@
|
||||
#include "structs/str_dungeon.h"
|
||||
#include "weather.h"
|
||||
#include "dungeon_pos_data.h"
|
||||
#include "dungeon_damage.h"
|
||||
|
||||
extern void sub_80833E8(DungeonPos *param_1, s32 *param_2);
|
||||
extern void sub_806A5B8(Entity *);
|
||||
extern void sub_806F370(Entity *pokemon, Entity *target, u32, u32, u8 *, u8 moveType, s32, u32, u32, u32);
|
||||
extern void sub_807D068(Entity *, DungeonPos *);
|
||||
extern void sub_807EC28(bool8 arg0);
|
||||
|
||||
|
||||
@@ -37,12 +37,10 @@
|
||||
extern void sub_806A5B8(Entity *entity);
|
||||
void sub_8075900(Entity *pokemon, u8 r1);
|
||||
extern void sub_807EC28(bool8);
|
||||
extern void sub_806F370(Entity *r0, Entity *r1, u32, u32, u8 *, u8, s32, u32, u32, u32);
|
||||
extern void MudWaterSportEffect(u32);
|
||||
extern void sub_806A6E8(Entity *);
|
||||
|
||||
extern void EndAbilityImmuneStatus(Entity *, Entity *);
|
||||
extern u8 sub_806F4A4(Entity *, u32);
|
||||
extern void HandleExplosion(Entity *pokemon, Entity *target, DungeonPos *pos, u32, u8 moveType, s16);
|
||||
extern void nullsub_92(Entity *);
|
||||
extern u8 sub_807EAA0(u32, u32);
|
||||
@@ -52,7 +50,6 @@ extern bool8 sub_805727C(Entity *, Entity *, s32);
|
||||
bool8 RollSecondaryEffect(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 s16 sub_8057600(Move *move, s32 itemID);
|
||||
|
||||
// Note: For some reason I have to define these as an array of 1 to match asm.
|
||||
|
||||
@@ -35,10 +35,7 @@
|
||||
#include "dungeon_strings.h"
|
||||
#include "dungeon_damage.h"
|
||||
|
||||
extern void sub_806F370(Entity *r0, Entity *r1, u32, u32, u8 *, u8, s32, u32, u32, u32);
|
||||
|
||||
extern void EndAbilityImmuneStatus(Entity *, Entity *);
|
||||
extern u8 sub_806F4A4(Entity *, u32);
|
||||
extern void HandleExplosion(Entity *pokemon, Entity *target, DungeonPos *pos, u32, u8 moveType, s16);
|
||||
extern void nullsub_92(Entity *);
|
||||
extern u8 sub_807EAA0(u32, u32);
|
||||
|
||||
@@ -43,12 +43,10 @@
|
||||
#include "dungeon_engine.h"
|
||||
|
||||
extern void sub_807EC28(bool8);
|
||||
extern void sub_806F370(Entity *r0, Entity *r1, u32, u32, u8 *, u8, s32, u32, u32, u32);
|
||||
static void sub_805A7D4(Entity *, Entity *, Item *, DungeonPos *);
|
||||
extern void MudWaterSportEffect(u32);
|
||||
extern void sub_806A6E8(Entity *);
|
||||
|
||||
extern u8 sub_806F4A4(Entity *, u32);
|
||||
extern void HandleExplosion(Entity *pokemon, Entity *target, DungeonPos *pos, u32, u8 moveType, s16);
|
||||
extern void nullsub_92(Entity *);
|
||||
extern u8 sub_807EAA0(u32, u32);
|
||||
|
||||
@@ -39,7 +39,6 @@
|
||||
|
||||
extern void sub_807F43C(Entity *, Entity *);
|
||||
extern void HandleOneRoomOrb(Entity *, Entity *);
|
||||
extern void sub_806F370(Entity *r0, Entity *r1, u32, u32, u8 *, u8, s32, u32, u32, u32);
|
||||
extern void UpdateMinimap(void);
|
||||
extern void HandleDroughtOrbAction(Entity *);
|
||||
extern void HandleLuminousOrbAction(Entity *pokemon);
|
||||
|
||||
@@ -41,7 +41,6 @@ bool8 sub_806AA0C(s32, s32);
|
||||
void sub_80421EC(DungeonPos *, u32);
|
||||
u8 GetFloorType(void);
|
||||
void sub_8045BF8(u8 *, Item *);
|
||||
void sub_806F480(Entity *, u32);
|
||||
void sub_804225C(Entity *, DungeonPos *, u8);
|
||||
void EnemyEvolution(Entity *);
|
||||
void sub_806A1E8(Entity *pokemon);
|
||||
@@ -327,10 +326,10 @@ void TryTriggerTrap(Entity *pokemon, DungeonPos *pos, int param_3, char param_4)
|
||||
}
|
||||
if (target != NULL) {
|
||||
if (trapData->unk1 == 2) {
|
||||
sub_806F480(target,1);
|
||||
sub_806F480(target,TRUE);
|
||||
}
|
||||
else if (trapData->unk1 == 1) {
|
||||
sub_806F480(target,0);
|
||||
sub_806F480(target,FALSE);
|
||||
}
|
||||
}
|
||||
switch(trapData->id) {
|
||||
|
||||
@@ -32,7 +32,6 @@ bool8 ExposeTrap(s32 x, s32 y);
|
||||
void UpdateMinimap();
|
||||
void sub_807EC28(u32);
|
||||
u8 IsFloorOver(void);
|
||||
extern void sub_806F370(Entity *pokemon, Entity *target, u32, u32, u8 *, u8 moveType, s32, u32, u32, u32);
|
||||
void sub_80421AC(Entity * pokemon, Entity * target);
|
||||
void sub_807BB78(Entity *pokemon);
|
||||
extern void UpdateCamera(u32);
|
||||
|
||||
Reference in New Issue
Block a user