Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- ACTION 52 SKETCH MOUSE
- xset = 0x80
- yset = 0x80
- gui.register( function ()
- xset = 0x80 + input.get(0)["xmouse"]
- yset = 0x74 + input.get(0)["ymouse"]
- if xset < 0x80 then
- xset = 0x80
- elseif xset > 0x80+320 then
- xset = 320+0x80
- elseif yset < 0x70 then
- yset = 0x70
- elseif yset > 0x80+224 then
- yset = 224+0x80
- end
- if input.get(0)["leftclick"] == true then
- joypad.set({C=true})
- elseif input.get(0)["middleclick"] == true then
- joypad.set({B=true})
- end
- memory.writeword(0xFF028A,xset)
- memory.writeword(0xFF028C,yset)
- -- OSC
- xpos = memory.readword(0xFF028A)
- ypos = memory.readword(0xFF028C)
- color = memory.readword(0xFF00BC)
- size = memory.readword(0xFF00C4)
- msg2 = string.format("Pencil: %x %x %x %x", xpos, ypos, color, size)
- gui.text(240,224-10,msg2,"white","black")
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement