[ARCHIVE] Simple Questions (SEARCH BEFORE ASKING A QUESTION)
View Single Post
January 27th, 2013 (12:31 PM).
Dark Energy is back in action! ;)
Join Date: Oct 2008
Location: A small country in the North
Originally Posted by
How would you find the ASM routine that the game runs when pressing A while selecting "Pokedex" on the Start Menu? I tried pausing the game in VBA-SDL-H right after pressing A, but I can't find the exact routine, because whenever I put in a breakpoint, it breaks even in other places that have nothing to do with the Pokedex, and that it seems like the game is always running multiple routines or something :/
There are several things you can try but you're currently on a wrong path if I understood right what you're saying here. The processor executes code so fast that if you're trying to press some button on that program to stop executing at certain point, you can never be quick enough.
Anyway, can't you just set a breakpoint to the ram address having the buttons stored in them? There should be some high ram area in GBA where certain universal things like key presses are stored. When you press A, one bit is set in a certain ram address and you can set a breakpoint to that address and follow the code onwards from there.
Another way would be trying to use an asm editor and get hang of the processes being executed before you press A button at that time.
You should be able to find some table defining text strings "Pokedex", "Pokemon", [Player's name]", "Option" and all that stuff. Find the pointer to "Pokedex" for instance and see how it is accessed. Somewhere close to it (either in that routine or some "main routine" calling that subroutine) you should find a routine for making the game wait for the player to press either A button or Up/Down for scrolling up or down in the menu.
My Rom Hack
Learn how to hack GB/C games:
Check my GameBoy/Color hacking videos in Youtube
-The video set uses Pokemon Silver (U) rom for demonstrations
View Public Profile
Send a private message to miksy91
Find all posts by miksy91
Find threads started by miksy91