Masterjun

Codex generated code | first 3 lines by me, next lines by AI

Aug 17th, 2021 (edited)
193
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.52 KB | None | 0 0
  1. -- This is a Lua script for BizHawk.
  2. -- It displays "cool speed" in green on the screen using gui.text whenever the speed address at $007B is over 48.
  3. -- Otherwise it displays "slow speed :(" in red.
  4.  
  5.  
  6. -- uncomment the line below if you need to set a speed limit
  7. -- client.SetGameExtraPadding(0, 0, 50, 0)
  8.  
  9. local speed_addr = 0x007B
  10.  
  11. while true do
  12.     if memory.readbyte(speed_addr) > 48 then
  13.         gui.text(100, 100, "cool speed", "green")
  14.     else
  15.         gui.text(100, 100, "slow speed :(", "red")
  16.     end
  17.     emu.frameadvance()
  18. end
Add Comment
Please, Sign In to add comment