C# Class FarseerPhysics.ScreenSystem.ScreenManager

The screen manager is a component which manages one or more GameScreen instances. It maintains a stack of _screens, calls their Update and Draw methods at the appropriate times, and automatically routes _input to the topmost active screen.
Inheritance: Microsoft.Xna.Framework.DrawableGameComponent
Afficher le fichier Open project: tinco/Farseer-Physics Class Usage Examples

Méthodes publiques

Свойство Type Description
MainMenuScreen FarseerPhysics.ScreenSystem.MainMenuScreen

Méthodes publiques

Méthode Description
AddScreen ( GameScreen screen ) : void

Adds a new screen to the screen manager.

Draw ( GameTime gameTime ) : void

Tells each screen to draw itself.

GoToMainMenu ( ) : void

Goes to main menu. Removes all active screens and add a main menu

RemoveScreen ( GameScreen screen ) : void

Removes a screen from the screen manager. You should normally use GameScreen.ExitScreen instead of calling this directly, so the screen can gradually transition off rather than just being instantly removed.

ScreenManager ( Microsoft.Xna.Framework.Game game ) : System.Collections.Generic

Constructs a new screen manager component.

Update ( GameTime gameTime ) : void

Allows each screen to run logic.

Méthodes protégées

Méthode Description
LoadContent ( ) : void

Load your graphics content.

UnloadContent ( ) : void

Unload your graphics content.

Method Details

AddScreen() public méthode

Adds a new screen to the screen manager.
public AddScreen ( GameScreen screen ) : void
screen GameScreen
Résultat void

Draw() public méthode

Tells each screen to draw itself.
public Draw ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime
Résultat void

GoToMainMenu() public méthode

Goes to main menu. Removes all active screens and add a main menu
public GoToMainMenu ( ) : void
Résultat void

LoadContent() protected méthode

Load your graphics content.
protected LoadContent ( ) : void
Résultat void

RemoveScreen() public méthode

Removes a screen from the screen manager. You should normally use GameScreen.ExitScreen instead of calling this directly, so the screen can gradually transition off rather than just being instantly removed.
public RemoveScreen ( GameScreen screen ) : void
screen GameScreen
Résultat void

ScreenManager() public méthode

Constructs a new screen manager component.
public ScreenManager ( Microsoft.Xna.Framework.Game game ) : System.Collections.Generic
game Microsoft.Xna.Framework.Game
Résultat System.Collections.Generic

UnloadContent() protected méthode

Unload your graphics content.
protected UnloadContent ( ) : void
Résultat void

Update() public méthode

Allows each screen to run logic.
public Update ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime
Résultat void

Property Details

MainMenuScreen public_oe property

public MainMenuScreen,FarseerPhysics.ScreenSystem MainMenuScreen
Résultat FarseerPhysics.ScreenSystem.MainMenuScreen