Page 2 of 2

Re: Zooming on 3D Race Games

PostPosted: Sun Jan 30, 2011 2:42 am
by DST
Well part of the secret is the map itself. It only stores a number - that number is used for the color of the square but also the number of lines to draw.
Thus the track borders with a value of 4 are complete squares, while the 'rest of the world' is 2-line Lshapes that form a grid, to cut back on the total number of lines to transform.

Their actual xy in the transformation is just assigned from their position in the array.


Just thought of another speedup: ditch the array cell draw, and calculate the start and end of all the lines on the grid as huge lines from left to right, and top to bottom. Easy enough. Then simply draw black lines over them for the main track center.

That would result in probably 1/4 the total number of lines.

Re: Zooming on 3D Race Games

PostPosted: Sun Jan 30, 2011 8:42 am
by Bee-Ant
Wow Dee, If I'm not mistaken you made the same thing before...it's Picodrive or something?and this is way better :D
But you can't compare this with GAG's demo...
This uses lines only while GAG's uses images...so of course this demo gets a faster fps ;)

Re: Zooming on 3D Race Games

PostPosted: Sat Aug 06, 2011 12:42 am
by tintran
having been to the forum for a while, just tried DST's Neon Z racing.
I got flickering between 20 to 30 frames.

OS: Linux Fedora release 14
cat /proc/cpuinfo gave me more info than I was looking for
processor: 0 model name: AMD Athlon(tm) 64 X2 Dual Core Processor 3800+ cpu MHz:1000.000 cache size: 512 KB
processor: 1 model name: AMD Athlon(tm) 64 X2 Dual Core Processor 3800+ cpu MHz:1000.000 cache size: 512 KB


Unrelated to the game Neon Z racing: I think it's probably alot faster than 20 to 30 frames, since i ran the .exe (probably got executed by WINE under Fedora), because when I run GE for linux, it is fast and not laggy like when i just run the GE (not for linux) it probably runs under WINE again and i can see it lag when i try to resize the main GE window or move it around. 20-30 fps is still pretty smooth.

Re: Zooming on 3D Race Games

PostPosted: Sun Aug 07, 2011 5:11 am
by tintran
@Game A GoGo, no, i don't mind at all (actually awed that someone would try and understand my code, i have problem understanding my own code after a week or so) :shock:
how did you get that tile.bmp to show as ground? did you pixel by pixel it? and i don't know what mode 7 is. :?:

Re: Zooming on 3D Race Games

PostPosted: Sun Aug 07, 2011 1:30 pm
by Game A Gogo
The ground was pixel duplicated (3 times I think, so 1 pixel is 9 pixel big...) to reduce lag.

Mode 7 was a special drawing mode on the Super Nintendo, it allowed you to stretch.skew and a few stuff. Thus allowing "3D" games to exist on the super Nintendo.

Of course, the Super Nintendo had a chip to process this quickly and a chip specially designed to access the entire image map in a split second, while GE struggles A LOT with data processing.

And about understanding your code... I know what you mean :P

Re: Zooming on 3D Race Games

PostPosted: Tue Oct 25, 2011 3:07 am
by DST
Okay, dunno why i didn't do this before but here's the source if anyone wants to look into it.

All the important 3d stuff is in canvos>draw actor. Toward the bottom you will find the transformations.

It's pretty complicated but if you can understand the transformations then you can do 3d in anything.

NeonZRacingByDST.zip
(507.06 KiB) Downloaded 300 times

Re: Zooming on 3D Race Games

PostPosted: Tue Nov 08, 2011 4:05 pm
by JamesLeonardo32
DST wrote:Okay, dunno why i didn't do this before but here's the source if anyone wants to look into it.

All the important 3d stuff is in canvos>draw actor. Toward the bottom you will find the transformations.

It's pretty complicated but if you can understand the transformations then you can do 3d in anything.


O wow, impressive job again, sir DST.