summaryrefslogtreecommitdiff
path: root/maps/Route38.asm
blob: 4f5dc4dda90f75e5d7307e3b60fe40fdd0cda710 (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
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
Route38_MapScriptHeader: ; 0x1a1d0c
	; trigger count
	db 0

	; callback count
	db 0
; 0x1a1d0e

TrainerBird_keeperToby: ; 0x1a1d0e
	; bit/flag number
	dw $3ff

	; trainer group && trainer id
	db BIRD_KEEPER, TOBY

	; text when seen
	dw Bird_keeperTobySeenText

	; text when trainer beaten
	dw Bird_keeperTobyBeatenText

	; script when lost
	dw $0000

	; script when talk again
	dw Bird_keeperTobyScript
; 0x1a1d1a

Bird_keeperTobyScript: ; 0x1a1d1a
	talkaftercancel
	loadfont
	2writetext UnknownText_0x1a1f86
	closetext
	loadmovesprites
	end
; 0x1a1d22

TrainerSailorHarry: ; 0x1a1d22
	; bit/flag number
	dw $57e

	; trainer group && trainer id
	db SAILOR, HARRY

	; text when seen
	dw SailorHarrySeenText

	; text when trainer beaten
	dw SailorHarryBeatenText

	; script when lost
	dw $0000

	; script when talk again
	dw SailorHarryScript
; 0x1a1d2e

SailorHarryScript: ; 0x1a1d2e
	talkaftercancel
	loadfont
	2writetext UnknownText_0x1a220c
	closetext
	loadmovesprites
	end
; 0x1a1d36

TrainerLassDana1: ; 0x1a1d36
	; bit/flag number
	dw $51e

	; trainer group && trainer id
	db LASS, DANA1

	; text when seen
	dw LassDana1SeenText

	; text when trainer beaten
	dw LassDana1BeatenText

	; script when lost
	dw $0000

	; script when talk again
	dw LassDana1Script
; 0x1a1d42

LassDana1Script: ; 0x1a1d42
	writecode $17, $1a
	talkaftercancel
	loadfont
	checkflag $0074
	iftrue UnknownScript_0x1a1d82
	checkflag $0082
	iftrue UnknownScript_0x1a1df6
	checkcellnum $1a
	iftrue UnknownScript_0x1a1e17
	checkevent $0289
	iftrue UnknownScript_0x1a1d6b
	2writetext UnknownText_0x1a20ec
	keeptextopen
	setevent $0289
	2call UnknownScript_0x1a1e0b
	2jump UnknownScript_0x1a1d6e
; 0x1a1d6b

UnknownScript_0x1a1d6b: ; 0x1a1d6b
	2call UnknownScript_0x1a1e0f
UnknownScript_0x1a1d6e: ; 0x1a1d6e
	askforphonenumber $1a
	if_equal $1, UnknownScript_0x1a1e1f
	if_equal $2, UnknownScript_0x1a1e1b
	trainertotext LASS, DANA1, $0
	2call UnknownScript_0x1a1e13
	2jump UnknownScript_0x1a1e17
; 0x1a1d82

UnknownScript_0x1a1d82: ; 0x1a1d82
	2call UnknownScript_0x1a1e23
	winlosstext LassDana1BeatenText, $0000
	copybytetovar $da03
	if_equal $4, UnknownScript_0x1a1da1
	if_equal $3, UnknownScript_0x1a1da7
	if_equal $2, UnknownScript_0x1a1dad
	if_equal $1, UnknownScript_0x1a1db3
	if_equal $0, UnknownScript_0x1a1db9
UnknownScript_0x1a1da1: ; 0x1a1da1
	checkevent EVENT_RESTORED_POWER_TO_KANTO
	iftrue UnknownScript_0x1a1ded
UnknownScript_0x1a1da7: ; 0x1a1da7
	checkevent $0044
	iftrue UnknownScript_0x1a1de0
UnknownScript_0x1a1dad: ; 0x1a1dad
	checkevent EVENT_CLEARED_RADIO_TOWER
	iftrue UnknownScript_0x1a1dd3
UnknownScript_0x1a1db3: ; 0x1a1db3
	checkflag $0045
	iftrue UnknownScript_0x1a1dc6
UnknownScript_0x1a1db9: ; 0x1a1db9
	loadtrainer LASS, DANA1
	startbattle
	returnafterbattle
	loadvar $da03, $1
	clearflag $0074
	end
; 0x1a1dc6

UnknownScript_0x1a1dc6: ; 0x1a1dc6
	loadtrainer LASS, DANA2
	startbattle
	returnafterbattle
	loadvar $da03, $2
	clearflag $0074
	end
; 0x1a1dd3

UnknownScript_0x1a1dd3: ; 0x1a1dd3
	loadtrainer LASS, DANA3
	startbattle
	returnafterbattle
	loadvar $da03, $3
	clearflag $0074
	end
; 0x1a1de0

UnknownScript_0x1a1de0: ; 0x1a1de0
	loadtrainer LASS, DANA4
	startbattle
	returnafterbattle
	loadvar $da03, $4
	clearflag $0074
	end
; 0x1a1ded

UnknownScript_0x1a1ded: ; 0x1a1ded
	loadtrainer LASS, DANA5
	startbattle
	returnafterbattle
	clearflag $0074
	end
; 0x1a1df6

UnknownScript_0x1a1df6: ; 0x1a1df6
	2call UnknownScript_0x1a1e27
	verbosegiveitem THUNDERSTONE, 1
	iffalse UnknownScript_0x1a1e08
	clearflag $0082
	setevent $0102
	2jump UnknownScript_0x1a1e17
; 0x1a1e08

UnknownScript_0x1a1e08: ; 0x1a1e08
	2jump UnknownScript_0x1a1e2b
; 0x1a1e0b

UnknownScript_0x1a1e0b: ; 0x1a1e0b
	jumpstd $0023
	end
; 0x1a1e0f

UnknownScript_0x1a1e0f: ; 0x1a1e0f
	jumpstd $0024
	end
; 0x1a1e13

UnknownScript_0x1a1e13: ; 0x1a1e13
	jumpstd $0025
	end
; 0x1a1e17

UnknownScript_0x1a1e17: ; 0x1a1e17
	jumpstd $0026
	end
; 0x1a1e1b

UnknownScript_0x1a1e1b: ; 0x1a1e1b
	jumpstd $0027
	end
; 0x1a1e1f

UnknownScript_0x1a1e1f: ; 0x1a1e1f
	jumpstd $0028
	end
; 0x1a1e23

UnknownScript_0x1a1e23: ; 0x1a1e23
	jumpstd $0029
	end
; 0x1a1e27

UnknownScript_0x1a1e27: ; 0x1a1e27
	jumpstd $002a
	end
; 0x1a1e2b

UnknownScript_0x1a1e2b: ; 0x1a1e2b
	jumpstd $002b
	end
; 0x1a1e2f

TrainerSchoolboyChad1: ; 0x1a1e2f
	; bit/flag number
	dw $475

	; trainer group && trainer id
	db SCHOOLBOY, CHAD1

	; text when seen
	dw SchoolboyChad1SeenText

	; text when trainer beaten
	dw SchoolboyChad1BeatenText

	; script when lost
	dw $0000

	; script when talk again
	dw SchoolboyChad1Script
; 0x1a1e3b

SchoolboyChad1Script: ; 0x1a1e3b
	writecode $17, $1b
	talkaftercancel
	loadfont
	checkflag $0075
	iftrue UnknownScript_0x1a1e75
	checkcellnum $1b
	iftrue UnknownScript_0x1a1ef5
	checkevent $028b
	iftrue UnknownScript_0x1a1e5e
	2writetext UnknownText_0x1a200e
	keeptextopen
	setevent $028b
	2call UnknownScript_0x1a1ee9
	2jump UnknownScript_0x1a1e61
; 0x1a1e5e

UnknownScript_0x1a1e5e: ; 0x1a1e5e
	2call UnknownScript_0x1a1eed
UnknownScript_0x1a1e61: ; 0x1a1e61
	askforphonenumber $1b
	if_equal $1, UnknownScript_0x1a1efd
	if_equal $2, UnknownScript_0x1a1ef9
	trainertotext SCHOOLBOY, CHAD1, $0
	2call UnknownScript_0x1a1ef1
	2jump UnknownScript_0x1a1ef5
; 0x1a1e75

UnknownScript_0x1a1e75: ; 0x1a1e75
	2call UnknownScript_0x1a1f01
	winlosstext SchoolboyChad1BeatenText, $0000
	copybytetovar $da04
	if_equal $4, UnknownScript_0x1a1e94
	if_equal $3, UnknownScript_0x1a1e9a
	if_equal $2, UnknownScript_0x1a1ea0
	if_equal $1, UnknownScript_0x1a1ea6
	if_equal $0, UnknownScript_0x1a1eac
UnknownScript_0x1a1e94: ; 0x1a1e94
	checkevent EVENT_RESTORED_POWER_TO_KANTO
	iftrue UnknownScript_0x1a1ee0
UnknownScript_0x1a1e9a: ; 0x1a1e9a
	checkevent $0044
	iftrue UnknownScript_0x1a1ed3
UnknownScript_0x1a1ea0: ; 0x1a1ea0
	checkevent EVENT_CLEARED_RADIO_TOWER
	iftrue UnknownScript_0x1a1ec6
UnknownScript_0x1a1ea6: ; 0x1a1ea6
	checkflag $0049
	iftrue UnknownScript_0x1a1eb9
UnknownScript_0x1a1eac: ; 0x1a1eac
	loadtrainer SCHOOLBOY, CHAD1
	startbattle
	returnafterbattle
	loadvar $da04, $1
	clearflag $0075
	end
; 0x1a1eb9

UnknownScript_0x1a1eb9: ; 0x1a1eb9
	loadtrainer SCHOOLBOY, CHAD2
	startbattle
	returnafterbattle
	loadvar $da04, $2
	clearflag $0075
	end
; 0x1a1ec6

UnknownScript_0x1a1ec6: ; 0x1a1ec6
	loadtrainer SCHOOLBOY, CHAD3
	startbattle
	returnafterbattle
	loadvar $da04, $3
	clearflag $0075
	end
; 0x1a1ed3

UnknownScript_0x1a1ed3: ; 0x1a1ed3
	loadtrainer SCHOOLBOY, CHAD4
	startbattle
	returnafterbattle
	loadvar $da04, $4
	clearflag $0075
	end
; 0x1a1ee0

UnknownScript_0x1a1ee0: ; 0x1a1ee0
	loadtrainer SCHOOLBOY, CHAD5
	startbattle
	returnafterbattle
	clearflag $0075
	end
; 0x1a1ee9

UnknownScript_0x1a1ee9: ; 0x1a1ee9
	jumpstd $0019
	end
; 0x1a1eed

UnknownScript_0x1a1eed: ; 0x1a1eed
	jumpstd $001a
	end
; 0x1a1ef1

UnknownScript_0x1a1ef1: ; 0x1a1ef1
	jumpstd $001b
	end
; 0x1a1ef5

UnknownScript_0x1a1ef5: ; 0x1a1ef5
	jumpstd $001c
	end
; 0x1a1ef9

UnknownScript_0x1a1ef9: ; 0x1a1ef9
	jumpstd $001d
	end
; 0x1a1efd

UnknownScript_0x1a1efd: ; 0x1a1efd
	jumpstd $001e
	end
; 0x1a1f01

UnknownScript_0x1a1f01: ; 0x1a1f01
	jumpstd $001f
	end
; 0x1a1f05

TrainerBeautyValerie: ; 0x1a1f05
	; bit/flag number
	dw $4bc

	; trainer group && trainer id
	db BEAUTY, VALERIE

	; text when seen
	dw BeautyValerieSeenText

	; text when trainer beaten
	dw BeautyValerieBeatenText

	; script when lost
	dw $0000

	; script when talk again
	dw BeautyValerieScript
; 0x1a1f11

BeautyValerieScript: ; 0x1a1f11
	talkaftercancel
	loadfont
	2writetext UnknownText_0x1a2185
	closetext
	loadmovesprites
	end
; 0x1a1f19

TrainerBeautyOlivia: ; 0x1a1f19
	; bit/flag number
	dw $5c1

	; trainer group && trainer id
	db BEAUTY, OLIVIA

	; text when seen
	dw BeautyOliviaSeenText

	; text when trainer beaten
	dw BeautyOliviaBeatenText

	; script when lost
	dw $0000

	; script when talk again
	dw BeautyOliviaScript
; 0x1a1f25

BeautyOliviaScript: ; 0x1a1f25
	talkaftercancel
	loadfont
	2writetext UnknownText_0x1a229a
	closetext
	loadmovesprites
	end
; 0x1a1f2d

MapRoute38Signpost0Script: ; 0x1a1f2d
	jumptext UnknownText_0x1a22fd
; 0x1a1f30

MapRoute38Signpost1Script: ; 0x1a1f30
	jumptext UnknownText_0x1a2324
; 0x1a1f33

FruitTreeScript_0x1a1f33: ; 0x1a1f33
	fruittree $3
; 0x1a1f35

Bird_keeperTobySeenText: ; 0x1a1f35
	text "Fly high into the"
	line "sky, my beloved"
	cont "bird #MON!"
	done
; 0x1a1f63

Bird_keeperTobyBeatenText: ; 0x1a1f63
	text "I feel like just"
	line "flying away now."
	done
; 0x1a1f86

UnknownText_0x1a1f86: ; 0x1a1f86
	text "I plan to train in"
	line "CIANWOOD CITY to"

	para "teach my #MON"
	line "how to FLY."
	done
; 0x1a1fc5

SchoolboyChad1SeenText: ; 0x1a1fc5
	text "Let me try some-"
	line "thing I learned"
	cont "today."
	done
; 0x1a1fee

SchoolboyChad1BeatenText: ; 0x1a1fee
	text "I didn't study"
	line "enough, I guess."
	done
; 0x1a200e

UnknownText_0x1a200e: ; 0x1a200e
	text "I have to take so"
	line "many tests, I"

	para "don't have much"
	line "time for #MON."

	para "So when I do get"
	line "to play, I really"
	cont "concentrate."
	done
; 0x1a207d

LassDana1SeenText: ; 0x1a207d
	text "You seem to be"
	line "good at #MON."

	para "If you are, how"
	line "about giving me"
	cont "some advice?"
	done
; 0x1a20c8

LassDana1BeatenText: ; 0x1a20c8
	text "I see. So you can"
	line "battle that way."
	done
; 0x1a20ec

UnknownText_0x1a20ec: ; 0x1a20ec
	text "I know something"
	line "good!"

	para "MOOMOO FARM's milk"
	line "is famous for its"
	cont "flavor."
	done
; 0x1a2130

BeautyValerieSeenText: ; 0x1a2130
	text "Hi! Aren't you a"
	line "cute trainer!"

	para "May I see your"
	line "#MON?"
	done
; 0x1a2164

BeautyValerieBeatenText: ; 0x1a2164
	text "I'm glad I got to"
	line "see your #MON!"
	done
; 0x1a2185

UnknownText_0x1a2185: ; 0x1a2185
	text "When I see #-"
	line "MON, it seems to"
	cont "soothe my nerves."
	done
; 0x1a21b7

SailorHarrySeenText: ; 0x1a21b7
	text "I've been over-"
	line "seas, so I know"

	para "about all sorts of"
	line "#MON!"
	done
; 0x1a21f0

SailorHarryBeatenText: ; 0x1a21f0
	text "Your skill is"
	line "world class!"
	done
; 0x1a220c

UnknownText_0x1a220c: ; 0x1a220c
	text "All kinds of peo-"
	line "ple around the"

	para "world live happily"
	line "with #MON."
	done
; 0x1a224c

BeautyOliviaSeenText: ; 0x1a224c
	text "Don't you think my"
	line "#MON and I are"
	cont "beautiful?"
	done
; 0x1a2279

BeautyOliviaBeatenText: ; 0x1a2279
	text "We drink MOOMOO"
	line "MILK every day."
	done
; 0x1a229a

UnknownText_0x1a229a: ; 0x1a229a
	text "MOOMOO MILK is"
	line "good for beauty"

	para "and health, but"
	line "inconveniently,"

	para "they only sell a"
	line "bottle at a time."
	done
; 0x1a22fd

UnknownText_0x1a22fd: ; 0x1a22fd
	text "ROUTE 38"

	para "OLIVINE CITY -"
	line "ECRUTEAK CITY"
	done
; 0x1a2324

UnknownText_0x1a2324: ; 0x1a2324
	text "TRAINER TIPS"

	para "If a #MON is"
	line "trying to evolve,"
	cont "you can stop it."

	para "Press the B But-"
	line "ton during evolu-"
	cont "tion."

	para "That startles the"
	line "#MON and stops"
	cont "its evolution."
	done
; 0x1a23bb

Route38_MapEventHeader: ; 0x1a23bb
	; filler
	db 0, 0

	; warps
	db 2
	warp_def $8, $23, 1, GROUP_ROUTE_38_ECRUTEAK_GATE, MAP_ROUTE_38_ECRUTEAK_GATE
	warp_def $9, $23, 2, GROUP_ROUTE_38_ECRUTEAK_GATE, MAP_ROUTE_38_ECRUTEAK_GATE

	; xy triggers
	db 0

	; signposts
	db 2
	signpost 7, 33, $0, MapRoute38Signpost0Script
	signpost 13, 5, $0, MapRoute38Signpost1Script

	; people-events
	db 7
	person_event SPRITE_STANDING_YOUNGSTER, 5, 8, $9, $0, 255, 255, $92, 1, TrainerSchoolboyChad1, $ffff
	person_event SPRITE_LASS, 7, 19, $a, $0, 255, 255, $92, 2, TrainerLassDana1, $ffff
	person_event SPRITE_STANDING_YOUNGSTER, 19, 16, $a, $0, 255, 255, $92, 1, TrainerBird_keeperToby, $ffff
	person_event SPRITE_BUENA, 13, 23, $6, $0, 255, 255, $92, 1, TrainerBeautyValerie, $ffff
	person_event SPRITE_SAILOR, 9, 28, $1e, $0, 255, 255, $92, 2, TrainerSailorHarry, $ffff
	person_event SPRITE_FRUIT_TREE, 14, 16, $1, $0, 255, 255, $0, 0, FruitTreeScript_0x1a1f33, $ffff
	person_event SPRITE_BUENA, 12, 9, $a, $0, 255, 255, $92, 1, TrainerBeautyOlivia, $ffff
; 0x1a2430