Aucune description

hooks.asm 3.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222
  1. //Ipatix sound stuff
  2. .org 0x080007B4
  3. .word 0x0203E000 // new PCM work area
  4. .org 0x081DD0B4
  5. .word main_mixer // new mixer ROM location
  6. .word 0x03005F50 // new mixer RAM location (used for loading)
  7. .halfword mixer_size
  8. .halfword 0x400 // CpuSet, copy code by 32 bit units
  9. .word 0x0203E000 // new PCM work area
  10. .org 0x081DD0C8
  11. // set correct sound driver operation mode
  12. // 12 channels at 26758 Hz samplerate
  13. .byte 0x00, 0xCC, 0x98, 0x00
  14. .org 0x081DC094
  15. .word 0x03005F50+1 // new mixer RAM location (used for branch)
  16. // repoint correctly to the new cry tables
  17. .org 0x080720C8
  18. .include "patches/disable_cry_table_blocks.s"
  19. // cry-ID = poke-ID
  20. .org 0x08043304
  21. LSL R0, R0, #0x10
  22. LSR R0, R0, #0x10
  23. BX LR
  24. // music overrides
  25. .org 0x081DD0F4
  26. LDR R1, =music_override|1
  27. BX R1
  28. .pool
  29. .org 0x0808064C
  30. LDR R1, =trainer_intro_music_id_to_song|1
  31. LDR R2, =0x080806BA|1 // return location
  32. MOV LR, R2
  33. BX R1
  34. .pool
  35. //End of sound stuff
  36. //Don't know what thats all about... leaving it commented for now
  37. //.org 0x0800f268
  38. // .halfword 0xE000
  39. //Battle bg use new table
  40. .org 0x0800F2A0
  41. .word battle_bg_table
  42. .org 0x0800F2E0
  43. .word battle_bg_table
  44. .org 0x0800F320
  45. .word battle_bg_table
  46. .org 0x0800F40E
  47. ldr r0, =battle_bg_hook|1
  48. bx r0
  49. lsl r0, #0
  50. .pool
  51. .org 0x0800FD5C
  52. .word battle_bg_table
  53. .org 0x0800FD88
  54. .word battle_bg_table
  55. //end of battle bg table
  56. //flag routine
  57. .org 0x0806E5D6
  58. ldr r0, =flag_hook|1
  59. bx r0
  60. lsl r0, #0
  61. .pool
  62. //end of flag routine
  63. //var routine
  64. .org 0x0806E45C
  65. ldr r0,=var_hook+1
  66. bx r0
  67. .pool
  68. //end of var routine
  69. //trainer Flag stuff
  70. .org 0x08080382
  71. mov r1, #0x80
  72. lsl r1, #0x15
  73. .org 0x080800BA
  74. mov r2, #0x80
  75. lsl r2, #0x5
  76. .org 0x08080428
  77. mov r1, #0x80
  78. lsl r1, #0x15
  79. .org 0x08080440
  80. mov r1, #0x80
  81. lsl r1, #0x15
  82. .org 0x08080454
  83. mov r1, #0x80
  84. lsl r1, #0x15
  85. //end of trainer flag stuff
  86. //New behavior bytes for jumping
  87. .org 0x0806811A
  88. ldr r0,=jump_behavior|1
  89. bx r0
  90. .pool
  91. //behavior walk stuff
  92. .org 0x0806D720
  93. ldr r0,=on_step|1
  94. bx r0
  95. .pool
  96. //end of new behavior bytes for jumping
  97. //transparent textboxes and mugshots
  98. .org 0x08069410
  99. bx r0
  100. .org 0x0806941C
  101. .word trans_activate|1
  102. .org 0x08069504
  103. bx r1
  104. .org 0x0806950C
  105. .word trans_deactivate|1
  106. .org 0x08150000
  107. ldr r0, =pal_load_hook_2|1
  108. bx r0
  109. .pool
  110. .org 0x0815044A
  111. bx r1
  112. .org 0x08150450
  113. .word pal_load_hook|1
  114. .org 0x0809CEB2
  115. ldr r0, =trans_mug_close_fix+1
  116. bx r0
  117. lsl r0, #0
  118. .pool
  119. //end of transparent textboxes and mugshots
  120. //saveblock routine start
  121. .org 0x080D9EDC
  122. ldr r0, =load_hijack|1
  123. bx r0
  124. .pool
  125. .org 0x080d991E
  126. bx r7
  127. .org 0x080d995C
  128. .word store_hijack|1
  129. .org 0x083FEC94
  130. .include "patches/save_table/save_table.S"
  131. //end of saveblock routine
  132. //new battle script commands
  133. //replace tables
  134. .org 0x08014C1C
  135. .word bs_command_table
  136. .org 0x08015A28
  137. .word bs_command_table
  138. .org 0x08015C6C
  139. .word bs_command_table
  140. .org 0x08015C98
  141. .word bs_command_table
  142. .org 0x0801D054
  143. .word bs_command_table
  144. //end of new battle script commands
  145. //move effect table
  146. .org 0x08016364
  147. .word m_effect_table
  148. .org 0x08023328
  149. .word m_effect_table
  150. .org 0x08025CF8
  151. .word m_effect_table
  152. .org 0x08027464
  153. .word m_effect_table
  154. .org 0x080297F0
  155. .word m_effect_table
  156. .org 0x0802BE80
  157. .word m_effect_table
  158. //end of move effect table
  159. //move limits
  160. .org 0x080D75FC
  161. .byte 0,0,0,0,0,0
  162. //end of move limits
  163. //print string mod
  164. .org 0x080D77C0
  165. bx r1
  166. .org 0x080D77CC
  167. .word custom_print_string|1
  168. //end of print string mod
  169. //new move animation table
  170. .org 0x080725d0
  171. .word m_animation_table
  172. //end of new move animation table