diff options
Diffstat (limited to 'Penguloon/Scenes')
| -rw-r--r-- | Penguloon/Scenes/GameScene.cs | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/Penguloon/Scenes/GameScene.cs b/Penguloon/Scenes/GameScene.cs index 5412147..40a7650 100644 --- a/Penguloon/Scenes/GameScene.cs +++ b/Penguloon/Scenes/GameScene.cs @@ -17,6 +17,7 @@ namespace Penguloon.Scenes public SpeedButton ChangeSpeedBtn { get; set; } public ButtonIngame OptionsBtn { get; set; } public IngameOptions OptionsMenu { get; set; } + public IngameEndStats IngameEndStats { get; set; } public ObjectSelector ObjectSeletor { get; set; } @@ -42,6 +43,11 @@ namespace Penguloon.Scenes (StaticUIValues.ScreenViewport.Y / 2) - (StaticUIValues.IngameOptionsSize.Y / 2)), StaticUIValues.IngameOptionsSize); + IngameEndStats = new IngameEndStats(this, + new Vector2((StaticUIValues.ScreenViewport.X / 2) - (StaticUIValues.IngameOptionsSize.X / 2), + (StaticUIValues.ScreenViewport.Y / 2) - (StaticUIValues.IngameOptionsSize.Y / 2)), + StaticUIValues.IngameOptionsSize); + ChangeSpeedBtn.OnClick += ChangeSpeedBtn_OnClick; StartRoundBtn.OnClick += StartRoundBtn_OnClick; OptionsBtn.OnClick += OptionsBtn_OnClick; @@ -136,20 +142,23 @@ namespace Penguloon.Scenes (int)StaticUIValues.ScreenViewport.Y - StaticUIValues.IngameUIPlayButtonHeight - StaticUIValues.BorderWidth, (int)StaticUIValues.ScreenViewport.X - (Level.Map.MapWidth + StaticUIValues.BorderWidth - 5), StaticUIValues.BorderWidth)); - DrawText(ContentManager.GetFont(StaticUIValues.IngameFont), "Gold: " + Level.Money, + DrawText(ContentManager.GetFont(StaticUIValues.IngameFont), Main.Resources.GetString(Resource.String.IngameGold) + ": " + Level.Money, new Vector2(Level.Map.MapWidth + StaticUIValues.BorderWidth, 10), new Vector2(StaticUIValues.ScreenViewport.X - Level.Map.MapWidth - StaticUIValues.BorderWidth, StaticUIValues.IngameUITextAreaHeight), TextAllignment.LeftTop, Color.White, Color.Black, 2); - DrawText(ContentManager.GetFont(StaticUIValues.IngameFont), "Wave: " + Level.Map.WaveManager.CurrentWave.ToString(), + DrawText(ContentManager.GetFont(StaticUIValues.IngameFont), Main.Resources.GetString(Resource.String.IngameWave) + ": " + Level.Map.WaveManager.CurrentWave.ToString(), new Vector2(Level.Map.MapWidth + StaticUIValues.BorderWidth, 0), new Vector2(StaticUIValues.ScreenViewport.X - Level.Map.MapWidth - StaticUIValues.BorderWidth, StaticUIValues.IngameUITextAreaHeight), TextAllignment.LeftMiddle, Color.White, Color.Black, 2); - DrawText(ContentManager.GetFont(StaticUIValues.IngameFont), "Health: " + Level.Health, + DrawText(ContentManager.GetFont(StaticUIValues.IngameFont), Main.Resources.GetString(Resource.String.IngameHealth) + ": " + Level.Health, new Vector2(Level.Map.MapWidth + StaticUIValues.BorderWidth, 0), new Vector2(StaticUIValues.ScreenViewport.X - Level.Map.MapWidth - StaticUIValues.BorderWidth, StaticUIValues.IngameUITextAreaHeight), TextAllignment.LeftBottom, Color.White, Color.Black, 2); + + // draw finished controls here + IngameEndStats.Draw(deltaTime); } public override void Update(float deltaTime, TouchLocation[] touchLocations) @@ -164,6 +173,11 @@ namespace Penguloon.Scenes OptionsBtn.Update(deltaTime, touchLocations); OptionsMenu.Update(deltaTime, touchLocations); } + // update finished controls here + else + { + IngameEndStats.Update(deltaTime, touchLocations); + } if (StartRoundBtn.ControlState == ControlState.Disabled && !Level.Map.WaveManager.RoundActive && !Level.Finished) { |
