Menu States
[Operating States]

Collaboration diagram for Menu States:

Implements the Root Menu and Network Options Menu. More...


Files

file  menustate.c
 The implementation for STATE_CODES::STATE_MENUROOT.
file  menustate.h
 Defines the functions used for STATE_CODES::STATE_MENUROOT.

Data Structures

struct  MenuSettings_t
 A collection of information entered by the user at the menu that is moved to other data structures for gameplay. More...

Typedefs

typedef MenuSettings_t MenuSettings

Functions

int MenuRootInit ()
 Initializes the menu items used to make the Root Menu.
int MenuRootUninit ()
 Removes the root menu.

Variables

static MenuItemmenu
 The internal list of menu items used in the current menu.
MenuSettingsmenuSettings
 The settings enetered by the user that are maintained until the game state begins but not during the game state.

Detailed Description

Implements the Root Menu and Network Options Menu.


Typedef Documentation

typedef struct MenuSettings_t MenuSettings

Definition at line 70 of file menustate.h.


Function Documentation

int MenuRootInit (  ) 

Initializes the menu items used to make the Root Menu.

Todo:
Load any persistant game settings.
Postcondition:
If successful, static menu text has been rendered and menuSettings points to allocated memory and is initalized to zero.
Returns:
True on sucess, false if there was an error.
Author:
Jeff Jackowski

Todo:
The following line of code should be in a function called when the menu may need to go through a graphic reset sort of thing.

Definition at line 42 of file menustate.c.

References COLOR_BLACK, COLOR_TEXT, colorFmtInd, LAYER_MAX, layers, menu, menuSettings, NetStatInit(), SetupMenu(), STATE_ERROR, STATE_OK, TeamSelInit(), and TextSetupStateMenu().

Here is the call graph for this function:

int MenuRootUninit (  ) 

Removes the root menu.

Postcondition:
menuSettings is not deallocated so that its settings can be used in GameInit().
Todo:
Save any persistant game settings.
Returns:
True on sucess, false if there was an error.
Author:
Jeff Jackowski

Definition at line 68 of file menustate.c.

References menu, NetStatUninit(), RemoveMenu(), STATE_OK, TeamSelUninit(), and TextUnsetState().

Here is the call graph for this function:


Variable Documentation

MenuItem* menu [static]

The internal list of menu items used in the current menu.

For internal use only.

Definition at line 40 of file menustate.c.

Referenced by MenuRootInit(), MenuRootUninit(), and SetupMenu().

MenuSettings* menuSettings

The settings enetered by the user that are maintained until the game state begins but not during the game state.

The pointer must be NULL when deallocated.

Definition at line 33 of file menustate.c.

Referenced by GameInit(), GetLocalPlayerName(), main(), MenuRootInit(), SetLocalPlayerName(), SetUsername(), TeamSelInit(), TeamSelInput(), TeamSelUninit(), and TeamSelUpdate().


Generated on Mon May 28 04:41:42 2007 for Retro Tank Super Attack by  doxygen 1.5.2