Class GameState

java.lang.Object
  extended by GameState

public class GameState
extends java.lang.Object

Keeps track of the state of the game Generates random topics from a file


Field Summary
static int IN_GAME
           
static java.lang.String TOPIC_FILE_NAME
           
static int WAITING_FOR_PLAYERS
           
 
Constructor Summary
GameState()
          Constructs a GameState
 
Method Summary
 void endGame()
          Ends the game
 int getGameMode()
          Gets the current game mode
 java.lang.String getTopic()
          Gets a random topic and stores that for when the game starts
static void main(java.lang.String[] args)
           
 void startGame()
          Starts the game
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

WAITING_FOR_PLAYERS

public static final int WAITING_FOR_PLAYERS
See Also:
Constant Field Values

IN_GAME

public static final int IN_GAME
See Also:
Constant Field Values

TOPIC_FILE_NAME

public static final java.lang.String TOPIC_FILE_NAME
See Also:
Constant Field Values
Constructor Detail

GameState

public GameState()
Constructs a GameState

Method Detail

getTopic

public java.lang.String getTopic()
Gets a random topic and stores that for when the game starts

Returns:
a random topic

getGameMode

public int getGameMode()
Gets the current game mode

Returns:
The game mode

startGame

public void startGame()
Starts the game


endGame

public void endGame()
Ends the game


main

public static void main(java.lang.String[] args)