Romhacking.net

Romhacking => ROM Hacking Discussion => Topic started by: mrhuxo on November 18, 2021, 04:51:44 pm

Title: Modding SMB sprites and adding tiles and coding new game mechanics
Post by: mrhuxo on November 18, 2021, 04:51:44 pm
I'll say first, I don't need any utilities or softwares to access the games sprites. And I already have a software that allows me to tweak the games coding. I just need help though with sprites specifically. I'm planning on making another Rom hack but I need to know how to add more tiles to a sprite, and to code in new mechanics. One of my ideas was though was that I was planning on making Luigi, his own separate character sprite aside from being a recolor of Mario. But how will I be able to do that exactly? Will I need to allocate more kb to the Rom and how will I code Luigi to be a different sprite? Also, I want to know how I can add his high jump from The lost levels as well add in a new power up. There's also the background. Now I know how to change sprites, but I don't know I can alter the background graphics. Any help with that please? This is a pretty big rom hack I'm wanting to do based of the super Mario Bros movie back in the 80's and I have a lot of ideas to make this a good rom
Title: Re: Modding SMB sprites and adding tiles and coding new game mechanics
Post by: FAST6191 on November 19, 2021, 09:30:20 am
"And I already have a software that allows me to tweak the games coding" "but I need to know how to code in new mechanics New mechanics"
?
One kind of implies the other.

New mechanics is also not a fixed concept, and for that matter more tiles to a sprite is also not fixed. New mechanics can be as simple as you doing things it already does; jumping and firing a fireball would presumably only need you to trigger the fireball command it already knows from a jump which is basically already does, might even a single instruction change. Compare that to adding a radical new style of play (maybe you bring the super mushroom powerup from new super mario brothers), and possibly some level tweaks too so as to take advantage of it and that is a different matter entirely.

"Will I need to allocate more kb to the Rom"
Someone might know I guess but it is usually something you get to figure out for you and what you plan to do.

As a hint though, and assuming there is no nice commented disassembly for you to play with (which there is and that changes the best approach by making that the easier path), then when in different states (large, small, fire flower, maybe star, not sure what others exist here in this game offhand) then there is probably a call to display different sprites. Here I would probably make another state and where it normally fetches mario sprites (chances are not all are kept in RAM at all points) it will instead dutifully go off for your location you picked for luigi ones (and same probably palettes).
Title: Re: Modding SMB sprites and adding tiles and coding new game mechanics
Post by: Cyneprepou4uk on November 22, 2021, 09:23:05 am
I think he meant that he has an emulator like FCEUX or Mesen as a software for game editing.



Since original SMB doesn't have any free space worth of mention, you'll need to use a different mapper and expand the ROM for most of your hacks.

You need to load different tiles into PPU for Luigi, create another sprite data table and read it instead.

Higher jump can be achieved by setting a different gravity value into RAM.

You can alter background graphics by editing tiles.

A new powerup is probably the most difficult task. Basically you need to create a new object index and add it to all necessary tables.

SMB disassembly can be helpful
https://gist.github.com/1wErt3r/4048722
Title: Re: Modding SMB sprites and adding tiles and coding new game mechanics
Post by: NesDraug on November 22, 2021, 03:00:53 pm
This is a pretty big rom hack I'm wanting to do based of the super Mario Bros movie back in the 80's and I have a lot of ideas to make this a good rom

Do you mean 90s?
I'm just wondering if you've seen this post. Perhaps you can find someone who likes your idea (or already started working on a hack like that).

https://www.romhacking.net/forum/index.php?topic=31449.0