Advertisement
Guest User

Untitled

a guest
Nov 10th, 2019
20
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local offX, offY, camX, camY
  2. local addr_offX = 0x5B96
  3. local addr_offY = 0x5B98
  4. local addr_camX = 0x59D0
  5. local addr_camY = 0x59D2
  6.  
  7. while true do
  8.   savestate.saveslot(0)
  9.   offX = mainmemory.read_s16_le(addr_offX)
  10.   offY = mainmemory.read_s16_le(addr_offY)
  11.   camX = mainmemory.read_s16_le(addr_camX)
  12.   camY = mainmemory.read_s16_le(addr_camY)
  13.   mainmemory.write_s16_le(addr_camX, camX + offX - 128)
  14.   mainmemory.write_s16_le(addr_camY, camY + offY - 80)
  15.   emu.frameadvance()
  16.   emu.frameadvance()
  17.   emu.frameadvance()
  18.   savestate.loadslot(0)
  19.   emu.frameadvance()
  20. end
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement