summaryrefslogtreecommitdiff
path: root/data/scripts/maps/Route119.inc
blob: 55a3fb1dc3f751889e262408ac681dc664a7d97a (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
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
Route119_MapScripts:: @ 8151167
	map_script 5, Route119_MapScript1_151172
	map_script 3, Route119_MapScript1_15119B
	.byte 0

Route119_MapScript1_151172:: @ 8151172
	checkflag 2145
	callif 1, Route119_EventScript_15117C
	end

Route119_EventScript_15117C:: @ 815117C
	compare 0x8004, 6
	callif 1, Route119_EventScript_151193
	compare 0x8004, 7
	callif 1, Route119_EventScript_151197
	return

Route119_EventScript_151193:: @ 8151193
	disappear 35
	return

Route119_EventScript_151197:: @ 8151197
	disappear 36
	return

Route119_MapScript1_15119B:: @ 815119B
	call Route119_EventScript_1A014E
	call Route119_EventScript_1A0172
	call Route119_EventScript_1A0196
	compare 0x40b3, 1
	callif 1, Route119_EventScript_1511B9
	special SetRoute119Weather
	end

Route119_EventScript_1511B9:: @ 81511B9
	setflag 893
	clearflag 892
	setvar 0x40b3, 2
	return

Route119_EventScript_1511C5:: @ 81511C5
	setvar 0x4001, 1
	jump Route119_EventScript_1511DB
	end

Route119_EventScript_1511D0:: @ 81511D0
	setvar 0x4001, 2
	jump Route119_EventScript_1511DB
	end

Route119_EventScript_1511DB:: @ 81511DB
	lockall
	reappear 25
	checkgender
	compare RESULT, 0
	callif 1, Route119_EventScript_151254
	compare RESULT, 1
	callif 1, Route119_EventScript_151259
	pause 65
	compare 0x4001, 1
	callif 1, Route119_EventScript_1513A6
	compare 0x4001, 2
	callif 1, Route119_EventScript_1513B1
	move 255, Route119_Movement_1A0845
	waitmove 0
	pause 30
	compare 0x4001, 1
	callif 1, Route119_EventScript_1513D2
	compare 0x4001, 2
	callif 1, Route119_EventScript_1513E1
	disappear 25
	reappear 16
	pause 30
	checkgender
	compare RESULT, 0
	jumpeq Route119_EventScript_15125E
	compare RESULT, 1
	jumpeq Route119_EventScript_1512D8
	releaseall
	end

Route119_EventScript_151254:: @ 8151254
	playmusic 415, 1
	return

Route119_EventScript_151259:: @ 8151259
	playmusic 421, 1
	return

Route119_EventScript_15125E:: @ 815125E
	msgbox Route119_Text_1710BB, 4
	switch 0x4023
	case 0, Route119_EventScript_15128D
	case 1, Route119_EventScript_15129D
	case 2, Route119_EventScript_1512AD
	end

Route119_EventScript_15128D:: @ 815128D
	trainerbattle 3, OPPONENT_MAY_6, 0, Route119_Text_171156
	jump Route119_EventScript_1512BD
	end

Route119_EventScript_15129D:: @ 815129D
	trainerbattle 3, OPPONENT_MAY_9, 0, Route119_Text_171156
	jump Route119_EventScript_1512BD
	end

Route119_EventScript_1512AD:: @ 81512AD
	trainerbattle 3, OPPONENT_MAY_3, 0, Route119_Text_171156
	jump Route119_EventScript_1512BD
	end

Route119_EventScript_1512BD:: @ 81512BD
	msgbox Route119_Text_1711B1, 4
	call Route119_EventScript_151352
	msgbox Route119_Text_171214, 4
	jump Route119_EventScript_151362
	end

Route119_EventScript_1512D8:: @ 81512D8
	msgbox Route119_Text_171358, 4
	switch 0x4023
	case 0, Route119_EventScript_151307
	case 1, Route119_EventScript_151317
	case 2, Route119_EventScript_151327
	end

Route119_EventScript_151307:: @ 8151307
	trainerbattle 3, OPPONENT_BRENDAN_6, 0, Route119_Text_1713E2
	jump Route119_EventScript_151337
	end

Route119_EventScript_151317:: @ 8151317
	trainerbattle 3, OPPONENT_BRENDAN_9, 0, Route119_Text_1713E2
	jump Route119_EventScript_151337
	end

Route119_EventScript_151327:: @ 8151327
	trainerbattle 3, OPPONENT_BRENDAN_3, 0, Route119_Text_1713E2
	jump Route119_EventScript_151337
	end

Route119_EventScript_151337:: @ 8151337
	msgbox Route119_Text_17140B, 4
	call Route119_EventScript_151352
	msgbox Route119_Text_171475, 4
	jump Route119_EventScript_151362
	end

Route119_EventScript_151352:: @ 8151352
	giveitem ITEM_HM02
	setflag 110
	return

Route119_EventScript_151362:: @ 8151362
	closebutton
	compare 0x4001, 1
	callif 1, Route119_EventScript_1513D2
	compare 0x4001, 2
	callif 1, Route119_EventScript_1513E1
	disappear 16
	reappear 25
	pause 30
	compare 0x4001, 1
	callif 1, Route119_EventScript_1513BC
	compare 0x4001, 2
	callif 1, Route119_EventScript_1513C7
	disappear 25
	setvar 0x4072, 1
	playmusicbattle 0
	fadedefault
	releaseall
	end

Route119_EventScript_1513A6:: @ 81513A6
	move 25, Route119_Movement_1513F0
	waitmove 0
	return

Route119_EventScript_1513B1:: @ 81513B1
	move 25, Route119_Movement_1513FA
	waitmove 0
	return

Route119_EventScript_1513BC:: @ 81513BC
	move 25, Route119_Movement_151405
	waitmove 0
	return

Route119_EventScript_1513C7:: @ 81513C7
	move 25, Route119_Movement_15140F
	waitmove 0
	return

Route119_EventScript_1513D2:: @ 81513D2
	movespriteperm 16, 25, 32
	movespriteperm 25, 25, 32
	return

Route119_EventScript_1513E1:: @ 81513E1
	movespriteperm 16, 26, 32
	movespriteperm 25, 26, 32
	return

Route119_Movement_1513F0:: @ 81513F0
	step_18
	step_18
	step_18
	step_18
	step_18
	step_18
	step_18
	step_18
	step_16
	step_end

Route119_Movement_1513FA:: @ 81513FA
	step_18
	step_18
	step_18
	step_18
	step_18
	step_18
	step_18
	step_18
	step_18
	step_16
	step_end

Route119_Movement_151405:: @ 8151405
	step_18
	step_16
	step_16
	step_16
	step_18
	step_16
	step_16
	step_16
	step_16
	step_end

Route119_Movement_15140F:: @ 815140F
	step_17
	step_16
	step_16
	step_16
	step_18
	step_18
	step_16
	step_16
	step_16
	step_16
	step_end

Route119_EventScript_15141A:: @ 815141A
	msgbox Route119_Text_171698, 2
	end

Route119_EventScript_151423:: @ 8151423
	msgbox Route119_Text_171749, 3
	end

Route119_EventScript_15142C:: @ 815142C
	msgbox Route119_Text_171762, 3
	end

Route119_EventScript_151435:: @ 8151435
	trainerbattle 0, OPPONENT_BRENT, 0, Route119_Text_1BE521, Route119_Text_1BE54F
	msgbox Route119_Text_1BE561, 6
	end

Route119_EventScript_15144C:: @ 815144C
	trainerbattle 0, OPPONENT_DONALD, 0, Route119_Text_1BE5A4, Route119_Text_1BE5DF
	msgbox Route119_Text_1BE5F8, 6
	end

Route119_EventScript_151463:: @ 8151463
	trainerbattle 0, OPPONENT_TAYLOR, 0, Route119_Text_1BE632, Route119_Text_1BE67B
	msgbox Route119_Text_1BE695, 6
	end

Route119_EventScript_15147A:: @ 815147A
	trainerbattle 0, OPPONENT_DOUG, 0, Route119_Text_1BE6EA, Route119_Text_1BE729
	msgbox Route119_Text_1BE748, 6
	end

Route119_EventScript_151491:: @ 8151491
	trainerbattle 0, OPPONENT_GREG, 0, Route119_Text_1BE784, Route119_Text_1BE7D3
	msgbox Route119_Text_1BE7E9, 6
	end

Route119_EventScript_1514A8:: @ 81514A8
	trainerbattle 0, OPPONENT_KENT, 0, Route119_Text_1BE82F, Route119_Text_1BE88D
	msgbox Route119_Text_1BE89A, 6
	end

Route119_EventScript_1514BF:: @ 81514BF
	trainerbattle 0, OPPONENT_JACKSON_1, 0, Route119_Text_1BE8BB, Route119_Text_1BE90E
	specialval RESULT, sub_8082C68
	compare RESULT, 1
	jumpeq Route119_EventScript_1514E6
	msgbox Route119_Text_1BE937, 6
	end

Route119_EventScript_1514E6:: @ 81514E6
	trainerbattle 5, OPPONENT_JACKSON_1, 0, Route119_Text_1BE98D, Route119_Text_1BE9D0
	msgbox Route119_Text_1BE9E8, 6
	end

Route119_EventScript_1514FD:: @ 81514FD
	trainerbattle 0, OPPONENT_CATHERINE_1, 0, Route119_Text_1BEA3A, Route119_Text_1BEA88
	specialval RESULT, sub_8082C68
	compare RESULT, 1
	jumpeq Route119_EventScript_151524
	msgbox Route119_Text_1BEAB3, 6
	end

Route119_EventScript_151524:: @ 8151524
	trainerbattle 5, OPPONENT_CATHERINE_1, 0, Route119_Text_1BEB22, Route119_Text_1BEB49
	msgbox Route119_Text_1BEB68, 6
	end

Route119_EventScript_15153B:: @ 815153B
	trainerbattle 0, OPPONENT_HUGH, 0, Route119_Text_1BEBC0, Route119_Text_1BEC1C
	msgbox Route119_Text_1BEC2A, 6
	end

Route119_EventScript_151552:: @ 8151552
	trainerbattle 0, OPPONENT_PHIL, 0, Route119_Text_1BEC5E, Route119_Text_1BEC9A
	msgbox Route119_Text_1BECB1, 6
	end

Route119_EventScript_151569:: @ 8151569
	trainerbattle 0, OPPONENT_YASU, 0, Route119_Text_1BECF1, Route119_Text_1BED4C
	msgbox Route119_Text_1BED5C, 6
	end

Route119_EventScript_151580:: @ 8151580
	trainerbattle 0, OPPONENT_TAKASHI, 0, Route119_Text_1BEDB6, Route119_Text_1BEDEC
	msgbox Route119_Text_1BEE06, 6
	end

Route119_EventScript_151597:: @ 8151597
	trainerbattle 0, OPPONENT_HIDEO_2, 0, Route119_Text_1BEE2D, Route119_Text_1BEE4B
	msgbox Route119_Text_1BEE66, 6
	end

Route119_EventScript_1515AE:: @ 81515AE
	trainerbattle 0, OPPONENT_EUGENE, 0, Route119_Text_1BEED0, Route119_Text_1BEF37
	msgbox Route119_Text_1BEF67, 6
	end

Route119_EventScript_1515C5:: @ 81515C5
	lock
	faceplayer
	msgbox Route119_Text_171520, 4
	closebutton
	move LAST_TALKED, Route119_Movement_1A083D
	waitmove 0
	release
	end

Route119_EventScript_1515DC:: @ 81515DC
	lock
	faceplayer
	msgbox Route119_Text_17157C, 4
	closebutton
	move LAST_TALKED, Route119_Movement_1A083D
	waitmove 0
	release
	end

Route119_EventScript_1515F3:: @ 81515F3
	msgbox Route119_Text_1715D7, 2
	end

Route119_EventScript_1515FC:: @ 81515FC
	msgbox Route119_Text_1716F4, 2
	end

Route119_EventScript_151605:: @ 8151605
	msgbox Route119_Text_171774, 3
	end