|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--zork2Class.Game
the class Game creation :5 mai 03 at 17:53:31
Constructor Summary | |
Game()
the constructor for game |
Method Summary | |
void |
changeIsLocked()
void Game::changeIsLocked change the ihm status : now we can run an other frame |
void |
executeCommand(java.lang.String com)
method :void executeCommand this method permit to manage the commandWord executeur this method ignore the word case the known commands are : best score : launch the best score frame help : launch the help frame hide all : hide all the dialog frame exit : ask if player realy want to quit and exit if true exit -f : ewit program without asking cheat : enable cheat mode : player name is changed to "tricheur" life : player life number = 6 god : player capacity are all at 100 and player have the ultimate weapon go north : player move to the north, if there is an open door he change room go south : like go north but for south go East : like go north but for east go west : like go north but for west take : if there is an item in the accessible comboBox the player take it drop : drop the inventory selected item an floor open chest : if the player have the chest key, this command open the chest open door : if the player have the door key, this command open the door weapon : the inventory selected is set as current weapon. if the selected item is already the weapon, the player's current weapon is set as null noweapon : player's current weapon is set as null description : launch the item description frame clear : clear the consol kill : remove 10 player's energy points high score : launch the high score frame save : save the current game. if there is no name given, the save name is the default name. |
java.lang.String |
getDungeonName()
|
GameFrame |
getFenetre()
Returns the game window. |
javax.swing.JDialog |
getFenetreLoading()
method :JDialog getFenetreLoading |
Room |
getFinalRoom()
Returns the finalRoom. |
Room |
getFirstRoom()
Returns the firstRoom. |
java.util.Hashtable |
getListRoom()
Returns the listItem. |
Player |
getPlayer()
Returns the player. |
boolean |
isDeveloppeur()
Returns the isDeveloppeur. |
boolean |
isLockCommand()
get the lockCommand parameter |
void |
launchCreatPerso()
void Game::launchCreatPerso create or show if already created the create perso frame |
void |
launchGame()
void Game::launchGame create or show if already created the main game frame |
void |
launchLoadGameGame()
void Game::launchLoadGame create or show if already created the load game frame for game frame |
void |
launchLoadGameMenu()
void Game::launchLoadGameGame create or show if already created the load game frame for main menu frame |
void |
launchMainMenu()
void Game::launchMainMenu create or show if already created the main Menu |
void |
launchSaveGame()
void Game::launchSaveGame create or show if already created the save ame frame |
void |
loadDungeonFromFile(java.lang.String dungeon)
method :void loadDungeonFromFile load a dungeon from a file |
void |
PlayerIsDead()
method :void PlayerIsDead method called when the player's life number if 0 so the player have lose |
void |
PlayerWin()
method :void PlayerWin method called when the player is in the final room so the player have win |
void |
setDungeonName(java.lang.String string)
set the dungeon name |
void |
setFenetre(GameFrame fenetre)
Sets the game window. |
void |
setFenetreLoading(javax.swing.JDialog dialog)
method :void setFenetreLoading |
void |
setFinalRoom(Room finalRoom)
Sets the finalRoom. |
void |
setFirstRoom(Room firstRoom)
Sets the firstRoom. |
void |
setIsDeveloppeur(boolean isDeveloppeur)
Sets if the player is a developpeur. |
void |
setListRoom(java.util.Hashtable listRoom)
Sets the listItem. |
void |
setLockCommand(boolean b)
set the lockCommand parameter lockCommand is used to stop the execution of the command, only text command ( # ) are read. |
void |
setPlayer(Player player)
Sets the player. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Game()
Method Detail |
public void executeCommand(java.lang.String com)
com
- the command to executepublic void loadDungeonFromFile(java.lang.String dungeon)
public void PlayerIsDead()
public void PlayerWin()
public void launchMainMenu()
public void launchCreatPerso()
public void launchSaveGame()
public void launchLoadGameGame()
public void launchLoadGameMenu()
public void launchGame()
public void changeIsLocked()
public Room getFinalRoom()
public Room getFirstRoom()
public java.util.Hashtable getListRoom()
public Player getPlayer()
public void setFinalRoom(Room finalRoom)
finalRoom
- The finalRoom to setpublic void setFirstRoom(Room firstRoom)
firstRoom
- The firstRoom to setpublic void setListRoom(java.util.Hashtable listRoom)
public void setPlayer(Player player)
player
- The player to setpublic boolean isDeveloppeur()
public void setIsDeveloppeur(boolean isDeveloppeur)
isDeveloppeur
- The isDeveloppeur to setpublic GameFrame getFenetre()
public void setFenetre(GameFrame fenetre)
fenetre
- The fenetre to setpublic boolean isLockCommand()
public void setLockCommand(boolean b)
b
- public javax.swing.JDialog getFenetreLoading()
public void setFenetreLoading(javax.swing.JDialog dialog)
dialog
- public java.lang.String getDungeonName()
public void setDungeonName(java.lang.String string)
string
- the dungeon name to set
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |