comprehensive SMB1 disassembly

Discuss technical or other issues relating to programming the Nintendo Entertainment System, Famicom, or compatible systems.

Moderator: Moderators

User avatar
Hamtaro126
Posts: 783
Joined: Thu Jan 19, 2006 5:08 pm

Re: comprehensive SMB1 disassembly

Post by Hamtaro126 »

One thing that might be interesting to do is to still try to make SMB use 1-screen mirror for scrolling left-right for future expansion, Even though the code cannot let me do that due to it being a bit of terrible code!

This way, You can usually port to systems that have scrolling but only have capability of 1-screen mirroring only... like Commodore 64, *Sega Master System, *Game Boy, etc

* I can try to convert code after I figure out how to display only one screen, of which needs a new renderer
AKA SmilyMZX/AtariHacker.
Sik
Posts: 1589
Joined: Thu Aug 12, 2010 3:43 am

Re: comprehensive SMB1 disassembly

Post by Sik »

tepples wrote:
Sik wrote:The other issue is control lag, which again I don't get (implementing lagless controls is easier and simpler, seriously o_O just react as soon as the input comes).
Perhaps it's that the operating system itself isn't designed around low latency. Some touch screens, for example, sample multiple times to ensure more accurate position readings. Keyboard input is often heavily processed based on an assumption, valid most of the time, that the keyboard is used for inputting text in any of several languages, some of them with fairly complex writing systems. And some adapters from classic SPI controllers to USB add latency as well. Furthermore, video and audio latency contribute to the perception of lag; an operating system's media subsystem may be geared toward the CPU-efficient and/or battery-efficient playback of noninteractive music and video more than toward gaming.
The biggest offenders tend to be unlicensed games on consoles though =P
User avatar
mikejmoffitt
Posts: 1352
Joined: Sun May 27, 2012 8:43 pm

Re: comprehensive SMB1 disassembly

Post by mikejmoffitt »

Hamtaro126 wrote:One thing that might be interesting to do is to still try to make SMB use 1-screen mirror for scrolling left-right for future expansion, Even though the code cannot let me do that due to it being a bit of terrible code!

This way, You can usually port to systems that have scrolling but only have capability of 1-screen mirroring only... like Commodore 64, *Sega Master System, *Game Boy, etc

* I can try to convert code after I figure out how to display only one screen, of which needs a new renderer
A proper, non giana-sisters port of SMB to the Commodore 64 would be awesome.
autoreverse
Posts: 7
Joined: Sun Nov 25, 2012 4:40 am

Re: comprehensive SMB1 disassembly

Post by autoreverse »

Hey doppelganger,

Not sure if this has been mentioned already. Line 15317:

Code: Select all

        stx $f1                 ;and stop making the sfx
...could be changed to:

Code: Select all

        stx Square1SoundBuffer                 ;and stop making the sfx
User avatar
oRBIT2002
Posts: 643
Joined: Sun Mar 19, 2006 3:06 am
Location: Gothenburg/Sweden

Re: comprehensive SMB1 disassembly

Post by oRBIT2002 »

Would be interesting to read some "behind the scenes" information on how this was done?
doppelganger
Posts: 183
Joined: Tue Apr 05, 2005 7:30 pm

Re: comprehensive SMB1 disassembly

Post by doppelganger »

Picture a man in his 30's at his computer, pouring through a disassembly of the program ROM, typing by hand everything in notepad.exe, stepping through the program in certain areas where it was more confusing, and comparing notes with the Super Mario Bros hacking project disassembly that was made further back in order to verify certain known things like the foreground object data format, and you have a pretty accurate picture of the behind-the-scenes stuff. There's not really much more to tell, unless you count a rough sequence of what got reverse-engineered...
Be whatever the situation demands.
User avatar
BMF54123
Posts: 410
Joined: Mon Aug 28, 2006 2:52 am
Contact:

Re: comprehensive SMB1 disassembly

Post by BMF54123 »

I'm really interested in the bits of unused code sprinkled about. Why does the game have a brick counter? Why are broken brick pieces changed into white balls when you touch the flagpole? The world may never know... :\

(though my theory for the latter is that fireworks were originally going to use the brick-breaking routine, just with the brick graphics changed to something more firework-like)
strat
Posts: 396
Joined: Mon Apr 07, 2008 6:08 pm
Location: Missouri

Re: comprehensive SMB1 disassembly

Post by strat »

I'll take a wild guess that you first looked at the vram writes and went backwards to find the area parser stuff.
Post Reply