Advertisement
MrCheeze

N64 ram editor setup notes

Jul 3rd, 2021
690
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.74 KB | None | 0 0
  1. NTSC 1.2
  2.  
  3. first full SRM:
  4. create file 1 with filename 800FC550 80300F20
  5. lightnode SRM using file 1 filename (angle ACA0 to use the filename at 8011ACA4)
  6. write 80300F20 to 800FC558 (file 2 backup offset and file 3 backup offset)
  7. this makes it so that when you make a file 3, it will be pasted into file 1 ram at 8011BBA4, which is event flags
  8.  
  9. second full SRM:
  10. create file 3 with filename 8011BBA0 8000A460
  11. lighhtnode SRM using event flags (angle BBA0 to use the filename at 8011BBA4)
  12. write 8011BBA0 to 8000A464
  13.  
  14. third full SRM:
  15. create file 3 with filename 80213F08 8000A260
  16. lighhtnode SRM using event flags (angle BBA0 to use the filename at 8011BBA4)
  17. write 80213F08 to 8000A264
  18.  
  19. combined effect of SRM 2 and 3 will be that 8011BBA0 will be written to 80213F08 every frame,
  20. so that one of the fairies that loads in initial kokiri scene load will trigger a lightnode SRM whenever its room unloads
  21.  
  22.  
  23.  
  24. first deathloop lightnode:
  25. create file 3 with filename 8001DF00 800F0314
  26. write 8001DF00 to 800F0318
  27. (make some function pointer that takes globalctx point to a nop in bank 8001)
  28.  
  29. second deathloop lightnode:
  30. create file 3 with filename 801DB684 800F0264
  31. setup angle EBFC or EC00 and grab a rock
  32. write 800F0264 to 801DB68C (held actor)
  33. and in turn, walking with this held actor will write EBFC/EC00 to the lower half of 800F0318, making the event editor always open when a demo isn't running.
  34.  
  35. (note: the wii can probably use this route if we add a few more deathloops to enable d-pad at this point. but the exact details are not known.)
  36.  
  37.  
  38. now, the event editor is open and we can freely control the event flags using inf_table[22,23,24,25].
  39. and every time we walk out of and back into a kokiri house, a lightnode ramwrite will happen.
  40. this can be bootstrapped quickly into making the event editor itself control ram.
  41.  
  42.  
  43. first event editor lightnode:
  44. enter bits in inf_table[22-25] for 801DB684 800E8788
  45. grab rock and setup angle 87C2
  46. write 800E8788 to 801DB68C (held actor)
  47. this in turn writes 87C2 to the lower half of 800E87B8 (event_chk_inf[19] write address)
  48.  
  49. first event editor lightnode:
  50. enter bits in inf_table[22-25] for 800E87B8 800E87B8
  51. write 800E87B8 to 800E87C0 (event_chk_inf[20] write address)
  52.  
  53. now, event_chk_inf[20] points to the upper half of the event_chk_inf[19] write address.
  54. use event_chk_inf[20] to modify event_chk_inf[19] to point to 800E87C2 (lower half of event_chk_inf[20] write address)
  55. use event_chk_inf[19] to modify event_chk_inf[20] to point to 800E87C8 (upper half of event_chk_inf[21] write address)
  56. use event_chk_inf[20] to modify the upper half of event_chk_inf[21] to 800E
  57. use event_chk_inf[19] to modify event_chk_inf[20] to point to 800E87CA (upper half of event_chk_inf[21] write address)
  58. use event_chk_inf[20] to modify event_chk_inf[21] to 800E87C0
  59.  
  60.  
  61. now FINALLY we are done setting up the ram editor!
  62. event_chk_inf[19] points to the LOWER half of where event_chk_inf[20] should write to
  63. event_chk_inf[20] is used to write the actual value
  64. event_chk_inf[21] points to the UPPER half of where event_chk_inf[20] should write to
  65.  
  66. note: a glitchy string will display instead of "event_chk_inf[19]", this is normal. also, don't ever scroll up past it, the game will crash if you do.
  67.  
  68. first thing to use the ram editor for will be to make the game stop writing to 80213F08 every frame (just in case this causes some random crashes later.)
  69. set event_chk_inf[21]=8000, event_chk_inf[19]=A264; and then event_chk_inf[20]=803F. this will make it so the game writes to 803F3F08 every frame instead, which is harmless.
  70.  
  71. there may also be other instabilities accidentally introduced by all the ramwrites we've done. if any crashes happen, we can add in some more cleanup at this stage.
  72.  
  73. now, do whatever you want with ram editor!!!!!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement