Points of Required Attention™
Please chime in on a proposed restructuring of the ROM hacking sections.
Views: 88,512,753
Main | FAQ | Uploader | IRC chat | Radio | Memberlist | Active users | Latest posts | Calendar | Stats | Online users | Search 05-02-24 01:54 PM
Guest: Register | Login

Main - Posts by Drakon

Pages: 1 2 3 4

Drakon
Posted on 01-26-14 04:09 AM, in Zelda 3 Hack: Oracle of Secrets Link | Quote | ID: 155535


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 1/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
I registered just to say this totally f#cking rules.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-16-14 05:00 AM, in Zelda - The Legend of Link (v3-12-20) Released Link | Quote | ID: 155688


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 2/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
I concur, this is blow my mind amazing.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-17-14 02:25 PM, in Mega Man X1 Hacking! (rev. 4 of 02-17-14 02:36 PM) Link | Quote | ID: 155703


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 3/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
This looks fantastic. I don't understand what you mean by "some palettes are hard coded". I recently did a castlevania hack using revamp to edit palettes and there was a lot of palette data I had to edit manually because the editor didn't include it for some reason. Do people who make editors just like to only allow you to edit some palette data and not all of it? Or did they just not get around to adding everything?

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-17-14 02:32 PM, in My Super Mario Bros 3 Hack - ROM Saves Player(s) Progress *UPDATED v7 9-17-14* (rev. 2 of 02-17-14 02:36 PM) Link | Quote | ID: 155704


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 4/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
This hack and metroid + saving inspired me so much I recently hacked the japanese release of castlevania 3 to include sram support. Personally I can't wait for every long game with either a password system or no saving system to get a sram hack.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-17-14 02:40 PM, in Mega Man 4 Voyage (Update: Out NOW) (rev. 3 of 02-17-14 02:48 PM) Link | Quote | ID: 155705


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 5/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
This is amazing, the music you wrote is fantastic. This is everything a hack should be. What did you use to compose and insert the music?

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-19-14 01:27 AM, in My Castlevania 3j hack (rev. 32 of 02-19-14 10:20 PM) Link | Quote | ID: 155722


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 6/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days




What this hack features:

Sram saving, no more passwords, it saves everything I felt is important even what loop you're in. I did the lazy version and just replaced the "password" jump with a jump to my loading code and renamed it "continue". I set the cursor to default to continue so you have to press "select" to erase your data making it difficult to erase your game by accident. It saves when you start a new stage, when you enter a new substage (going through one of those mid-stage doors) and right after you die, all automatically.

All stages are played in sequence giving you the full experience. No more choosing routes, now you get to play every stage in the game! Don't have time to do it all in one sitting? Worry not! Because there's sram saving so you can turn it off and come back to it whenever you feel.

I changed most of the game palette data, I wanted to get rid of that whole cartoon feel and give it a more realistic look.

Alucard is now the main character with the freeze attack and mr belmont is the backup character that you start your new game with. Both characters always have fully powered up weapons no more need to pickup weapon upgrades (I had to disable it due to a bug with alucard). Since you play every stage you can pick up any side character you want, yes you can have two alucards if you want. Whenever you pass through a substage door or start a new stage / die, alucard's weapon reverts back to the freeze attack so don't worry if you pick up the clock weapon.

I changed which song is played at which point of the game, this is merely a preference thing.

I changed the title screen from a bunch of japanese kanji into what I think is a nicer set of tiles (see above screenshot). Again, preference.

This indeed runs on real hardware, this playthrough was recorded from an av famicom with a converted madara vrc6 famicom cartridge.

The debugger used to locate ram addresses, locate code I want to change, and check my inserted code was fceux debug build. ReVamp was used for most of the palette changes but still a lot of palette changes I had to do manually. yy-chr was used for the tile changes of the title screen. Winhex was used for ending credit and title screen text changes. All programming changes I just typed myself in hex in notepad and inserted using a hex editor.

Will I release the ips? No, I don't feel like giving out this much work freely. But for anyone who's interested in hacking away at castlevania 3j here's my hacking notes so you can make your own awesome hack! (I want to inspire more people to learn how to do this):

https://www.mediafire.com/?zdik4tf5iw3ng77

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-19-14 02:07 AM, in My Castlevania 3j hack (rev. 4 of 02-19-14 02:15 AM) Link | Quote | ID: 155724


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 7/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted by NARFNra
For images, use [img ] and [/img ] without the spaces. Links are [url ], and I think videos are...

Ah, you need to take the embed code off youtube, I think.

Nice job, by the way!


Thank you sir! All fixed and description added. Thanks for the nice comment too.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-19-14 10:16 PM, in My Castlevania 3j hack (rev. 5 of 02-19-14 10:30 PM) Link | Quote | ID: 155728


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 8/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted by justin3009
The notes themselves work but if you release it on a pay per basis, you will get slapped with a nice big fine. Be wary of what you do when it comes to legality issues like that.


