Method | Description | |
---|---|---|
AddScreen ( |
Adds a new screen to the screen manager.
|
|
Draw ( |
Tells each screen to draw itself.
|
|
DrawRectangle ( |
Draw an empty rectangle of the given size and color.
|
|
EndRun ( ) : void | ||
FadeBackBufferToBlack ( int alpha ) : void |
Helper draws a translucent black fullscreen sprite, used for fading screens in and out, and for darkening the background behind popups.
|
|
GetScreens ( ) : NScumm.MonoGame.GameScreen[] |
Expose an array holding all the screens. We return a copy rather than the real master list, because screens should only ever be added or removed using the AddScreen and RemoveScreen methods.
|
|
RemoveScreen ( |
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 |
Constructs a new screen manager component.
|
|
Update ( |
Allows each screen to run logic.
|
Method | Description | |
---|---|---|
LoadContent ( ) : void |
Load your graphics content.
|
|
UnloadContent ( ) : void |
Unload your graphics content.
|
Method | Description | |
---|---|---|
TraceScreens ( ) : void |
Prints a list of all the screens, for debugging.
|
public AddScreen ( |
||
screen | ||
return | void |
public Draw ( |
||
gameTime | ||
return | void |
public DrawRectangle ( |
||
rectangle | The destination rectangle. | |
color | Color | The color of the rectangle. |
blendState | The blending to use. | |
return | void |
public FadeBackBufferToBlack ( int alpha ) : void | ||
alpha | int | |
return | void |
public GetScreens ( ) : NScumm.MonoGame.GameScreen[] | ||
return | NScumm.MonoGame.GameScreen[] |
public RemoveScreen ( |
||
screen | ||
return | void |
public ScreenManager ( Microsoft.Xna.Framework.Game game ) : System | ||
game | Microsoft.Xna.Framework.Game | |
return | System |
public Update ( |
||
gameTime | ||
return | void |