org.jangband.data
Class Game

java.lang.Object
  extended by org.jangband.data.Game

public class Game
extends java.lang.Object

Character generation actually generates a Game object that contains a world map, player character info and game options. From the users' perspective, they are generating a character, but this is a little slight of hand on the program's part.

A game should only have one main character, even if guest characters are allowed to visit the game in a later version of Jangband.

Game contains game info that doesn't make sense to store in a seperate class, such as a time.

Author:
tdavis

Field Summary
private  TimeOfDay beginningTime
          Beginning time of day.
private  PlayerCharacter character
          Character's stats.
private  WorldMap map
          Wilderness and town information.
private  CharacterPreferences prefs
          Game specific options.
private  long time
          Number of turns taken since the game began.
 
Constructor Summary
Game(WorldMap wm, PlayerCharacter pc, CharacterPreferences cp)
           
 
Method Summary
 TimeOfDay getBeginningTime()
           
 PlayerCharacter getCharacter()
           
 WorldMap getMap()
           
 CharacterPreferences getPrefs()
           
 long getTime()
           
 void setBeginningTime(TimeOfDay beginningTime)
           
 void setCharacter(PlayerCharacter character)
           
 void setMap(WorldMap map)
           
 void setPrefs(CharacterPreferences prefs)
           
 void setTime(long time)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

character

private PlayerCharacter character
Character's stats.


map

private WorldMap map
Wilderness and town information.


prefs

private CharacterPreferences prefs
Game specific options.


time

private long time
Number of turns taken since the game began.


beginningTime

private TimeOfDay beginningTime
Beginning time of day. The time of day that the game began at.

Constructor Detail

Game

public Game(WorldMap wm,
            PlayerCharacter pc,
            CharacterPreferences cp)
Method Detail

getCharacter

public PlayerCharacter getCharacter()
Returns:
the character

setCharacter

public void setCharacter(PlayerCharacter character)
Parameters:
character - the character to set

getMap

public WorldMap getMap()
Returns:
the map

setMap

public void setMap(WorldMap map)
Parameters:
map - the map to set

getPrefs

public CharacterPreferences getPrefs()
Returns:
the prefs

setPrefs

public void setPrefs(CharacterPreferences prefs)
Parameters:
prefs - the prefs to set

getTime

public long getTime()
Returns:
the time

setTime

public void setTime(long time)
Parameters:
time - the time to set

getBeginningTime

public TimeOfDay getBeginningTime()
Returns:
the beginningTime

setBeginningTime

public void setBeginningTime(TimeOfDay beginningTime)
Parameters:
beginningTime - the beginningTime to set




SourceForge.net Logo

Server provided by Gene Davis Software.