C# Class SunsetHigh.InGameMenu

Static class for handling the in-game menu.
Mostrar archivo Open project: ErraticUnicorn/MOSH

Public Methods

Method Description
close ( ) : void
confirm ( ) : void
draw ( SpriteBatch sb ) : void
goBack ( ) : void
init ( ) : void

Initializes all the menu panels and links them togther. Call this in the Game's create cycle. Lots of hard coding here! - we'll have to adjust it if the game's viewport size changes.

isExiting ( ) : bool
isOpen ( ) : bool
loadContent ( Microsoft.Xna.Framework.Content.ContentManager content ) : void
moveCursor ( Direction dir ) : void
open ( ) : void
pushActivePanel ( Panel panel ) : void
refreshPanelLists ( ) : void
reset ( ) : void

We'll need a cleaner method later of resetting the game.

sendOneKeyInput ( Keys key ) : bool

Used for changing key controls

update ( float elapsed ) : void

Private Methods

Method Description
nullCheck ( ) : void
popIn ( ) : void
popOut ( ) : void

Method Details

close() public static method

public static close ( ) : void
return void

confirm() public static method

public static confirm ( ) : void
return void

draw() public static method

public static draw ( SpriteBatch sb ) : void
sb Microsoft.Xna.Framework.Graphics.SpriteBatch
return void

goBack() public static method

public static goBack ( ) : void
return void

init() public static method

Initializes all the menu panels and links them togther. Call this in the Game's create cycle. Lots of hard coding here! - we'll have to adjust it if the game's viewport size changes.
public static init ( ) : void
return void

isExiting() public static method

public static isExiting ( ) : bool
return bool

isOpen() public static method

public static isOpen ( ) : bool
return bool

loadContent() public static method

public static loadContent ( Microsoft.Xna.Framework.Content.ContentManager content ) : void
content Microsoft.Xna.Framework.Content.ContentManager
return void

moveCursor() public static method

public static moveCursor ( Direction dir ) : void
dir Direction
return void

open() public static method

public static open ( ) : void
return void

pushActivePanel() public static method

public static pushActivePanel ( Panel panel ) : void
panel Panel
return void

refreshPanelLists() public static method

public static refreshPanelLists ( ) : void
return void

reset() public static method

We'll need a cleaner method later of resetting the game.
public static reset ( ) : void
return void

sendOneKeyInput() public static method

Used for changing key controls
public static sendOneKeyInput ( Keys key ) : bool
key Keys
return bool

update() public static method

public static update ( float elapsed ) : void
elapsed float
return void