Page 1 of 3
NES programming
Posted: Wed Apr 25, 2007 7:17 am
by evildragon
Well, I'm sorta known on the net for being the first to give the NES an optical drive, a DVD-ROM drive exactly.. (video overlay, to play movies, and using simple API to control the drives ESS Video Drive decoder onboard..)
I was going to port Sonic 2 onto the NES, and make it as authentic as possible, and so far my planning is going good.. (even with the limited sound and graphics)..
BUT, I have NO idea how the heck im going to do the special stage! How do I even begin to simulate 3D like that on the NES? Remember, it needs to be authentic as possible..
Posted: Wed Apr 25, 2007 7:30 am
by TmEE co.(TM)
Maybe set up pattern table and do bank switches on CROM ? Can we see your work somewhere ?
Posted: Wed Apr 25, 2007 3:05 pm
by evildragon
TmEE co.(TM) wrote:Maybe set up pattern table and do bank switches on CROM ? Can we see your work somewhere ?
i haven't had a website created showcasing my stuff........yet.. one of my friends have offered to do it for me, i just have to get off my lazy butt and compile pictures and information..
Re: NES programming
Posted: Wed Apr 25, 2007 5:33 pm
by Shiru
evildragon wrote:How do I even begin to simulate 3D like that on the NES?
If you skilled enough to make NES game, you must easily see what there is no any 3D in special stage of Sonic 2, it's just animation with low framerate. And it's not hard to implement on NES, of course.
Re: NES programming
Posted: Wed Apr 25, 2007 6:25 pm
by evildragon
Shiru wrote:evildragon wrote:How do I even begin to simulate 3D like that on the NES?
If you skilled enough to make NES game, you must easily see what there is no any 3D in special stage of Sonic 2, it's just animation with low framerate. And it's not hard to implement on NES, of course.
yea, i know it's just animated stuff, but the problem i am seeing, is, is the NES even fast enough to switch graphics like that? don't forget when the rings come closer, they get bigger too...
i've never been able to get the NES to transfer fast enough to do something close like that..
Posted: Wed Apr 25, 2007 6:40 pm
by Shiru
You must use simple compression for background, and update only tiles which changes from previous frame. If your animation will be looks like SMD special stage (many flat-shaded areas), you'll be able to update screen fast enough. In best case you'll even not need to update tileset, only nametable.
About rings, it's not sprite scaling, just sprites with same size, but with different size of rings inside sprite. And they move by precalculated trajectories (X,Y,sprite number), depending from current part of background animation.
Posted: Wed Apr 25, 2007 6:44 pm
by evildragon
yea, i knew that about the rings, as the genesis didn't have scaling and rotation.. what i meant was i didn't know if the NES could load the multiple ring sprites quick enough..
i'm going to have to see how much CPU usage i even have to work with.. i might have to drop Tails from the game...
i already know how im gonna alocate the NES sound channels:
Square 1: Music
Square 2: Sound Effects
Noise: Sound Effects
Triangle: Sound Effects / Music
(The Triangle sound is undecided.. im debating between sound effects or music for it.. for music it could add some bass..
Posted: Wed Apr 25, 2007 7:13 pm
by Shiru
evildragon wrote:i already know how im gonna alocate the NES sound channels:
Most of games uses all channels for music, and take one of it when sfx need to play. But seems you have your very own way with 1-ch music;)
Posted: Wed Apr 25, 2007 7:18 pm
by evildragon
yea, well, in real life, i can only play one note at a time, even on a guitar..

part of my autism, i can't handle producing more than one note at a single time... and my programming will show it...
since the product was already started, game engine concerned, here's some screens.. notice the horrible colors in EHZ, it sucks badly.. the greens are more like "neon"--ish colored..
http://blackevilweredragon.spymac.com/sonicNES1.jpg
http://blackevilweredragon.spymac.com/sonicNES2.jpg
Posted: Thu Apr 26, 2007 6:25 am
by Stef
Do you mean these are real NES screenshots ???
To be honest i'm very septic since in severals parts the image seems to overpast the 4 colors tile limitation (specially the sonic sprite) and even with sprite overdraw it would be quite difficult to achieve a so good result.
So far if you're really getting this result on NES, i'm *very* impressed, probably one of the best looking NES game i've ever seen !
Edit :
After taking better attention, it just cannot be NES screenshot.
Futhermore you're strangly got the same 'bottom line bug' than genesis version.
Posted: Thu Apr 26, 2007 6:39 am
by evildragon
Stef wrote:
Do you mean these are real NES screenshots ???
To be honest i'm very septic since in severals parts the image seems to overpast the 4 colors tile limitation (specially the sonic sprite) and even with sprite overdraw it would be quite difficult to achieve a so good result.
So far if you're really getting this result on NES, i'm *very* impressed, probably one of the best looking NES game i've ever seen !
Edit :
After taking better attention, it just cannot be exactly at it is on a real NES.
Futhermore you're strangly got the same 'bottom line bug' than genesis version.
yea, those are real shots.. crappy RF is all I had at the time to take them... (i couldn't find my composite cables)...
it has the same bottom line bug as I directly ported the main code from the Genesis version (minus some code that really took down the 6502)... I couldn't find what causes it, and why it's only on emerald hill zone...
the color limitation i did take into consideration.. how i got around it really takes penalty on the NES, but my optical drives on-board memory comes in for this.. There's multiple tiles each with their own palette.. Not very easy to pull off, and really causes Sonics animation to be very poor.. I'll try and record a video tomorrow if i can... (however. most of the color boosting is strictly dithering, and the extra colors come from NTSC's "flaws"

you can see a slight colored band on sonics hand, from the dithering, it's like a greenish color)
(PS: I can't find any code in Sonic 2 to actually use all 240 lines on the NES. It seems Sonic 2 was made 224 line only, even on PAL..)
Posted: Thu Apr 26, 2007 6:47 am
by evildragon
here's a comparision.. you can see there was pallette loss, AND detail loss.. The gras lost the "sparkle", the colors got pretty "dull", and the sky, well, that hole layer is non-existant... (there's no way i can get the NES to do that, as far as I see)...
http://blackevilweredragon.spymac.com/soniccomp.png
Oh, and on the NES version, Sonic hangs to the right, because as the Genesis version was coded for 320 pixels width, i was lazy to correct Sonics placement on-screen.. I rushed the engine...
Posted: Thu Apr 26, 2007 7:35 am
by TmEE co.(TM)
Its VERY awesome despite the loss in colors !!! I've played ~500 NES/FC games on real(pirate) HW and your Sonic2 version kicks most of their @$$ !!!
How easy is to program for NES compared with MD ? I'd like to take a shot on it too someday...
Posted: Thu Apr 26, 2007 4:21 pm
by evildragon
TmEE co.(TM) wrote:Its VERY awesome despite the loss in colors !!! I've played ~500 NES/FC games on real(pirate) HW and your Sonic2 version kicks most of their @$$ !!!
How easy is to program for NES compared with MD ? I'd like to take a shot on it too someday...
it's a little harder to program.. the main dificulty, is the lacking of scrolling diagonaly.. you have to work around that, like how Mario 3 did...
Posted: Thu Apr 26, 2007 4:31 pm
by Shiru
evildragon wrote:
it's a little harder to program.. the main dificulty, is the lacking of scrolling diagonaly.. you have to work around that, like how Mario 3 did...
It's nothing that many games uses 'lacking' diagonal scroll?;)