blob: d4a5abb14baf0c21b9fbe4cf9fd0d0edeb4a150f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
|
MAX_LEVEL EQU 100
NUM_MOVES EQU 4
ATTACK EQU 0
DEFENSE EQU 1
SPEED EQU 2
SP_ATTACK EQU 3
SP_DEFENSE EQU 4
ACCURACY EQU 5
EVASION EQU 6
; move struct
MOVE_LENGTH EQU 7
MOVE_ANIM EQU 0
MOVE_EFFECT EQU 1
MOVE_POWER EQU 2
MOVE_TYPE EQU 3
MOVE_ACC EQU 4
MOVE_PP EQU 5
MOVE_CHANCE EQU 6
; stat constants
NUM_STATS EQU 6
STAT_HP EQU 1
STAT_ATK EQU 2
STAT_DEF EQU 3
STAT_SPD EQU 4
STAT_SATK EQU 5
STAT_SDEF EQU 6
STAT_MIN_NORMAL EQU 5
STAT_MIN_HP EQU 10
; shiny dvs
ATKDEFDV_SHINY EQU $EA
SPDSPCDV_SHINY EQU $AA
; battle classes
WILD_BATTLE EQU 1
TRAINER_BATTLE EQU 2
; battle types
BATTLETYPE_NORMAL EQU $00
BATTLETYPE_CANLOSE EQU $01
BATTLETYPE_TUTORIAL EQU $03
BATTLETYPE_FISH EQU $04
BATTLETYPE_ROAMING EQU $05
BATTLETYPE_SHINY EQU $07
BATTLETYPE_TREE EQU $08
BATTLETYPE_FORCEITEM EQU $0a
BATTLETYPE_SUICUNE EQU $0c
; battle variables
BATTLE_VARS_SUBSTATUS1 EQU 0
BATTLE_VARS_SUBSTATUS2 EQU 1
BATTLE_VARS_SUBSTATUS3 EQU 2
BATTLE_VARS_SUBSTATUS4 EQU 3
BATTLE_VARS_SUBSTATUS5 EQU 4
BATTLE_VARS_SUBSTATUS1_OPP EQU 5
BATTLE_VARS_SUBSTATUS2_OPP EQU 6
BATTLE_VARS_SUBSTATUS3_OPP EQU 7
BATTLE_VARS_SUBSTATUS4_OPP EQU 8
BATTLE_VARS_SUBSTATUS5_OPP EQU 9
BATTLE_VARS_STATUS EQU 10
BATTLE_VARS_STATUS_OPP EQU 11
BATTLE_VARS_MOVE_ANIM EQU 12
BATTLE_VARS_MOVE_EFFECT EQU 13
BATTLE_VARS_MOVE_POWER EQU 14
BATTLE_VARS_MOVE_TYPE EQU 15
BATTLE_VARS_MOVE EQU 16
BATTLE_VARS_LAST_COUNTER_MOVE EQU 17
BATTLE_VARS_LAST_COUNTER_MOVE_OPP EQU 18
BATTLE_VARS_LAST_MOVE EQU 19
BATTLE_VARS_LAST_MOVE_OPP EQU 20
; status
SLP EQU 7 ; 7 turns
PSN EQU 3
BRN EQU 4
FRZ EQU 5
PAR EQU 6
; substatus
SUBSTATUS_IN_LOVE EQU 7
SUBSTATUS_ENCORED EQU 6
SUBSTATUS_ENDURE EQU 5
SUBSTATUS_PERISH EQU 4
SUBSTATUS_IDENTIFIED EQU 3
SUBSTATUS_PROTECT EQU 2
SUBSTATUS_CURSE EQU 1
SUBSTATUS_NIGHTMARE EQU 0
SUBSTATUS_CURLED EQU 0
SUBSTATUS_CONFUSED EQU 7
SUBSTATUS_FLYING EQU 6
SUBSTATUS_UNDERGROUND EQU 5
SUBSTATUS_CHARGED EQU 4
SUBSTATUS_FLINCHED EQU 3
SUBSTATUS_ROLLOUT EQU 1
SUBSTATUS_BIDE EQU 0
SUBSTATUS_LEECH_SEED EQU 7
SUBSTATUS_RAGE EQU 6
SUBSTATUS_RECHARGE EQU 5
SUBSTATUS_SUBSTITUTE EQU 4
SUBSTATUS_FOCUS_ENERGY EQU 2
SUBSTATUS_MIST EQU 1
SUBSTATUS_UNLEASH EQU 0
SUBSTATUS_CANT_RUN EQU 7
SUBSTATUS_DESTINY_BOND EQU 6
SUBSTATUS_LOCK_ON EQU 5
SUBSTATUS_TOXIC EQU 0
; environmental
SCREENS_REFLECT EQU 4
SCREENS_LIGHT_SCREEN EQU 3
SCREENS_SAFEGUARD EQU 2
SCREENS_SPIKES EQU 0
; weather
WEATHER_RAIN EQU 1
WEATHER_SUN EQU 2
WEATHER_SANDSTORM EQU 3
WEATHER_RAIN_END EQU 4
WEATHER_SUN_END EQU 5
WEATHER_SANDSTORM_END EQU 6
; move effects
EFFECT_NORMAL_HIT EQU $00
EFFECT_SLEEP EQU $01
EFFECT_POISON_HIT EQU $02
EFFECT_LEECH_HIT EQU $03
EFFECT_BURN_HIT EQU $04
EFFECT_FREEZE_HIT EQU $05
EFFECT_PARALYZE_HIT EQU $06
EFFECT_EXPLOSION EQU $07
EFFECT_DREAM_EATER EQU $08
EFFECT_MIRROR_MOVE EQU $09
EFFECT_ATTACK_UP EQU $0a
EFFECT_DEFENSE_UP EQU $0b
EFFECT_SPEED_UP EQU $0c
EFFECT_SP_ATK_UP EQU $0d
EFFECT_SP_DEF_UP EQU $0e
EFFECT_ACCURACY_UP EQU $0f
EFFECT_EVASION_UP EQU $10
EFFECT_ALWAYS_HIT EQU $11
EFFECT_ATTACK_DOWN EQU $12
EFFECT_DEFENSE_DOWN EQU $13
EFFECT_SPEED_DOWN EQU $14
EFFECT_SP_ATK_DOWN EQU $15
EFFECT_SP_DEF_DOWN EQU $16
EFFECT_ACCURACY_DOWN EQU $17
EFFECT_EVASION_DOWN EQU $18
EFFECT_HAZE EQU $19
EFFECT_BIDE EQU $1a
EFFECT_RAMPAGE EQU $1b
EFFECT_WHIRLWIND EQU $1c
EFFECT_MULTI_HIT EQU $1d
EFFECT_CONVERSION EQU $1e
EFFECT_FLINCH_HIT EQU $1f
EFFECT_HEAL EQU $20
EFFECT_TOXIC EQU $21
EFFECT_PAY_DAY EQU $22
EFFECT_LIGHT_SCREEN EQU $23
EFFECT_TRI_ATTACK EQU $24
EFFECT_UNUSED_25 EQU $25 ; unused
EFFECT_OHKO EQU $26
EFFECT_RAZOR_WIND EQU $27
EFFECT_SUPER_FANG EQU $28
EFFECT_STATIC_DAMAGE EQU $29
EFFECT_BIND EQU $2a
EFFECT_UNUSED_2B EQU $2b ; unused
EFFECT_DOUBLE_HIT EQU $2c
EFFECT_JUMP_KICK EQU $2d
EFFECT_MIST EQU $2e
EFFECT_FOCUS_ENERGY EQU $2f
EFFECT_RECOIL_HIT EQU $30
EFFECT_CONFUSE EQU $31
EFFECT_ATTACK_UP_2 EQU $32
EFFECT_DEFENSE_UP_2 EQU $33
EFFECT_SPEED_UP_2 EQU $34
EFFECT_SP_ATK_UP_2 EQU $35
EFFECT_SP_DEF_UP_2 EQU $36
EFFECT_ACCURACY_UP_2 EQU $37
EFFECT_EVASION_UP_2 EQU $38
EFFECT_TRANSFORM EQU $39
EFFECT_ATTACK_DOWN_2 EQU $3a
EFFECT_DEFENSE_DOWN_2 EQU $3b
EFFECT_SPEED_DOWN_2 EQU $3c
EFFECT_SP_ATK_DOWN_2 EQU $3d
EFFECT_SP_DEF_DOWN_2 EQU $3e
EFFECT_ACCURACY_DOWN_2 EQU $3f
EFFECT_EVASION_DOWN_2 EQU $40
EFFECT_REFLECT EQU $41
EFFECT_POISON EQU $42
EFFECT_PARALYZE EQU $43
EFFECT_ATTACK_DOWN_HIT EQU $44
EFFECT_DEFENSE_DOWN_HIT EQU $45
EFFECT_SPEED_DOWN_HIT EQU $46
EFFECT_SP_ATK_DOWN_HIT EQU $47
EFFECT_SP_DEF_DOWN_HIT EQU $48
EFFECT_ACCURACY_DOWN_HIT EQU $49
EFFECT_EVASION_DOWN_HIT EQU $4a
EFFECT_SKY_ATTACK EQU $4b
EFFECT_CONFUSE_HIT EQU $4c
EFFECT_TWINEEDLE EQU $4d
EFFECT_UNUSED_4E EQU $4e ; unused
EFFECT_SUBSTITUTE EQU $4f
EFFECT_HYPER_BEAM EQU $50
EFFECT_RAGE EQU $51
EFFECT_MIMIC EQU $52
EFFECT_METRONOME EQU $53
EFFECT_LEECH_SEED EQU $54
EFFECT_SPLASH EQU $55
EFFECT_DISABLE EQU $56
EFFECT_LEVEL_DAMAGE EQU $57
EFFECT_PSYWAVE EQU $58
EFFECT_COUNTER EQU $59
EFFECT_ENCORE EQU $5a
EFFECT_PAIN_SPLIT EQU $5b
EFFECT_SNORE EQU $5c
EFFECT_CONVERSION2 EQU $5d
EFFECT_LOCK_ON EQU $5e
EFFECT_SKETCH EQU $5f
EFFECT_DEFROST_OPPONENT EQU $60
EFFECT_SLEEP_TALK EQU $61
EFFECT_DESTINY_BOND EQU $62
EFFECT_REVERSAL EQU $63
EFFECT_SPITE EQU $64
EFFECT_FALSE_SWIPE EQU $65
EFFECT_HEAL_BELL EQU $66
EFFECT_PRIORITY_HIT EQU $67
EFFECT_TRIPLE_KICK EQU $68
EFFECT_THIEF EQU $69
EFFECT_MEAN_LOOK EQU $6a
EFFECT_NIGHTMARE EQU $6b
EFFECT_FLAME_WHEEL EQU $6c
EFFECT_CURSE EQU $6d
EFFECT_UNUSED_6E EQU $6e ; unused
EFFECT_PROTECT EQU $6f
EFFECT_SPIKES EQU $70
EFFECT_FORESIGHT EQU $71
EFFECT_PERISH_SONG EQU $72
EFFECT_SANDSTORM EQU $73
EFFECT_ENDURE EQU $74
EFFECT_ROLLOUT EQU $75
EFFECT_SWAGGER EQU $76
EFFECT_FURY_CUTTER EQU $77
EFFECT_ATTRACT EQU $78
EFFECT_RETURN EQU $79
EFFECT_PRESENT EQU $7a
EFFECT_FRUSTRATION EQU $7b
EFFECT_SAFEGUARD EQU $7c
EFFECT_SACRED_FIRE EQU $7d
EFFECT_MAGNITUDE EQU $7e
EFFECT_BATON_PASS EQU $7f
EFFECT_PURSUIT EQU $80
EFFECT_RAPID_SPIN EQU $81
EFFECT_UNUSED_82 EQU $82 ; unused
EFFECT_UNUSED_83 EQU $83 ; unused
EFFECT_MORNING_SUN EQU $84
EFFECT_SYNTHESIS EQU $85
EFFECT_MOONLIGHT EQU $86
EFFECT_HIDDEN_POWER EQU $87
EFFECT_RAIN_DANCE EQU $88
EFFECT_SUNNY_DAY EQU $89
EFFECT_STEEL_WING EQU $8a
EFFECT_METAL_CLAW EQU $8b
EFFECT_ANCIENTPOWER EQU $8c
EFFECT_FAKE_OUT EQU $8d
EFFECT_BELLY_DRUM EQU $8e
EFFECT_PSYCH_UP EQU $8f
EFFECT_MIRROR_COAT EQU $90
EFFECT_SKULL_BASH EQU $91
EFFECT_TWISTER EQU $92
EFFECT_EARTHQUAKE EQU $93
EFFECT_FUTURE_SIGHT EQU $94
EFFECT_GUST EQU $95
EFFECT_STOMP EQU $96
EFFECT_SOLARBEAM EQU $97
EFFECT_THUNDER EQU $98
EFFECT_TELEPORT EQU $99
EFFECT_BEAT_UP EQU $9a
EFFECT_FLY EQU $9b
EFFECT_DEFENSE_CURL EQU $9c
|