# GravityChooser.GravityChooserBackgroundScreen Class Reference

Background screen for gravity chooser. More...

Inheritance diagram for GravityChooser.GravityChooserBackgroundScreen:

List of all members.

## Public Member Functions
| GravityChooserBackgroundScreen ()
| Constructor for the GravityChooserBackgroundScreen.
override void | LoadContent ()
| Loads graphics content for the GravityChooserBackgroundScreen.
override void | UnloadContent ()
| Unloads graphics content for the GravityChooserBackgroundScreen.
override void | Update (GameTime gameTime, bool otherScreenHasFocus, bool coveredByOtherScreen)
| Updates the background screen.
override void | Draw (GameTime gameTime)
| Draws the background screen.

## Detailed Description

Background screen for gravity chooser.

Definition at line 19 of file GravityChooserBackgroundScreen.cs.

## Constructor & Destructor Documentation

GravityChooser.GravityChooserBackgroundScreen.GravityChooserBackgroundScreen | ( |  | ) |

Constructor for the GravityChooserBackgroundScreen.

Definition at line 40 of file GravityChooserBackgroundScreen.cs.

    00041         {
    00042             TransitionOnTime = TimeSpan.FromSeconds(0.5);
    00043             TransitionOffTime = TimeSpan.FromSeconds(0.5);
    00044         }

## Member Function Documentation

override void GravityChooser.GravityChooserBackgroundScreen.Draw | ( | GameTime | gameTime | ) | `[virtual]`

Draws the background screen.

Reimplemented from NewGamePhysics.StateManager.GameScreen.

Definition at line 83 of file GravityChooserBackgroundScreen.cs.

    00084         {
    00085             SpriteBatch spriteBatch = ScreenManager.SpriteBatch;
    00086             Viewport viewport = ScreenManager.GraphicsDevice.Viewport;
    00087             Rectangle fullscreen = new Rectangle(0, 0, viewport.Width, viewport.Height);
    00088             byte fade = TransitionAlpha;
    00089
    00090             spriteBatch.Begin(SpriteBlendMode.None);
    00091
    00092             spriteBatch.Draw(backgroundTexture, fullscreen,
    00093                              new Color(fade, fade, fade));
    00094
    00095             spriteBatch.End();
    00096         }

override void GravityChooser.GravityChooserBackgroundScreen.LoadContent | ( |  | ) | `[virtual]`

Loads graphics content for the GravityChooserBackgroundScreen.

Reimplemented from NewGamePhysics.StateManager.GameScreen.

Definition at line 49 of file GravityChooserBackgroundScreen.cs.

    00050         {
    00051             if (contentManager == null)
    00052             {
    00053                 contentManager = new ContentManager(ScreenManager.Game.Services, "Content");
    00054             }
    00055
    00056             backgroundTexture = contentManager.Load<Texture2D>(@"Sprites\background");
    00057         }

override void GravityChooser.GravityChooserBackgroundScreen.UnloadContent | ( |  | ) | `[virtual]`

Unloads graphics content for the GravityChooserBackgroundScreen.

Reimplemented from NewGamePhysics.StateManager.GameScreen.

Definition at line 62 of file GravityChooserBackgroundScreen.cs.

    00063         {
    00064             contentManager.Unload();
    00065         }

override void GravityChooser.GravityChooserBackgroundScreen.Update | ( | GameTime | gameTime,
|  | bool | otherScreenHasFocus,
|  | bool | coveredByOtherScreen |
| ) |  |  | `[virtual]`

Updates the background screen.

Reimplemented from NewGamePhysics.StateManager.GameScreen.

Definition at line 74 of file GravityChooserBackgroundScreen.cs.

    00076         {
    00077             base.Update(gameTime, otherScreenHasFocus, false);
    00078         }

The documentation for this class was generated from the following file:

- C:/Users/Andreas Schiffler/Desktop/SVN/NewGamePhysics/GravityChooser/Screens/GravityChooserBackgroundScreen.cs