Thanks for a heads up but any on pay basis would be for the ips not the rom.

Posted by Zynk
Of course you can't release the rom itself. But how about a patch? Just saying.

Anyways, I'll respect your withholding your work. I hope the hack notes will prove useful to others romhackers.



Thanks, it's really hard to find communities where people appreciate the work that's shown regardless if they can get it for free or not. The hacking notes are to save future hackers the effort of having to hunt down those ram and other addresses themselves.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-20-14 12:50 AM, in My Castlevania 3j hack (rev. 5 of 02-20-14 01:00 AM) Link | Quote | ID: 155731


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 9/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Oh okay thanks for the clarification. In that case I just won't release it then and I won't accept money for it. I would love to see what interesting hacks are made using my hacking notes.

There's so many people out there selling reproduction cartridges of romhacks, I didn't realize that sort of thing was so unlawful.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-21-14 08:26 PM, in Mega Man 4 Voyage (Update: Out NOW) Link | Quote | ID: 155747


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 10/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Yikes the music is manually edited by hex?! I hope someday someone makes a program that inserts something like a midi into the rom for you.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-23-14 02:06 AM, in Fire 'n Ice, with sram saving (rev. 6 of 02-23-14 02:25 AM) Link | Quote | ID: 155752


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 11/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
I decided to test my new found nes asm skills that I gained from working on other projects. I worked last night and this morning and hacked in fully functional sram saving to the fire 'n ice rom:

For something done in a night and a bit of a morning I'm pretty proud.



I haven't had time to test the full game yet. I'll get around to that when I feel like playing it more.

My goal is to eventually hack sram into all the longer nes games I like that I feel should have it. I'm starting with password system games since I wouldn't have to add a menu option to the title screen I can just hijack the password option.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-23-14 12:46 PM, in Fire 'n Ice, with sram saving (rev. 31 of 02-23-14 01:41 PM) Link | Quote | ID: 155755


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 12/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted by NARFNra
Wow, impressive work. I'm curious, I don't need technical details on a "i could do it myself" level, but what do you really do to add SRAM? Tell the game to save at predetermined points to a location in the SRAM memory, and look it up on startup?


This is a guide on how I did it for this game. How you do it depends on how the game is programmed as well as how you want to handle saving and loading which is completely up to you since you're writing the code.

