summaryrefslogtreecommitdiff
path: root/include/constants
diff options
context:
space:
mode:
authorDizzyEggg <jajkodizzy@wp.pl>2018-02-08 11:17:41 +0100
committerDizzyEggg <jajkodizzy@wp.pl>2018-02-08 11:17:41 +0100
commit96290f4ee3864afdd9946541706102ecf6c1c009 (patch)
treed22bc2135fdee82ab53023ee42a2164379aafe82 /include/constants
parenta10fd5a7c4d92551c579baacf07c499b6f434619 (diff)
pokemon and battle constants
Diffstat (limited to 'include/constants')
-rw-r--r--include/constants/battle_script_commands.h97
-rw-r--r--include/constants/pokemon.h80
2 files changed, 177 insertions, 0 deletions
diff --git a/include/constants/battle_script_commands.h b/include/constants/battle_script_commands.h
new file mode 100644
index 000000000..0390f17f4
--- /dev/null
+++ b/include/constants/battle_script_commands.h
@@ -0,0 +1,97 @@
+#ifndef GUARD_CONSTANTS_BATTLE_SCRIPT_COMMANDS_H
+#define GUARD_CONSTANTS_BATTLE_SCRIPT_COMMANDS_H
+
+// Battle Scripting and BattleCommunication addresses
+#define sPAINSPLIT_HP gBattleScripting
+#define sBIDE_DMG gBattleScripting + 4
+#define sMULTIHIT_STRING gBattleScripting + 8
+#define sDMG_MULTIPLIER gBattleScripting + 0xE
+#define sTWOTURN_STRINGID gBattleScripting + 0xF
+#define sB_ANIM_ARG1 gBattleScripting + 0x10
+#define sB_ANIM_ARG2 gBattleScripting + 0x11
+#define sTRIPLE_KICK_POWER gBattleScripting + 0x12
+#define sMOVEEND_STATE gBattleScripting + 0x14
+#define sBANK_WITH_ABILITY gBattleScripting + 0x15
+#define sMULTIHIT_EFFECT gBattleScripting + 0x16
+#define sBANK gBattleScripting + 0x17
+#define sB_ANIM_TURN gBattleScripting + 0x18
+#define sB_ANIM_TARGETS_HIT gBattleScripting + 0x19
+#define sSTATCHANGER gBattleScripting + 0x1A
+#define sFIELD_1B gBattleScripting + 0x1B
+#define sGIVEEXP_STATE gBattleScripting + 0x1C
+#define sBATTLE_STYLE gBattleScripting + 0x1D
+#define sLVLBOX_STATE gBattleScripting + 0x1E
+#define sLEARNMOVE_STATE gBattleScripting + 0x1F
+#define sFIELD_20 gBattleScripting + 0x20
+#define sRESHOW_MAIN_STATE gBattleScripting + 0x21
+#define sRESHOW_HELPER_STATE gBattleScripting + 0x22
+#define sFIELD_23 gBattleScripting + 0x23
+#define sFIELD_24 gBattleScripting + 0x24
+#define sMULTIPLAYER_ID gBattleScripting + 0x25
+
+#define cEFFECT_CHOOSER gBattleCommunication + 3
+#define cMULTISTRING_CHOOSER gBattleCommunication + 5
+
+// Battle Script defines for getting the wanted battler
+#define BS_TARGET 0
+#define BS_ATTACKER 1
+#define BS_EFFECT_BATTLER 2
+#define BS_FAINTED 3
+#define BS_BANK_0 7
+#define BS_ATTACKER_WITH_PARTNER 4 // for atk98_status_icon_update
+#define BS_ATTACKER_SIDE 8 // for atk1E_jumpifability
+#define BS_NOT_ATTACKER_SIDE 9 // for atk1E_jumpifability
+#define BS_SCRIPTING 10
+#define BS_PLAYER1 11
+#define BS_OPPONENT1 12
+#define BS_PLAYER2 13
+#define BS_OPPONENT2 14
+
+// atk 01, accuracy calc
+#define NO_ACC_CALC 0xFFFE
+#define NO_ACC_CALC_CHECK_LOCK_ON 0xFFFF
+#define ACC_CURR_MOVE 0
+
+// compare operands
+#define CMP_EQUAL 0x0
+#define CMP_NOT_EQUAL 0x1
+#define CMP_GREATER_THAN 0x2
+#define CMP_LESS_THAN 0x3
+#define CMP_COMMON_BITS 0x4
+#define CMP_NO_COMMON_BITS 0x5
+
+// atk76, various
+#define VARIOUS_CANCEL_MULTI_TURN_MOVES 0
+#define VARIOUS_SET_MAGIC_COAT_TARGET 1
+#define VARIOUS_IS_RUNNING_IMPOSSIBLE 2
+#define VARIOUS_GET_MOVE_TARGET 3
+#define VARIOUS_RESET_INTIMIDATE_TRACE_BITS 5
+#define VARIOUS_UPDATE_CHOICE_MOVE_ON_LVL_UP 6
+#define VARIOUS_EMIT_YESNOBOX 13
+#define VARIOUS_WAIT_CRY 18
+#define VARIOUS_RETURN_OPPONENT_MON1 19
+#define VARIOUS_RETURN_OPPONENT_MON2 20
+#define VARIOUS_SET_TELEPORT_OUTCOME 25
+#define VARIOUS_PLAY_TRAINER_DEFEATED_MUSIC 26
+
+// atk80, dmg manipulation
+#define ATK80_DMG_CHANGE_SIGN 0
+#define ATK80_DMG_HALF_BY_TWO_NOT_MORE_THAN_HALF_MAX_HP 1
+#define ATK80_DMG_DOUBLED 2
+
+// atk4F, a flag used for the jumpifcantswitch command
+#define ATK4F_DONT_CHECK_STATUSES 0x80
+
+// statchange defines
+#define STAT_CHANGE_BS_PTR 0x1
+#define STAT_CHANGE_NOT_PROTECT_AFFECTED 0x20
+#define STAT_CHANGE_WORKED 0
+#define STAT_CHANGE_DIDNT_WORK 1
+
+// atk48
+#define ATK48_STAT_NEGATIVE 0x1
+#define ATK48_STAT_BY_TWO 0x2
+#define ATK48_BIT_x4 0x4
+#define ATK48_LOWER_FAIL_CHECK 0x8
+
+#endif // GUARD_CONSTANTS_BATTLE_SCRIPT_COMMANDS_H
diff --git a/include/constants/pokemon.h b/include/constants/pokemon.h
new file mode 100644
index 000000000..78c1583b4
--- /dev/null
+++ b/include/constants/pokemon.h
@@ -0,0 +1,80 @@
+#ifndef GUARD_CONSTANTS_POKEMON_H
+#define GUARD_CONSTANTS_POKEMON_H
+
+// Pokemon types
+#define TYPE_NORMAL 0x00
+#define TYPE_FIGHTING 0x01
+#define TYPE_FLYING 0x02
+#define TYPE_POISON 0x03
+#define TYPE_GROUND 0x04
+#define TYPE_ROCK 0x05
+#define TYPE_BUG 0x06
+#define TYPE_GHOST 0x07
+#define TYPE_STEEL 0x08
+#define TYPE_MYSTERY 0x09
+#define TYPE_FIRE 0x0a
+#define TYPE_WATER 0x0b
+#define TYPE_GRASS 0x0c
+#define TYPE_ELECTRIC 0x0d
+#define TYPE_PSYCHIC 0x0e
+#define TYPE_ICE 0x0f
+#define TYPE_DRAGON 0x10
+#define TYPE_DARK 0x11
+#define NUMBER_OF_MON_TYPES 0x12
+
+// Pokemon egg groups
+#define EGG_GROUP_NONE 0
+#define EGG_GROUP_MONSTER 1
+#define EGG_GROUP_WATER_1 2
+#define EGG_GROUP_BUG 3
+#define EGG_GROUP_FLYING 4
+#define EGG_GROUP_FIELD 5
+#define EGG_GROUP_FAIRY 6
+#define EGG_GROUP_GRASS 7
+#define EGG_GROUP_HUMAN_LIKE 8
+#define EGG_GROUP_WATER_3 9
+#define EGG_GROUP_MINERAL 10
+#define EGG_GROUP_AMORPHOUS 11
+#define EGG_GROUP_WATER_2 12
+#define EGG_GROUP_DITTO 13
+#define EGG_GROUP_DRAGON 14
+#define EGG_GROUP_UNDISCOVERED 15
+
+// Pokemon natures
+#define NATURE_HARDY 0
+#define NATURE_LONELY 1
+#define NATURE_BRAVE 2
+#define NATURE_ADAMANT 3
+#define NATURE_NAUGHTY 4
+#define NATURE_BOLD 5
+#define NATURE_DOCILE 6
+#define NATURE_RELAXED 7
+#define NATURE_IMPISH 8
+#define NATURE_LAX 9
+#define NATURE_TIMID 10
+#define NATURE_HASTY 11
+#define NATURE_SERIOUS 12
+#define NATURE_JOLLY 13
+#define NATURE_NAIVE 14
+#define NATURE_MODEST 15
+#define NATURE_MILD 16
+#define NATURE_QUIET 17
+#define NATURE_BASHFUL 18
+#define NATURE_RASH 19
+#define NATURE_CALM 20
+#define NATURE_GENTLE 21
+#define NATURE_SASSY 22
+#define NATURE_CAREFUL 23
+#define NATURE_QUIRKY 24
+
+// Pokemon Stats
+#define STAT_HP 0
+#define STAT_ATK 1
+#define STAT_DEF 2
+#define STAT_SPEED 3
+#define STAT_SPATK 4
+#define STAT_SPDEF 5
+#define STAT_ACC 6 // only in battles
+#define STAT_EVASION 7 // only in battles
+
+#endif // GUARD_CONSTANTS_POKEMON_H