Saturday 6 September 2014

Space Invader analysis

At our first lecture in analysis and design we talked about what a game is and what we’re going to do during the course. We’re most obviously going to analyze. We’re going to learn how to deconstruct games to its core systems. See how the game works in its simplest definition, where it’s just components reacting with each other. Simply see through the flashy graphics and see the mechanism.

A way to do that is to break the game into pieces, objects. Your character is an object. The object has different properties that make it differ from your enemy. And they have behaviors, and relationships on how to react with each other and make something happen. Our first assignment was to analyze an old classic, namely space invaders with this method. It’s a very simple game, to the eye. But what lies beyond can be pretty tricky.



Let’s start with the objects. The objects are everything, together they create the game. At the most basic we have the player controlled craft, the enemies and the shields. But rather we have shield parts, since the shield is made out of squares that one each gets destroyed while hit. The whole shield doesn’t disappear, hence each part is a separate object but with the same properties and behavior. The bullets, or lasers is also objects. But the score and lives is also objects. Even the screen is an object. The objects is part of the whole jigsaw puzzle that creates the whole picture, the game.

Next up is the properties. The properties is what defines the objects, makes it what it is. Without location it couldn’t be there, without visual graphics it couldn’t be seen, without speed it wouldn’t be able to move. There is other properties as health, or also called hit points. Sound, hit box, and the ability to spawn a bullet. The enemy will have similar properties, but it’s an NPC, and the other is player controlled. Yet the shield narrows down to location, graphics and hit box. It can’t move, or spawn bullets like the other two. Score only has graphics and location.

But behaviors then. Behaviors is whatever the object is able to perform. There is very simple behaviors in this game. For player craft it’s simply movement and attack. When you have all this you’ll get something looking like a game very much, but there won’t be much fun. You’re bullets won’t be able to destroy something without relationships. What happens when a bullet hits an enemy? The enemy takes damage and is destroyed. That is a relationship between the bullet and the enemy. When a shield part is hit by a bullet it gets destroyed. If a bullet collides with an enemy laser it neutralizes. Player craft has the relationship of spawning with bullets.


It’s here when things can get confusing. Is it really a property of the player craft to spawn bullets, or is it a relationship? Or both? Does shield parts have no behavior, as being destroyed when hit is a relationship? There is a lot to be discussed on this subject. And still it’s not all of it. For every relationship there is a system. A system made out of an input, process and an output, hence a feedback for the player. And one system triggers another one. There is a collision system that triggers the damage system, which in turn triggers the score system and so forth. I’m not going into depth about systems this time since the plan was to keep this short. It has been a very interesting assignment, and even thinking about breaking down more complex games like this is truly intriguing.

No comments:

Post a Comment