First I fished through the ram using the fceux ram search option to find the values I wanted to back up when sram saving being sure to write them all down in my notes. Once I found everything I needed to back up I found in the code where the values get updated once you clear a stage by setting breakpoints. Once I found the code that updates the last value I changed that code to a jsr command to free space at the end of the bank (luckily this particular game had good amounts of free space at the end of every bank so I didn't have to do bankswitching like I did with castlevania). Of course the first line of code I execute after the jsr command is whatever code I overwrote with that jsr, so I basically relocate that code to wherever I've jsr'd to (jsr is jump with return capability, like calling a sub-routine).

Now that I'm in an area of rom with lots of free space and I've executed everything that needs executing I can start adding my own code. How I program the saving and loading routines depends on what ram areas I'm backing up. Fire 'n ice was a bit easier to work with since the game has most of the ram I'm backing up in sequential order. Before I back up my ram in my auto-save routine to be sure the original game code doesn't get thrown off I push everything that I'm going to be using for my code into the stack. For this game I used values a and x so the way the nes works is you push a into the stack, transfer x into a, and then push a into the stack again. When you're done executing your code you pull a from the stack, transfer a into x, and then pull a from the stack again and that restores everything to exactly the state it was in before executing my code.

For this game two ram addresses that needed backing up were not in sequential order so after I pushed everything to the stack I just manually loaded each value into a and then stored a into whatever part of sram I felt like saving it into. Saving to s-ram just requires storing data in address range 6000-7fff for a standard 8k sram chip. If you're ever unsure you can just read the nes memory map here:

http://en.wikibooks.org/wiki/NES_Programming/Memory_Map

This link was found on google by typing "nes memory map".

The rest of the ram data I wanted to back up was in sequential order in the regular ram so instead of manually copying each individual piece I could write a loop that copies a certain range. First I set value x to 1. Then I copy from memory range (wherever I want to start copying from), x so it takes that address and adds value x to the end. Meaning if I'm loading from 0200, x and x = 1 it'll load from 0201. If x = 2 it'll load from 0202 etc etc. Then I write a store command in the same format as my load command so I store in address, x. Sram range starts at 6000 but I already used locations 6000 and 6001 so I told it to store at 6001, x. Since x = 1 it starts saving at location 6002. After the load and save commands I increase x by 1. I next do a command that compares x to a certain value, if x != (not equal) that value then it branches back to the beginning of my loop and and keeps copying data and incrementing x by 1 until x reaches whatever value I set. Since x increments by 1 every loop it copies the next piece of data from the ram to the next area in sram until x reaches the number I specified. Meaning the number I specified is the number of times this function loops and increments x which determines how much data in the ram gets copied into sram. Since I could code this in a loop format my added code was relatively small and could easily fit into the free space at the end of the bank with plenty of room to spare.

That took care of auto-saving which in this game I only needed to do after values get updated once you clear a stage. In castlevania I had to call my auto-save function in more than one place because I wanted to update my sram when I started a new stage, when I started a new sub-stage (going through a sub-stage door) and after I died and my number of lives was updated. For a loading routine I literally write the reverse of my auto-saving code. I pasted the disassembled auto-saving code into my notes and just wrote the complete reverse in hex. Again it's important that before and after I execute my added code that I push and pull every value that I'm changing so the normal game code doesn't get thrown off. Once my loading routine was written I needed to stick it somewhere in the rom and call it somehow. I reverse engineered how the game main menu selection determines where to jump to through trial and error breakpoint work. I changed the code so when you select the "continue" option instead of jumping to the password screen it jumps me to yet another block of free space at the end of the rom back. Then I just insert my sram loading code to wherever I jump. I also looked up where the game jumps to when you select "new game" and traced to the rom area after it resets all the values. This is important because after executing my sram loading code I need to jump to this area so it starts the game instead of going into the password screen. It's important to jump to the area of code after it resets the ram values for a new game otherwise it would just reset all the data I loaded from sram defeating the purpose.

For a hijack like this I want to menu to default to the "continue" option, this way you have to change your menu selection to start a new game making it harder to erase your saved game by accident. First I found the ram data that determines where the menu cursor is. I changed the routine that sets the cursor to set it to the second slot. Unfortunately the game draws the menu cursor before reading what slot it's in so I needed to add an extra jump to the cursor drawing routine after the menu loads so it would draw the cursor in my relocated location. After getting that working I just used winhex to change the menu text to whatever I want it to say.

The last bit (very important otherwise it won't run on hardware or a flash cart) of this is changing the settings. I changed the ines header in nestopia for the game to have prg sram saving enabled with a 8k chip. Fire 'n ice uses the mmc3 mapper so I read the mmc3 mapper document here:

http://wiki.nesdev.com/w/index.php/MMC3

This document tells you what value to write to what memory range to set the mmc3 to enable sram saving. As a lazy time saver I just checked the value that was written to this address in the mario 3 sram hack by infidelity because mario 3 is also a mmc3 game. I changed fire 'n ice to write the mario 3 sram hack value to this address and bam, sram saving was up and running.

For a list of nes hex codes and what they do I just used this:

http://en.wikibooks.org/wiki/6502_Assembly

Not exactly some super obscure document, I found it on google by typing "nes asm". To figure out how these work I just looked at how the retail roms used this code in the fceux debug disassembly and figured out what the commands do and how to use them by looking at the disassembled code of the retail rom.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-23-14 01:21 PM, in Fire 'n Ice, with sram saving (rev. 4 of 02-23-14 01:24 PM) Link | Quote | ID: 155757


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 13/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
In reply to retrorain instead of updating the sram constantly I just update the sram at certain points, no need to constantly save progress. I didn't load my data on booting, I just hacked the main menu so I could load when a certain menu option is selected (usually a replaced password option since I'm no longer using passwords I can hijack this).

Before doing this stuff I contacted snarfblam and asked him for his suggestion on the easiest way to add sram. He was the one who suggested that I just have one save bank and hijack the main menu password option to be a load option.

Of course how you handle saving and loading is completely up to you, you're writing the code so you can do it however you like.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-23-14 01:28 PM, in Fire 'n Ice, with sram saving (rev. 6 of 02-23-14 04:00 PM) Link | Quote | ID: 155759


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 14/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted by RetroRain
It depends on what you're saving I suppose. I would imagine a game like Super Mario Bros. 3, if you only made it so that the game saves RAM on the map screen, anything you get in the level before you turn the power off would not be saved. But if you had the RAM constantly being checked and saved, you could save things you obtain in a level before turning the power off. I guess it depends on what you are going for. But yeah, I would agree that saving constantly, for the most part, would be too much. But I don't think there is any harm in doing it.

I might be doing a SRAM hack of my own now, thanks to you! Seriously, nice work man!


Thanks! I really want to thank snarfblam and infidelity for doing some of the first sram hacks to games that seriously needed it and giving me the idea that this can be done.

How often you save is completely a preference. I prefer my data being backed up when I die or finish a stage, but that's me. I like having the option of resetting the console and going back a little. Heck if you wanted to you could reprogram the game to just update the data you want backed up into the sram address instead of normal ram, no need to make a save and load routine. However then you'd have no control over when the data gets saved or loaded.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-23-14 06:05 PM, in Fire 'n Ice, with sram saving (rev. 6 of 02-23-14 06:11 PM) Link | Quote | ID: 155763


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 15/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted by Chaobomr
Wouldn't constantly saving be detrimental to the hardware? Such as, if you were using one of those blank carts, wouldn't constant saving wear out the battery? And if it's anything like newer consoles, wouldn't the constant saving corrupt information if you turned it off while the saving was taking place?


Nothing would be worn out. I'm fairly certain that when the cartridge is being fed power from the system the battery isn't being drained. It's only when the system is off that the battery keeps the sram chip going. I've been to arcades where they had arcade boards from the 90s with suicide battery systems still running with the original battery because they left the machines on all the time so the batteries were never being drained.

Constant saving won't be "corrupted" if you turn it off when the ram is being updated whatever was written should load fine. This isn't like modern hardware it's a completely different beast, low level, low power consumption and small amounts of info and ultra fast access speeds. All the programming is does in assembly because anything else would be too inefficient and too much of a a space hog. Older cartridge based hardware is basically indestructible compared to today's hardware and it's impossible to corrupt a read only maskrom / eprom / flash chip or these older ram chips. The only thing that could go wrong is if you programmed something wrong which is easy to do if you don't know how to properly push and pull with the stack or how to bankswitch properly.

I find technical documents for assembly programming for these older systems aren't beginner friendly at all I learned what I learned by asking around and doing a lot of reading.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-25-14 12:50 AM, in Fire 'n Ice, with sram saving (rev. 2 of 02-25-14 12:50 AM) Link | Quote | ID: 155773


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 16/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Just cleared the game, works fine start to finish with sram saving. I really don't find nes programming a "pain", just the documentation about it isn't very clear for beginners.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-25-14 01:18 PM, in Mega Man 4 Voyage (Update: Out NOW) Link | Quote | ID: 155775


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 17/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Perhaps an editor like ntrq that can be used to compose music? Just need something to help speed the process up.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-26-14 12:36 AM, in NES games with sram saving and other changes (rev. 8 of 02-28-14 01:24 PM) Link | Quote | ID: 155780


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 18/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted in order of completion from most recent to oldest. The other hacks I did on top of adding sram saving are preference hacks I did because I find the games more fun with these new features.

TMNT 2: the arcade game, sram saving and added the ability to change my weapon mid-stage (for fun)



Mario 2 with fully working sram saving is done:



Thanks data crystal for saving me the effort of hunting down all the ram values:

http://datacrystal.romhacking.net/wiki/Super_Mario_Bros._2:RAM_map

I just edited the game further to give princess the pick up speed of toad:



Fire 'n Ice nes with sram saving:



Castlevania 3j with sram saving, music track changes, palette changes, hacked to play every stage in the game + other hacks



____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-26-14 01:27 AM, in NES games with sram saving and other changes (rev. 2 of 02-26-14 01:59 AM) Link | Quote | ID: 155782


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 19/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted by shanem
So...where's the IPS patch?


Safe on my computer where it should be.

I'll be play testing this myself but I highly doubt I'll find any bugs.

____________________
http://16bitgamer.forumotion.ca/

Drakon
Posted on 02-26-14 04:14 AM, in NES games with sram saving and other changes (rev. 4 of 02-26-14 04:19 AM) Link | Quote | ID: 155785


Red Paragoomba
Compromised account. Please contact staff for a password reset.
Level: 18

Posts: 20/62
EXP: 29892
Next: 5

Since: 01-26-14
From: Toronto Canada

Last post: 3710 days
Last view: 3393 days
Posted by shanem
I'm new to this board. I don't know how you personally do things. Will there eventually be a release on here when you are satisfied with it?


No problem. I probably won't release it.

Posted by NARFNra
Posted by Drakon
Sorry for all the threads this forum won't let me edit titles to add more games into the existing threads. Anyway, mario 2 with fully working sram saving is done:


There isn't a little "Thread options" line under the title?

Anyway, good job. You guys pump these out pretty fast :o


Thanks, I'm fairly new here this board isn't beginner friendly.

Added a new ability to this hack, princess now picks things up at the same speed as toad. Video of the new ability in the first post.

____________________
http://16bitgamer.forumotion.ca/
Pages: 1 2 3 4


Main - Posts by Drakon

Acmlmboard 2.1+4δ (2023-01-15)
© 2005-2023 Acmlm, blackhole89, Xkeeper et al.

Page rendered in 0.236 seconds. (336KB of memory used)
MySQL - queries: 133, rows: 165/165, time: 0.224 seconds.