Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- base = 0xA34C
- maxcount = 0
- enemies = {
- { id = 117509910, name = "Smoker" },
- { id = 117513818, name = "Berserker" },
- { id = 117518154, name = "Thrasher" },
- { id = 117521014, name = "Seeker" },
- { id = 117534562, name = "Boat" },
- { id = 117524248, name = "Shark" }
- }
- while true do
- local count = 0
- for i=24, 218 do
- local addr = base + i * 0x48
- local id = mainmemory.read_s32_le(addr)
- for e = 1, 6 do
- local enemy = enemies[e]
- if id == enemy.id then
- gui.text(
- -40,
- 100 + 16 * (count % 28),
- string.format("%8X: %s", addr, enemy.name)
- )
- count = count + 1
- if count > maxcount then maxcount = count end
- end
- end
- end
- gui.text(0, 50, string.format("count: %d\nmaxcount: %d", count, maxcount))
- emu.frameadvance()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement