Zip : http://dl.dropbox.com/u/13388237/Ecliptic.zip
(/src/main.py - edit this file for options)
Video : http://www.youtube.com/watch?v=UZKlhkUWfZY
- arrow keys to move,
- left mouse button to interact,
- right mouse button to create light,
- middle mouse button to check energy levels,
- esc to quit.
: BSD 3.0
: CC BY 3.0 http://creativecommons.org/licenses/by/3.0/
This is kinda a post-mortem article about the game Ecliptic Space we made with MJ-Meo
for the 64digits three months long rpg competition
. We couldn't finish it in time ! Hence the 'game' is far from being finished and polished, there is only few mins of 'gameplay' and I think scales are off !
As for the tools used : Blender, Audacity, Krita, Inkscape, 3d-Coat, Gimp and of course Panda3d !
The purpose of the project was to create a game with rpg elements, from scratch. On my side, I did the graphics and shaders stuff, MJ-Meo was on the programming side and made the main code structure and the music. Ecliptic Space is (originally) an adventure-puzzle game with rpg elements.
First part of the project was to make some concept drawings to give us some ideas about scenario or look of the game; and as it was a comp', I had to make my own font for the game.
I tried to make a seamlessly working pipeline between Blender and Panda3d; moreover I lost the first month on trying to get anisotropic speculars in our game, with Ward lighting model, it was working very well visually, but the fact that I had to splash random colors on textures without having direct visual feedback was annoying, plus the way I made the shader was wrong; I made a texture by code containing all materials information (material index actually), I won't enter into details there, but the problem was only one material could be applied on a full model in practice.
So next to this, I tried to re-implement the Strauss lighting model like I did before, the problem was the same, I have no Strauss shader in Blender to get direct visual feedback on texture painting, and the way you have to use albedo textures with Strauss model wasn't good to me.
So, finally I went back to the classic Blinn-Phong model, so I could have a almost 1:1 result between Blender preview and Panda3d final visual result. Our custom lighting shader was using the same light attenuation equation than Blender with spherical point lights (in conclusion, less is more !).
The pipeline was working this way : in Blender, we could define what objects were collider meshes, sensors, lights or simply 'visual' objects; we were using Blender game tags for this. In Panda3d we go through the exported .egg and check for tags; for each particular tag do some things.
For the rendering, I forgot to mention we are using a deferred shading rendering here, so transparent models were problematics, I simply rendered transparents objects in its own buffer and composited it with main render with a simple z-testing; I think the result is OK, but transparent models are not affected by defererred lights in any way.
We choosed to use deferred lighting system, because one gameplay element of the game was the player could create light with his hand, so we needed 'fast' performances here.
I couldn't have deferred shadows working, again
The hand of the player is fully animated and the player can check his energy and oxygen levels with the help of a screen integrated into the arm. Here a simple uv scrolling is used to display all different energy/oxygen levels combinations.
I don't like fullscreen glow effects, so we had custom shader for glowing objects; models in blender had a fourth texture slot containing the amount of glow (green channel). In Panda3d, the glow buffer was using the albedo texture as the glow color and the green color of the fourth texture was used as the glow power (more green = more glow, less green = less glow).
So actually, in Blender I had to setup 4 textures slots for each model (was really annoying actually
) : diffuse, normal, specular, misc. So we had colored speculars, and as we are in a space ship, there has to be some metallic objects here or there. The main problem was the time it takes to make 4 custom textures for each model, hum.
The AI voice of the ship was made with a text-to-speech software.
Physics and sensors are using Bullet, we use the integrated ray-cast as well to interact with objects.
A human model was made from scratch, for interior ship construction and for the dead bodies the player should find in the abandonned stations.
For the ingame texts, a small class was made to make text images from the font' .png letters as I couldn't make a viable .ttf out of the font. The texts are made before runtime.
The game is locked at 30 fps, or physics go wild, and I think constant framerate is good thing.
: note there is a use of globals in the code (I wanted to try) and there is lot of things hard-coded, so I don't think it's good structure to follow but maybe you can grab a thing or two for your own projects !
About the main inspiration, there is the movie Pandorum and the game Crysis 2 mainly.
Credits for sounds fx :
Loge the 60th
Shaders were created with the help of : Nvidia CG tutorial and D3D10 book from gamedev http://content.gpwiki.org/index.php/D3DBook:Table_of_Contents
: gonna reformat this properly if it's hard to read, plus I notice screenshots are very dark when not fullscren :/
I can post blender files if someone wants to continue this game, just ask for it !