SRAM hex edit translations
Zeldix :: Zelda III Hacking :: Workshop
Page 1 of 1
SRAM hex edit translations
When looking at the SRAM editing information, how do you find those addresses in a hex editor?
for example, how do I find $7ef?
for example, how do I find $7ef?
wizzrobemaster- Ganon
- Since : 2015-01-04
Re: SRAM hex edit translations
You can't modify RAM/SRAM with hex editor from the rom, it on a different chip i think, (on emulator it in a file "rom.srm") when you run a rom the code will fill the RAM from the ROM and SRAM if it exist.
zarby89- Since : 2016-10-30
Re: SRAM hex edit translations
By opening the SRM save file in a hex editor and going to 7EF.When looking at the SRAM editing information, how do you find those addresses in a hex editor?
for example, how do I find $7ef?
However like Math On Napkings said in his docs, you can not edit the SRM in a hex editor and expect the changes to work/load, since every SRM has a safety check, the 2 bytes, which corespond to internal CRC. This is a safety for the save validation, which then prevents direct hex editing, unless if you later recalculate these 2 bytes correctly and change them as well.
Note: there is no direct need of knowing how the SRAM works unless you want to actually tackle with Rom to tell it how to save differently, however this is usually left alone.
Puzzledude- Since : 2012-06-20
Re: SRAM hex edit translations
going to 7EF ? the file doesnt start at 7EF already? for example 0x340 in the .SRM file is the bow but yeah it kinda useless to modify that file but it could be useful to make a sram viewer
zarby89- Since : 2016-10-30
Re: SRAM hex edit translations
Well, the sram is part of the ram, with the only difference that it can be stored permanently.
So you need to look into the Rom with an hex editor, best with a Geiger trace log if you want to manipulate something there.
This is only an example and must not be the real Rom code: For example if the beginning sets 7ef3c5 to 00. You should find something like
lda #$00
Sta $7ef3c5
In Geiger trace log. Use breakpoint hook at write 7ef3c5
In the log you also find the byte opcode stuff, it translates t:
a9 00 8f c5 f3 7e.
Find this sequence in the Rom with your editor and change it to
a9 01 8f c5 f3 7e to start in part 1.
So you need to look into the Rom with an hex editor, best with a Geiger trace log if you want to manipulate something there.
This is only an example and must not be the real Rom code: For example if the beginning sets 7ef3c5 to 00. You should find something like
lda #$00
Sta $7ef3c5
In Geiger trace log. Use breakpoint hook at write 7ef3c5
In the log you also find the byte opcode stuff, it translates t:
a9 00 8f c5 f3 7e.
Find this sequence in the Rom with your editor and change it to
a9 01 8f c5 f3 7e to start in part 1.
Conn- Since : 2013-06-30
Re: SRAM hex edit translations
No idea what you mean Zarby. The file starts at 000000. 7EF is in the 2nd saved game.zarby89 wrote:going to 7EF ? the file doesnt start at 7EF already? for example 0x340 in the .SRM file is the bow but yeah it kinda useless to modify that file but it could be useful to make a sram viewer
Thus 7EF
according to MON, is
Slot 1: $000; Mirror: $F00
Slot 2: $500; Mirror: $1400
Slot 3: $A00; Mirror: $1900
Thus 2EF of the second saved game
Again from MON
$280-$2FF Overworld Event Information
Puzzledude- Since : 2012-06-20
Re: SRAM hex edit translations
zarby89 wrote:You can't modify RAM/SRAM with hex editor from the rom, it on a different chip i think, (on emulator it in a file "rom.srm") when you run a rom the code will fill the RAM from the ROM and SRAM if it exist.
Okay so that explains why it is called an srm. I presume the srm file that needs to be edited is the one that appears when first loading the game?
wizzrobemaster- Ganon
- Since : 2015-01-04
Re: SRAM hex edit translations
Puzzledude wrote:
Thus 7EF
according to MON, is
Slot 1: $000; Mirror: $F00
Slot 2: $500; Mirror: $1400
Slot 3: $A00; Mirror: $1900
Thus 2EF of the second saved game
Again from MON
$280-$2FF Overworld Event Information
slot 1: $000
the F00 is the mirror in the ROM if you wanna get or set info in that sram slot you use LDA/STA $7EF000
in the sram file it start at $000 so for the bow which is $7EF340 from ROM become $000340
wizzrobemaster wrote:Okay so that explains why it is called an srm. I presume the srm file that needs to be edited is the one that appears when first loading the game?
it depends what you wanna do but yeah when you create a file it fill the sram data with the new data, everytime you save the game it will save all the ram 7EF000 to 7EF500 into the sram if the slot used is the 1st one
Last edited by zarby89 on Mon 18 Dec 2017 - 18:54; edited 1 time in total
zarby89- Since : 2016-10-30
Re: SRAM hex edit translations
So will I need to download Geiger (which I recall only works with Snes9x) to edit the SRAM?
wizzrobemaster- Ganon
- Since : 2015-01-04
Re: SRAM hex edit translations
i don't know what you are trying to do but you should not have to modify the sram at any point ... it contain nothing else than save data for the player
zarby89- Since : 2016-10-30
Re: SRAM hex edit translations
Not really. Geiger is a tracer. You don't need to edit SRAM at all.wizzrobemaster wrote:So will I need to download Geiger (which I recall only works with Snes9x) to edit the SRAM?
Puzzledude- Since : 2012-06-20
Re: SRAM hex edit translations
zarby89 wrote:i don't know what you are trying to do but you should not have to modify the sram at any point ... it contain nothing else than save data for the player
What about this:
https://www.zeldix.net/t389-start-sram-modifier
wizzrobemaster- Ganon
- Since : 2015-01-04
Re: SRAM hex edit translations
That's different. This is the starting SRAM, thus a number of things which you can edit before you even start. This is the "internal" SRAM and it is located in the Rom itself (and is highly useful for editing). It then goes to "actual" SRM file.What about this:
https://www.zeldix.net/t389-start-sram-modifier
Puzzledude- Since : 2012-06-20
Re: SRAM hex edit translations
you see, ram is mapped from 7e/0000 to 7f/ffff. So when addressing stuff you can decide wheterh you address rom or ram data,
e.g.,
LDA $7ef374 - address ram data
LDA $088423 - address rom data in bank 08
If the game needs sram to continue at later point you can store a part of the ram to sram, this can be addressed in Zelda 3 from 70/0000-70/1fff.
So in Zelda3, ram 7E/f000-7e/f4ff will be stored into sram.
As example, if you look in MoN's sram guide you find the entry:
$000 - $24F : Data for Rooms (two bytes per room)
This means that 7Ef000-7ef24f (room data) is transferred to sram. Other data stored is overworld data, items, progress flags and such.
If you look closely you have $2000 bytes of sram (70/0000-70/1fff), but only $500 bytes get stored (7E/f000-7e/f4ff). But remember that you have 3 slots. The remaining $500 bytes goes as overall infos like how many slots are used.
e.g.,
LDA $7ef374 - address ram data
LDA $088423 - address rom data in bank 08
If the game needs sram to continue at later point you can store a part of the ram to sram, this can be addressed in Zelda 3 from 70/0000-70/1fff.
So in Zelda3, ram 7E/f000-7e/f4ff will be stored into sram.
As example, if you look in MoN's sram guide you find the entry:
$000 - $24F : Data for Rooms (two bytes per room)
This means that 7Ef000-7ef24f (room data) is transferred to sram. Other data stored is overworld data, items, progress flags and such.
If you look closely you have $2000 bytes of sram (70/0000-70/1fff), but only $500 bytes get stored (7E/f000-7e/f4ff). But remember that you have 3 slots. The remaining $500 bytes goes as overall infos like how many slots are used.
Conn- Since : 2013-06-30
Re: SRAM hex edit translations
Is there a Geiger program for NES?
wizzrobemaster- Ganon
- Since : 2015-01-04
Similar topics
» Super Gameboy Translations
» Castlevania IV sram
» Start sram modifier
» Edit the doors? Yes, it is possible :D
» ZScream 3.0.2
» Castlevania IV sram
» Start sram modifier
» Edit the doors? Yes, it is possible :D
» ZScream 3.0.2
Zeldix :: Zelda III Hacking :: Workshop
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum