Advertisement
Guest User

Journey to Silius Collision box viewer

a guest
Nov 10th, 2013
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.76 KB | None | 0 0
  1. --Journey To Silius Collision Box Viewer
  2. --For FCEUX 2.2.x
  3. --Author Pasky
  4.  
  5. local function draw_axis(x,y)
  6.     gui.line(x,y-4,x,y+4)
  7.     gui.line(x-4,y,x+4,y)
  8. end
  9.  
  10. local function player()
  11.     local life = 0x00B0
  12.     local x = memory.readbyte(0x0506)
  13.     local y = memory.readbyte(0x0507)
  14. end
  15.  
  16. local function Collision()
  17.     local x
  18.     local y
  19.     local xrad
  20.     local yrad
  21.     memory.registerexec(0xE72A,function()
  22.         x = memory.readbyte(0x0016)
  23.         x2 = memory.getregister("A")
  24.         y = memory.readbyte(0x0017)
  25.         y2 = memory.readbyte(0x0002)
  26.         xrad = memory.readbyte(0x0000)
  27.         yrad = memory.readbyte(0x0001)
  28.         draw_axis(x,y)
  29.         draw_axis(x2,y2)
  30.         gui.box(x+xrad,y+yrad,x-xrad,y-yrad,"FF000035","#FF0000FF")
  31.     end)
  32. end
  33.  
  34. while true do
  35.     player()
  36.     Collision()
  37.     emu.frameadvance()
  38. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement