I think it’s time to post something new here, since with my current job I’m running the risk of leaving this place alone. :D
Just joking! But unfortunately there’s nothing really new about Beach Marbles Racing. Despite having a free weekend last week, I had some personal problems with some people I know, and I ended up to spend seven (bad) days away from my house, my Mac and my iPod. Productivity = zero! Yay! If you remember I also tweeted about the idea of making a short game during the free weekend, but I didn’t do it for the same reasons as above.
Anyways I am always ready to bring my ideas to life with Unity, and so here you are some cool things I come up with in random night time hours!
- Tech demo: Duel Of Speed 3D
Do you remember that Duel Of Speed tech demo (made in fake 3D) I posted some time ago? I wanted to evolve it in real 3D, and after a bit of trial and error about sticking a spaceship on a rollercoaster track (bastard quaternions everywhere!), I managed to pack a working demo. Obviously the driving model has to be improved a lot, but hey, it runs fine and fast for now (and 60 FPS also on iOS)!
Try it here! Control the ship with arrow keys. Duel Of Speed 3D Demo
- Fake Mode7 Demo
Cubes, cubes, cubes! Since I’m never satisfied with fake 3D stuff, I tought it would be cool not only to do a 2.5D tech demo, but also to do a fake Mode7 demo, consisting of many sprite images wich, through the use of many frames, mimicks viewing objects at different angulations, exactly like the old F-Zero and Mario Kart vehicles on SNES and GBA (take a look here, chapter 21.6.x. Warning! Lots of math!).
Note: I call it Mode7 only for its graphical resemblance. Technically it’s different!
Let’s be a little technical here. :)
The cubes you see in the screenshot are not 2D planes with a texture, nor 3D objects: they are real sprite billboards, printed directly on the screen, scaled and depth-sorted.
A “billboard” is an object that will always face the camera, no matter the angle. In videogames they are used a lot for plants, trees, explosions, particle effects, and other things like these, and they are often 2D planes placed in 3D space, not real printed sprites. The big difference between sprite billboards and 2D planes is that the latter always suffer from the classic fish-eye deformation when they are not central on the screen. A sprite billboard, instead, is not even a 3D object, since it’s directly an image printed on the screen at the right coordinates, with the right scale, and with the right depth sorting. Because of this, the final result can sometimes generate weird perspective views.
Another difference is that 2D planes are able to rotate only on several axis (the single Y axis is the most used for plants), while sprite billboards always face perfectly at the camera, no matter what. In the end, 2D billboards are optimal for modern games, while sprite billboards are perfect for retro-style games.
I used this shader as base, then modified it myself to get manual scaling and trasparency in.
I forgot, cubes are rendered in Cinema4D without antialias, and are point-filtered in Unity without Mipmaps to give a more pixelated effect.
So, actually the only real 3D things in this scene are the invisible GameObjects which handle the billboards, but all the rendering is made of sprites. No polygons at all! :)
In this demo there are always more than 127 draw calls at once. The good thing is that it runs 60 FPS in Web Player and ~50 FPS on iPod Touch 4. :D
Here’s the link to look it live (no controls yet): Fake Mode 7 Demo
WARINING: OpenGL-only. Most PCs will not run it, while it’s 100% working on Macs.
That’s all for today. I hope you enjoyed looking at the new tech demos! If you liked them, don’t esitate to ask and comment what you want. :)
See you around in the web!