diff options
author | AnonymousRandomPerson <chenghanngan.us@gmail.com> | 2021-12-13 23:22:03 -0500 |
---|---|---|
committer | AnonymousRandomPerson <chenghanngan.us@gmail.com> | 2021-12-14 22:54:03 -0500 |
commit | cd9a8c5a384124999e15626d9623b48f2687deba (patch) | |
tree | 096eef1adbb2781332d71cce238d0d2614b9feee /include | |
parent | 087405b9d975b447ef7b17afd1e73e449cc7881b (diff) |
Decomped CanTarget()
Diffstat (limited to 'include')
-rw-r--r-- | include/constants/status.h | 4 | ||||
-rw-r--r-- | include/constants/targeting.h | 12 | ||||
-rw-r--r-- | include/dungeon_ai_1.h | 9 | ||||
-rw-r--r-- | include/dungeon_entity.h | 9 |
4 files changed, 26 insertions, 8 deletions
diff --git a/include/constants/status.h b/include/constants/status.h index 19b860b..cf911c0 100644 --- a/include/constants/status.h +++ b/include/constants/status.h @@ -94,10 +94,6 @@ #define MUZZLED_STATUS_NONE 0 #define MUZZLED_STATUS_MUZZLED 1 -#define TARGETING_DECOY_NONE 0 -#define TARGETING_DECOY_TEAM 1 -#define TARGETING_DECOY_WILD 2 - #define STATUS_SPRITE_SLEEPLESS (1 << 0) #define STATUS_SPRITE_BURNED (1 << 1) #define STATUS_SPRITE_POISONED (1 << 2) diff --git a/include/constants/targeting.h b/include/constants/targeting.h new file mode 100644 index 0000000..6140716 --- /dev/null +++ b/include/constants/targeting.h @@ -0,0 +1,12 @@ +#ifndef GUARD_CONSTANTS_TARGETING_H +#define GUARD_CONSTANTS_TARGETING_H + +#define TARGETING_DECOY_NONE 0 +#define TARGETING_DECOY_TEAM 1 +#define TARGETING_DECOY_WILD 2 + +#define TARGET_CAPABILITY_CANNOT_ATTACK 0 +#define TARGET_CAPABILITY_CAN_TARGET 1 +#define TARGET_CAPABILITY_CAN_ATTACK_NOT_TARGET 2 + +#endif diff --git a/include/dungeon_ai_1.h b/include/dungeon_ai_1.h new file mode 100644 index 0000000..dace65a --- /dev/null +++ b/include/dungeon_ai_1.h @@ -0,0 +1,9 @@ +#ifndef GUARD_DUNGEON_AI_1_H +#define GUARD_DUNGEON_AI_1_H + +#include "dungeon_entity.h" + +// 0x71598 +u8 CanTarget(struct DungeonEntity *pokemon, struct DungeonEntity *targetPokemon, bool8 ignoreInvisible, bool8 checkPetrified); + +#endif diff --git a/include/dungeon_entity.h b/include/dungeon_entity.h index b894a2f..29e3112 100644 --- a/include/dungeon_entity.h +++ b/include/dungeon_entity.h @@ -287,10 +287,11 @@ enum MovementFlag enum ShopkeeperMode { - SHOPKEEPER_FRIENDLY = 1, + SHOPKEEPER_NONE, + SHOPKEEPER_FRIENDLY, // These two modes trigger if an explosion damages the shopkeeper. The shopkeeper attacks the side that damaged it. - SHOPKEEPER_AGGRESSIVE_TO_WILD = 2, - SHOPKEEPER_AGGRESSIVE_TO_PLAYER = 3 + SHOPKEEPER_AGGRESSIVE_TO_WILD, + SHOPKEEPER_AGGRESSIVE_TO_PLAYER }; enum MovementAction @@ -308,7 +309,7 @@ enum ClientType { CLIENT_TYPE_NONE = 0, CLIENT_TYPE_CLIENT = 1, // Used for mission clients that need rescuing. - CLIENT_TYPE_DONT_MOVE = 3 // Used for Diglett in the Skarmory boss fight. + CLIENT_TYPE_DONT_MOVE = 4 // Used for Diglett in the Skarmory boss fight. }; enum VisualFlag |