route2gate.asm 718 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. Route2GateScript:
  2. jp EnableAutoTextBoxDrawing
  3. Route2GateTextPointers:
  4. dw Route2GateText1
  5. dw Route2GateText2
  6. Route2GateText1:
  7. TX_ASM
  8. CheckEvent EVENT_GOT_HM05
  9. jr nz, .asm_5d60d
  10. ld a, 10 ; pokemon needed
  11. ld [hOaksAideRequirement], a
  12. ld a, HM_05 ; oak's aide reward
  13. ld [hOaksAideRewardItem], a
  14. ld [wd11e], a
  15. call GetItemName
  16. ld hl, wcd6d
  17. ld de, wOaksAideRewardItemName
  18. ld bc, ITEM_NAME_LENGTH
  19. call CopyData
  20. predef OaksAideScript
  21. ld a, [hOaksAideResult]
  22. cp $1
  23. jr nz, .asm_5d613
  24. SetEvent EVENT_GOT_HM05
  25. .asm_5d60d
  26. ld hl, Route2GateText_5d616
  27. call PrintText
  28. .asm_5d613
  29. jp TextScriptEnd
  30. Route2GateText_5d616:
  31. TX_FAR _Route2GateText_5d616
  32. db "@"
  33. Route2GateText2:
  34. TX_FAR _Route2GateText2
  35. db "@"