3.1. Searching for values

This is the easiest way of finding the address that holds a countable quantity, typically lives. Take note of the number of lives (or whatever) you have and interrupt the game, then open the Search window either from the disassembler window or by pressing F4.

Choose 'Word' search and enter the number you noted in the writable field. If you want to enter the number in hexadecimal (as shown in the disassembler window) rather than as a normal (decimal) number, select the 'Hex' option at the bottom. Choose a list to send the search results to (between one and ninety-nine; '1' will do for the first search) and click on 'Search'. When the search operation is finished, the Lists window will open automatically to show the results.

All the addresses listed on the left contain the word value you searched for. You can quickly move the disassembler to an address in the list by clicking Select on the address, and use the List arrows on the assembler button bar to move between the addresses in the list.

If there is only one address in the list, it is likely to be the correct address for the variable you were looking for. If there is more than one, try to narrow down the list (see the next section) to one address.

Most modern games use words to store all their workspace values, but some - and in particular 8-bit games run under emulators - store byte values instead. Each word is comprised of four bytes, but bytes can only hold values up to 255. To search for byte values, use the 'Byte' option rather than 'Word' before clicking on 'Search'.

Note that it is not usually a good idea to search for values like '0', '1' or (in hex) 'FFFFFFFF'. These values tend to occur a lot in a game's memory, so a search for them will take some time and may generate a very long and unwieldy list.


--) Narrowing a search
/\ Finding cheats


ajc@doggysoft.co.uk
23rd April 1998