• Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

About this blog

The game's official development journal.

Entries in this blog

My Game Doesn't Run Without It
The CharWars game engine is divided into two parts: the game world and the game interface.

The Game World
The game world basically acts as a world containing all the entities of the game. It also acts as the bridge for the physics world (Box2D's b2World) and the entities.

Entities are updated through the game world. Once the game world is updated, it only calls the update function of the entities which are on the top of their own hierarchy (has no parent entity). Once the entity is updated, it then calls the update functions of it's child entities. This method is much much better than updating one by one all the entities for a lot of reasons (synchronization, full hierarchy, etc.).

The Game Interface
The game interface handles the rendering and user-control functions of the game. It doesn't render the entities directly but instead the entities only send messages to it (this is also the same for user-control).
Game Concept
It first started after I had read the Star Wars VI comic book I had found on one of our secluded shelves. A feeling came, inspiring me to create a game. In that time, also, my brother had started coding his game. I watched him coding and creating artworks of ship parts (their very nice and intricate). Then I realized that it's pretty hard to make those kind of artworks. I was discouraged. But another thought came to me: Why not create a game that I need not to create images? Yes! Why not...... characters! Text! Chars! And so it begun.
The game's concept is quite simple. The one most important entity of the game is the char(character). It can build bigger entities when many of them are connected. It forms virtually everything in this game: from parts to ships; form particles to explosions. The char is most basic building block of the game that's why the game is called CharWars.

Entities and Hierarchy
The char forms all entities of CharWars. Here is a diagram showing the hierarchy of some of the game's entities:

Char --> Parts (weapons, thrusters, connectors, etc.) --> Controllable Entities (ships, drones, sentries, etc.)
--> Particles --> Explosions | Weapon Particles (beams, "missiles", etc.)
--> Static Bodies

I'm still thinking it over.

The game is written in C++ with SFML as the "official" graphics and sound and everything else API, and Box2D for the physics engine. I also borrowed some pieces of my brothers code.

I will post every development of the game in an interval of a week. I kindly ask for your suggestions. Comments to the developments are freely accepted. Thanks folks!
Sign in to follow this  
  • Advertisement