What is Iron Heart?
As mentioned before, Iron Heart is a tank arena game featuring steam-punk tanks that no longer have science fiction influences. The game play is still the same, featuring free-for-all tank battles with AI and friends. Here is a defined feature list for the prototype:
- One tank that players can select from
- One environment players can fight in
- Two weapons per tank, as well a special ability. This can be triggered or passive.
- One game mode (free-for-all).
- First semester: single player. Second semester: multi-player.
The prototype is designed to be simple in scope, but still fun and visually appealing.
Development Strategy
Simplicity is King. This sentence sums the core of the development strategy of Last Life Studios. On the feature life, you may have noticed the word "One" a lot. This is because Last Life Studios believes in making the simplest game possible, that is as fun possible, for the least amount of work possible. The game will be developed in such a fashion that it is easily able to have new content filtered in, if time permits. If the feature list is met, new content and polish will be added. Here is a potential content list, appearing in order of most importance.
- Three new tanks
- New game modes (team battle, horde).
- New pick ups
- New environments
It would be very easy for us as game developers to simply state our game will have all of this, but it is largely unrealistic. Developing a game is difficult and time consuming, but beginning early, developing schedules, and work lists to improve team organization are key success factors. While we are aiming towards a simpler development process to focus on polishing, we also have discussed programming aspects and game engine design.
Programming Strategy
While simplicity is king, organization is the next best thing. Developing Iron Heart will be a difficult task, so we organized the work into major objectives and sub-tasks. Major objectives constitute as major components of the game being complete such as the first tank being fully adapted into the game. This includes all physics, collision, abilities, loading, everything. Sub-tasks would be everything building up to that objective. Here is an example chart.
This allows the programmers, or any person in the group, to select tasks and simply begin to knock them off in an organized and efficient manner.
Using the Engines
After some discussion, we have determined different manners of implementing object-oriented programming and key programming factors of the game.
Rendering and loading:
When looking at the main.cpp of the game code wise, it will look something like this.
int main(int argc, const char* argv)
{
// Load necessary information.
memoryManager.startUp();
textureManager.startUp();
FBXLoader.startUp();
physicsManager.startUp();
//... and so on
// Run the game
game.run();
// Shut everything down in reverse order.
physicsManager.startUp();
FBXLoader.startUp();
textureManager.startUp();
memoryManager.startUp();
return 0;
}
This is because when loading the game, it will require that some classes load first because they may require data from other classes. We shut everything down in reverse order because of the stack theory. First in, first out. While there are more elegant ways of starting up the game, this way works because it is simple to read and understand. Remember, simplicity is King!
For loading objects in the game, we do a mixture of Starcraft II style loading, and simple bulk loading. In the Starcraft II engine, objects are loaded on the fly when they are needed. All sounds, animations, and physics are also loaded on the fly when the object in question does an action. Because Iron Heart will not feature a great deal of unique models and it will be easier to load objects when they are being used. When loading a single object though, load everything relating to it, but only if that tank will be used. It would look something like this, using pseudocode:
void loadLevel(LEVEL_1)
{
loadTankModel(FBXLoader.TANK_1); // Loads tank model and textures.
loadTankSounds(FBXLoader.TANK_1); // Loads tank sounds.
loadTankAnimations(FBXLoader.TANK_1); // Load tank animations
}
The load functions take in an object from the FBX loader class as an argument and load what they need. This way, if we have several tanks, there is no point loading tanks, sounds, animations, sprites, etc, if they will not be used. It helps streamline the game in terms of load times.
To avoid loading in several copies of an object, we can use pointers to a single object to reduce the amount of unique loads done. Players can be simply be given a tank as an argument and will control that. This helps cut down on load times, and is just a good programming practice.
Physics:
As mentioned earlier, Iron Heart will be built using Havok for physics and Ogre3D for rendering. Tanks will have "hard movement". Moving on treads generally means slow acceleration, no wheel rolling effect so stops will be hard, plus other effects like push back from explosions. These are simple implementations to the basic physics taught in first year, but will require a physics manager class that implements Havok into the game.
General Application Efficiency
To create an easy to debug engine, it is best to create manager classes, and any sub classes necessary to those manager classes. The engine used by Naughty Dog has several manager classes like physics, object loading, etc, and utilizes OOP to have classes communicate only if it is necessary. For Iron Heart, it will implement a Game Manager class that will load and construct all classes in the order they need to be, and also deconstruct them in the opposite order. Other manager classes, like physics, object loading, etc will manage their respective domain. By decentralizing the classes, and carefully arranging what includes what, and utilizing OOP principles, it will be easier to debug and keep efficient the code of the game.
For managing memory, fragmentation problems may occur. While this topic will be discussed in further development blogs, it is important to consider now as it can cause huge problems later. Some fixes may include a linked list with a fixed amount of memory, or a stack based system to manage memory, or even dual stack based which was implemented by Midway games. A popular way of dealing with fragmentation is on the fly defragmentation, as implemented by the Naughty Dog engine, where every frame they defrag up to a fixed number of bytes per frame. However, due to the size of the game in question, Iron Heart may not require any complex defragmention solutions, but it is still important to consider.
Summary
While Iron Heart is very early in development, project management and understanding the tools giving is key to creating a polished and fun game. Between understanding the engines given, and balancing all of the other classes, Last Life studios this year will be creating a kick-ass tank arena game. Check back next week for the next installment of the development of Iron Heart.

No comments:
Post a Comment