public EndScreen(SpaceSmasherBase game, EndState gameState) { gameBase = game; state = gameState; gameBase.IsMouseVisible = true; float worldWidth = XNACS1Lib.XNACS1Base.World.WorldDimension.X; float worldHeight = XNACS1Lib.XNACS1Base.World.WorldDimension.Y; afterGameBackground = new XNACS1Rectangle( new Vector2(worldWidth / 2, worldHeight / 2), worldWidth, worldHeight, GAMEOVER_BLUR_IMAGE); if (state == EndState.GAMEOVER) { afterGameForeground1 = new XNACS1Rectangle( new Vector2(worldWidth / 2, worldHeight / 2), 40f, 35f, GAMEOVER_STATIC_IMAGE); } else { afterGameForeground1 = new XNACS1Rectangle( new Vector2(worldWidth / 2, worldHeight / 2), 40f, 35f, GAMEWIN_STATIC_IMAGE); } }
public StartScreen(SpaceSmasherBase game) { gameBase = game; gameBase.IsMouseVisible = true; XNACS1Lib.XNACS1Base.World.SetBackgroundTexture(backgroundTexture); state = StartScreenState.START; startButton = new XNACS1Rectangle( new Vector2( XNACS1Lib.XNACS1Base.World.WorldDimension.X * 0.4f, XNACS1Lib.XNACS1Base.World.WorldDimension.Y * 0.4f), 14f, 6f, START_BUTTON_STATIC ); }