route18.asm 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. Route18Script:
  2. call EnableAutoTextBoxDrawing
  3. ld hl, Route18TrainerHeader0
  4. ld de, Route18ScriptPointers
  5. ld a, [wRoute18CurScript]
  6. call ExecuteCurMapScriptInTable
  7. ld [wRoute18CurScript], a
  8. ret
  9. Route18ScriptPointers:
  10. dw CheckFightingMapTrainers
  11. dw DisplayEnemyTrainerTextAndStartBattle
  12. dw EndTrainerBattle
  13. Route18TextPointers:
  14. dw Route18Text1
  15. dw Route18Text2
  16. dw Route18Text3
  17. dw Route18Text4
  18. dw Route18Text5
  19. Route18TrainerHeader0:
  20. dbEventFlagBit EVENT_BEAT_ROUTE_18_TRAINER_0
  21. db ($3 << 4) ; trainer's view range
  22. dwEventFlagAddress EVENT_BEAT_ROUTE_18_TRAINER_0
  23. dw Route18BattleText1 ; TextBeforeBattle
  24. dw Route18AfterBattleText1 ; TextAfterBattle
  25. dw Route18EndBattleText1 ; TextEndBattle
  26. dw Route18EndBattleText1 ; TextEndBattle
  27. Route18TrainerHeader1:
  28. dbEventFlagBit EVENT_BEAT_ROUTE_18_TRAINER_1
  29. db ($3 << 4) ; trainer's view range
  30. dwEventFlagAddress EVENT_BEAT_ROUTE_18_TRAINER_1
  31. dw Route18BattleText2 ; TextBeforeBattle
  32. dw Route18AfterBattleText2 ; TextAfterBattle
  33. dw Route18EndBattleText2 ; TextEndBattle
  34. dw Route18EndBattleText2 ; TextEndBattle
  35. Route18TrainerHeader2:
  36. dbEventFlagBit EVENT_BEAT_ROUTE_18_TRAINER_2
  37. db ($4 << 4) ; trainer's view range
  38. dwEventFlagAddress EVENT_BEAT_ROUTE_18_TRAINER_2
  39. dw Route18BattleText3 ; TextBeforeBattle
  40. dw Route18AfterBattleText3 ; TextAfterBattle
  41. dw Route18EndBattleText3 ; TextEndBattle
  42. dw Route18EndBattleText3 ; TextEndBattle
  43. db $ff
  44. Route18Text1:
  45. TX_ASM
  46. ld hl, Route18TrainerHeader0
  47. call TalkToTrainer
  48. jp TextScriptEnd
  49. Route18BattleText1:
  50. TX_FAR _Route18BattleText1
  51. db "@"
  52. Route18EndBattleText1:
  53. TX_FAR _Route18EndBattleText1
  54. db "@"
  55. Route18AfterBattleText1:
  56. TX_FAR _Route18AfterBattleText1
  57. db "@"
  58. Route18Text2:
  59. TX_ASM
  60. ld hl, Route18TrainerHeader1
  61. call TalkToTrainer
  62. jp TextScriptEnd
  63. Route18BattleText2:
  64. TX_FAR _Route18BattleText2
  65. db "@"
  66. Route18EndBattleText2:
  67. TX_FAR _Route18EndBattleText2
  68. db "@"
  69. Route18AfterBattleText2:
  70. TX_FAR _Route18AfterBattleText2
  71. db "@"
  72. Route18Text3:
  73. TX_ASM
  74. ld hl, Route18TrainerHeader2
  75. call TalkToTrainer
  76. jp TextScriptEnd
  77. Route18BattleText3:
  78. TX_FAR _Route18BattleText3
  79. db "@"
  80. Route18EndBattleText3:
  81. TX_FAR _Route18EndBattleText3
  82. db "@"
  83. Route18AfterBattleText3:
  84. TX_FAR _Route18AfterBattleText3
  85. db "@"
  86. Route18Text4:
  87. TX_FAR _Route18Text4
  88. db "@"
  89. Route18Text5:
  90. TX_FAR _Route18Text5
  91. db "@"