Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

The terminology "game state" is a bit vague to me. Could anybody clarify, what is included in the game state, please?

Is it a state of all the variables and objects within the game at particular moment?

share|improve this question
add comment

2 Answers

up vote 17 down vote accepted

An Introduction: Just what in the world is state?

Game state can be used to mean a variety of things and you'll find it used in many different ways in the game industry. In this case I'm using "game state" to provide a description of an object at a given point in time in a game. Clear as mud to you now? Don't worry, I'll try to describe it in a different way, one as a geek like me you might identify with a little better.

Comic books. When buying used comic books, they often say what "state" or condition the comic book is in. The current state of the comic book gives you some indication of how the comic book is going to look when you purchase it. Mint, Fine and Poor all give an image in your mind of just how battered or worn the comic book is.

The same is true for objects in your game. By defining the various valid states for your objects, your game will know just what to do when it is in that state. And just like the comic book industry has defined the various valid states for comic books, you as the governing board for your game must define valid states for your objects and just exactly how the game should respond when those objects are in any given state.

Since this Game State introduction has a very nice way to explain it, i quoted it and you can find the complete article at http://www.xnadevelopment.com/tutorials/thestateofthings/thestateofthings.shtml

share|improve this answer
1  
Thank you for this deailed and easy to understand explanation. To summarize, if I want to save a game play, I will simply gather the game state (states of all the relevant objects) and save them one by one. –  Bunkai.Satori Sep 21 '10 at 14:43
1  
Have a look at the following question for more alternative definitions: gamedev.stackexchange.com/questions/2423/… –  DrDeth Sep 21 '10 at 22:19
add comment

I was recently looking this subject up myself. This link gives great advice to implement a simple game stack/ state. http://gamedev.tutsplus.com/articles/game-design-articles/how-to-build-a-jrpg-a-primer-for-game-developers/#state

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.