APOCALYX is a...

free Game Engine based on OpenGL (MAIL) (SITE) (FORUM) (BLOG)

Thursday, October 23, 2008

Refractive Sphere

After a lot of days of silence, let's start again the APOCALYX 3D Engine daily posts. Today just a short old news: I simply signal an old paper of mine that describes how to simulate a refractive (and reflective) perfect sphere with just two triangles.

In DemoPack1 is available a demo (RefractiveSphere.lua) about the subject.

The article dates back to 2004, so it explains how to simulate a sphere through fragment programs. Now the same effect can be accomplished much more easily using fragment shaders and the GLSL language, but the theory behind the scene is still interesting.

Download the paper from here: RefractiveSphere.pdf.

Sunday, October 19, 2008

Third Person Shooter (II)

Other screenshots from Miguel Manchego Rivas' Simple Shooter.

You can download the demo from the Users' Gallery. Feel free to submit your little demos, even if you find the quality of yours worse that Miguel's ones. Thank you in advance!

Saturday, October 18, 2008

Third Person Shooter

Other screenshots from the Miguel Manchego Rivas' demos. This is the time of the Simple Shooter that you can find, as usual, in the Users' Gallery.

As you can see, the features of the demo resemble those of my Urban Tactics. The main important different is that the avatar can jump and walk on ramps, while in Urban Tactics the level is completely flat.
Another difference is the use of level items (items placed in the GtkRadiant Level Editor) to place objects, such as medikits, in the scenery.
Both these improvements were already available in Treasure Hunter, but jumps are much more fluid here.

Monday, October 13, 2008

Treasure Hunter (II)

Other two screenshots from Treasure Hunter. Visit the Users' Gallery for more.


Sunday, October 12, 2008

Treasure Hunter

Just a few screenshots from "Treasure Hunter", a side-scroller demo realized years ago by Miguel Manchego Rivas.

If you have developed games or demos using APOCALYX, feel free to submit them, even if they use very few functionalities. I'll be very happy to host them in the Users' Demos page.
Thank you in advance!


Saturday, October 11, 2008

Unicode fonts

Another quite hidden feature of APOCALYX is the support of UNICODE true type fonts.

You can find a demo showing how to display UNICODE true type fonts in "UnicodeTrueTypeFonts.lua" included in DemoPack2.
As you can see in the screenshot, after a true type font has been loaded in the engine, there are several different ways to use it to display texts. This feature is brought to you thanks to the FTGL and OGLFT libraires included in the engine.

Friday, October 10, 2008

Multiple viewports

Probably this is one of the most hidden features of the engine, but APOCALYX can also support multiple viewports.

There are several kinds of viewports: first of all, the world scene can be seen from different points of view, then also other simplified 3D worlds independent from the main scene can be rendered in their own viewport. To see the feature at work, try the "Viewports.lua" demo in DemoPack1.

Tuesday, October 7, 2008

Post MekaWars: Small RTS

Well, why should we limit the range of possible applications of the programming-game concept to the examples given in the past days? Other possibilities are available, such as the genre of Real-Time-Strategy games.


The paradigm harvest-build-attack is simple enough to be mastered by our intelligent bots, also known as agents. Your possible objection may be based on the number of the units: if one has to assign a virtual CPU to each unit, their computational power must be very limited. In this case, however, I have in mind something different: each player will program the AI of his army as a whole, then the computational time has to be shared among several units. This means that a single thread, the general, will command a number of units and receives feedback from them, leaving some of them, during time consuming activities (harvesting), in a sleeping status. The working unit will awake only for short periods, for example to control the nearby environment for threats. The approach may seem complex, but it's not as difficult as some programming-games are and... no general says that an army is easy to master.

Monday, October 6, 2008

Post MekaWars: SoccerTactyx

As a final example of projects that are going to benefit from the MekaWars development, let's consider the very-long waited Soccer Tactyx (ST). If you have been reading this blog since the beginning, you remember that ST was planned on occasion of the European Football Championship. Now I think that a more realistic release will be on occasion of the... Football World Cup!

Delays apart, also very common in professional games, you must consider that all the code behind MekaWars is also very useful to ST as well. In fact, if you look at the 2D viewer of the recent MekaWars preview (MekaWars.zip), you can easily imagine to substitute the space-fighters with soccer players and the resources with a ball. After this imaginative effort, you can immediately recognize the soccer mode of Gun-Tactyx when seen in 2D mode. The view is more suggestive and realistic in 3D mode, of course, but the viewer is independent from the simulator, once the rules of physics and the soccer players' behaviors are set.
In conclusion, in Soccer Tactyx the units are not fighters and harvesters, but soccer players. The enviromnent is not outer space, but a soccer field. The players will program the AI of their team, and watch them play against teams the AI of which was written by other players.
It's a long way to Soccer Tactyx yet, but the programming behind MekaWars will be useful even in this very different field.

Sunday, October 5, 2008

Post MekaWars: GunTactyx2

You may know that MekaWars, the game currently in a heavy development, is a spin-off of Gun-Tactyx (my CROBOTS-like QUAKE3-style programming-game) and long before of JRobots (my Java CROBOTS-like game with online tournaments). You also may know that I planned long ago a sequel to Gun-Tactyx, that is GUN TACTYX 2.

The occasion to develop MekaWars has delayed the GUN TACTYX 2 development a lot, but all the code behind MekaWars can be applied to GT2 as well. Effectively, if you look at the 2D viewer of the recent MekaWars preview (MekaWars.zip), you can imagine that those dots may represent different kind of objects other than space-fighters and space-harvesters. This means that a lot of code will be easily recycled.
Thus in GUN TACTYX 2 the units are not fighters and harvesters, but soldiers. The enviromnent is not outer space, but indoor or outdoor spaces. The players will program the AI of their team of specialists, each with his own different weapon, and watch them fight against soldiers whose AI was written by other players. Much more complex than MekaWars is, because of the articulated environment, but also worth a try and very beautiful to see.
It's a long way to GUN TACTYX 2 yet, but the programming behind MekaWars will help a lot even in this challenging environment.

Saturday, October 4, 2008

Post MekaWars: City Racing

If you have read the last posts, you know that MekaWars is currently in a heavy development phase. You can also discover the concept behind MekaWars playing with the recent preview (MekaWars.zip).
MekaWars is a game set up in a outer space environment, but the genre of "programming-games" can be obviously applied to worlds subject to other rules. For example, let's consider a few long waited APOCALYX demos starting from City Racing.


In City Racing, the units are not fighters and harvesters, like in MekaWars, but racing cars. The enviromnent is not outer space, but the streets of a town. The players will program the AI of their pilots and watch them race against pilots written by other players. Not as tricky as MekaWars is, but since the pilots' management is simpler and the action more fast paced, the game may result even more involving.
It's a long way to City Racing yet, but the programming behind MekaWars will help a lot even in a so different environment.

Friday, October 3, 2008

Particle System

The particle engine implemented in APOCALYX simulates the movement of textured particles in a frame rate independent way. Each particle moves along a path that is a superposition of two kind of movements: a quadratic path (characterized by an initial position, speed and acceleration) and a circular path (built from a radius and an angular speed). As usual, those parameters are linearly interpolated according to the life of the particle, together with its color, alpha transparency and size.

Fire and smoke

Smoke trail

Dragon's fire

Thursday, October 2, 2008

MekaWars official site (II)

I couldn't resist and show a few screenshots taken from the new MekaWars site that is going to appear at www.MekaWars.com. More detailed instructions, more demos and full featured forums: the real game apart, what could you ask more? Stay tuned!





Wednesday, October 1, 2008

Total War

Just a screenshot