Advertisement
Guest User

Untitled

a guest
Nov 6th, 2011
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.38 KB | None | 0 0
  1. rngcalls = 0;
  2. _a = 0;
  3.  
  4. function RNG()
  5. _a = _a + 1;
  6. if (_a == 3) then
  7.     print(string.format("0x%02X, ", memory.readbyte(0x001E)));
  8.     print(string.format("0x%02X, ", memory.readbyte(0x001F)));
  9.     _a = 0;
  10.     rngcalls = rngcalls + 1;
  11.     end;
  12.  
  13. end;
  14.  
  15. while (true) do
  16.   memory.register(0x001F, RNG);
  17.   gui.text(10,10, string.format("RNG CALLS: %2d", rngcalls));
  18.   FCEU.frameadvance();
  19. end;
  20.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement