C# Class Manic_Shooter.ManicShooter

This is the main type for your game
Inheritance: Microsoft.Xna.Framework.Game
Exibir arquivo Open project: TheGameDevelopmentClub/Manic-Shooter Class Usage Examples

Public Properties

Property Type Description
RNG System.Random
ScreenSize Microsoft.Xna.Framework.Rectangle
_gameState gameStates
playerPosition Vector2

Protected Properties

Property Type Description
song Song

Public Methods

Method Description
ManicShooter ( ) : System
gameKey_pausePressed ( Keys key ) : void
gameKey_spawnDefault ( Keys key ) : void
gameKey_spawnHunter ( Keys key ) : void
gameKey_spawnMob1 ( Keys Key ) : void
gameKey_spawnMob2 ( Keys Key ) : void
gameKey_spawnMob3 ( Keys key ) : void
gameKey_spawnTriangle ( Keys key ) : void

Protected Methods

Method Description
Draw ( GameTime gameTime ) : void

This is called when the game should draw itself.

Initialize ( ) : void

Allows the game to perform any initialization it needs to before starting to run. This is where it can query for any required services and load any non-graphic related content. Calling base.Initialize will enumerate through any components and initialize them as well.

LoadContent ( ) : void

LoadContent will be called once per game and is the place to load all of your content.

UnloadContent ( ) : void

UnloadContent will be called once per game and is the place to unload all content.

Update ( GameTime gameTime ) : void

Allows the game to run logic such as updating the world, checking for collisions, gathering input, and playing audio.

Private Methods

Method Description
DrawGameOver ( GameTime gameTime ) : void
DrawMenu ( GameTime gameTime ) : void
DrawPlay ( GameTime gameTime ) : void
GameStateSwitched ( ) : void
InitGameOverState ( ) : void
InitMenuState ( ) : void
InitPlayState ( ) : void
ParseMenuAction ( ) : void
SpawnEnemy ( ) : void
UpdateGameOver ( GameTime gameTime ) : void
UpdateMenu ( GameTime gameTime ) : void
UpdatePlay ( GameTime gameTime ) : void
gameOverTimer_Elapsed ( object sender, System.Timers.ElapsedEventArgs e ) : void

Method Details

Draw() protected method

This is called when the game should draw itself.
protected Draw ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime Provides a snapshot of timing values.
return void

Initialize() protected method

Allows the game to perform any initialization it needs to before starting to run. This is where it can query for any required services and load any non-graphic related content. Calling base.Initialize will enumerate through any components and initialize them as well.
protected Initialize ( ) : void
return void

LoadContent() protected method

LoadContent will be called once per game and is the place to load all of your content.
protected LoadContent ( ) : void
return void

ManicShooter() public method

public ManicShooter ( ) : System
return System

UnloadContent() protected method

UnloadContent will be called once per game and is the place to unload all content.
protected UnloadContent ( ) : void
return void

Update() protected method

Allows the game to run logic such as updating the world, checking for collisions, gathering input, and playing audio.
protected Update ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime Provides a snapshot of timing values.
return void

gameKey_pausePressed() public method

public gameKey_pausePressed ( Keys key ) : void
key Keys
return void

gameKey_spawnDefault() public method

public gameKey_spawnDefault ( Keys key ) : void
key Keys
return void

gameKey_spawnHunter() public method

public gameKey_spawnHunter ( Keys key ) : void
key Keys
return void

gameKey_spawnMob1() public method

public gameKey_spawnMob1 ( Keys Key ) : void
Key Keys
return void

gameKey_spawnMob2() public method

public gameKey_spawnMob2 ( Keys Key ) : void
Key Keys
return void

gameKey_spawnMob3() public method

public gameKey_spawnMob3 ( Keys key ) : void
key Keys
return void

gameKey_spawnTriangle() public method

public gameKey_spawnTriangle ( Keys key ) : void
key Keys
return void

Property Details

RNG public_oe static_oe property

public static Random,System RNG
return System.Random

ScreenSize public_oe static_oe property

public static Rectangle,Microsoft.Xna.Framework ScreenSize
return Microsoft.Xna.Framework.Rectangle

_gameState public_oe property

public gameStates _gameState
return gameStates

playerPosition public_oe static_oe property

public static Vector2 playerPosition
return Vector2

song protected_oe property

protected Song song
return Song