C# Class flxSharp.flxSharp.System.FlxGameRunner

Inheritance: Microsoft.Xna.Framework.Game
Datei anzeigen Open project: jlorek/flxSharp Class Usage Examples

Public Methods

Method Description
FlxGameRunner ( int gameSizeX, int gameSizeY, FlxState initialState, float zoom = 1.0f, int gameFramerate = 60, int flashFramerate, bool useSystemCursor = false ) : Microsoft.Xna.Framework

Setup the XNA graphics system and create a new FlxGame from the given arguments;

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
BasicDraw ( ) : 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

FlxGameRunner() public method

Setup the XNA graphics system and create a new FlxGame from the given arguments;
public FlxGameRunner ( int gameSizeX, int gameSizeY, FlxState initialState, float zoom = 1.0f, int gameFramerate = 60, int flashFramerate, bool useSystemCursor = false ) : Microsoft.Xna.Framework
gameSizeX int The width of your game in game pixels, not necessarily final display pixels (see Zoom).
gameSizeY int The height of your game in game pixels, not necessarily final display pixels (see Zoom).
initialState FlxState The class name of the state you want to create and switch to first (e.g. MenuState).
zoom float The default level of zoom for the game's cameras (e.g. 2 = all pixels are now drawn at 2x). Default = 1.
gameFramerate int How frequently the game should update (default is 60 times per second).
flashFramerate int Sets the actual display framerate for Flash player (default is 30 times per second).
useSystemCursor bool Whether to use the default OS mouse pointer, or to use custom flixel ones.
return Microsoft.Xna.Framework

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

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