-
-
Save taotao54321/9beb91a9f08edb2ea0075ac77b0f617b to your computer and use it in GitHub Desktop.
NES Dragon Quest (J): log fetching script commands from strange addresses
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--[[ | |
NES Dragon Quest (J) - log fetching script commands from strange addresses | |
--]] | |
local function on_exec() | |
local script_ptr = mainmemory.read_u16_le(0x99) | |
if 0x2008 <= script_ptr and script_ptr <= 0x3FFF then | |
console.log(string.format("fetch script command from $%04X", script_ptr)) | |
end | |
end | |
local function main() | |
event.onmemoryexecute(on_exec, 0xBD29) | |
end | |
main() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment