Virtual U.org
Get Personal Training on VU Today
    
Top shadow
 
 register/help
User Name:

Password:

Game class Reference
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

Game Class Reference

#include <OGAME.H>

List of all members.

Public Methods

 Game ()
int init (int loadGameCall=0)
void deinit (int loadGameCall=0)
void main_menu ()
int write_file (File *filePtr)
int read_file (File *filePtr)
void hall_of_fame ()
void scenario_deinit ()
void loadgame_deinit ()
int generator (int genMode)
void gen_disp (int refreshFlag)
void gen_detect ()

Public Attributes

char init_flag
char started_flag
char game_mode
char game_has_ended


Detailed Description

Primary entry point into the Game. Displays main menu page, creates and initializes all objects in a new game or loaded game, preserves global state of game and is written to the game file when the game is saved, etc. To modify the initialization routines, see Game::init() for the methods that are called to initialize each object.

Definition at line 35 of file OGAME.H.


Constructor & Destructor Documentation

Game::Game  
 

Definition at line 47 of file Ogame.cpp.

References GAME_PREGAME.


Member Function Documentation

void Game::deinit int    loadGameCall = 0
 

[int] loadGameCall - weather this function is called when a game is being loaded (default: 0)

Definition at line 166 of file Ogame.cpp.

References CURSOR_WAITING.

void Game::gen_detect  
 

Definition at line 214 of file OGAMGEN.CPP.

void Game::gen_disp int    refreshFlag
 

[int] refreshFlag = refresh flag (default:INFO_REPAINT)

Definition at line 193 of file OGAMGEN.CPP.

References GEN_BODY_X1, GEN_BODY_X2, GEN_BODY_Y1, GEN_BODY_Y2, and INFO_REPAINT.

int Game::generator int    genMode
 

Game Generator Menu

[int] genMode : GEN_MODE_NEW - new game generation GEN_MODE_DISP - display the game settings only, without user input

return : <int> 1 - ok, the game is generated and run 0 - cancel

Definition at line 85 of file OGAMGEN.CPP.

void Game::hall_of_fame  
 

Definition at line 704 of file Ogammain.cpp.

References HALL_FAME_NUM, NULL, and SCENARIO_COUNT.

int Game::init int    loadGameCall = 0
 

Note: all functions called in this function cannot call m.random(). Otherwise, it will cause random seed sync error.

[int] loadGameCall - weather this function is called when a game is being loaded (default: 0)

Definition at line 64 of file Ogame.cpp.

References CURSOR_WAITING, FACULTY_RANK_LEVEL_COUNT, INPUT_HIGH, and PROB_SCHOOL_TYPE_COUNT.

void Game::loadgame_deinit  
 

Definition at line 96 of file Ogam_if2.cpp.

void Game::main_menu  
 

Definition at line 70 of file Ogammain.cpp.

References NULL.

Referenced by WinMain().

int Game::read_file File   filePtr
 

Definition at line 304 of file OGFILE3.CPP.

References File::file_read().

Game::scenario_deinit  
 

Definition at line 110 of file Ogam_if1.cpp.

References mem_del, and NULL.

int Game::write_file File   filePtr
 

Definition at line 300 of file OGFILE3.CPP.

References File::file_write().


Member Data Documentation

char Game::game_has_ended
 

Definition at line 40 of file OGAME.H.

char Game::game_mode
 

Definition at line 39 of file OGAME.H.

char Game::init_flag
 

Definition at line 37 of file OGAME.H.

char Game::started_flag
 

Definition at line 38 of file OGAME.H.


The documentation for this class was generated from the following files:
Generated on Fri Aug 23 01:39:12 2002 for VirtualU by doxygen1.2.17