From af0ba50d00722e1b7330d1f9b1d23bd3b07a5567 Mon Sep 17 00:00:00 2001 From: aldrikboy Date: Wed, 17 Jan 2018 14:26:43 +0100 Subject: upgrades --- Penguloon/Controls/IngameOptions.cs | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'Penguloon/Controls/IngameOptions.cs') diff --git a/Penguloon/Controls/IngameOptions.cs b/Penguloon/Controls/IngameOptions.cs index e5a6890..137094c 100644 --- a/Penguloon/Controls/IngameOptions.cs +++ b/Penguloon/Controls/IngameOptions.cs @@ -23,6 +23,8 @@ namespace Penguloon.Controls public MessageBox QuitConfirmationBox { get; set; } public DateTime ShowTimeMsgBox { get; set; } + public MuteButton BtnMute { get; set; } + public IngameOptions(SceneBase parentScene, Vector2 position, Vector2 size) : base(parentScene, position, size) { this.DrawText = false; @@ -33,6 +35,10 @@ namespace Penguloon.Controls Vector2 BtnSize = new Vector2(Size.X - 90, StaticUIValues.IngameUIPlayButtonHeight); Vector2 MsgBoxSize = new Vector2(900, 550); + BtnMute = new MuteButton(parentScene, + new Vector2(position.X + (Size.X / 2) - (BtnSize.X / 2), Position.Y + Size.Y - (50 * 2) - (BtnSize.Y * 2)), + new Vector2(StaticUIValues.MenuButtonSize.Y, StaticUIValues.MenuButtonSize.Y)); + BtnContinue = new Button(parentScene, new Vector2(position.X + (Size.X / 2) - (BtnSize.X / 2), Position.Y + 50), BtnSize, parentScene.Main.Resources.GetString(Resource.String.IngameOptionsContinue)); @@ -58,7 +64,10 @@ namespace Penguloon.Controls GameScene gameScene = (GameScene)ParentScene; gameScene.Level.FinishGame(); - SceneManager.SelectedScene = SelectedScene.Menu; + gameScene.Level.EndDate = DateTime.Now; + gameScene.IngameEndStats.State = IngameOptionsState.Show; + + //SceneManager.SelectedScene = SelectedScene.Menu; } private void QuitConfirmationBox_OnMissClick(object sender, EventArgs e) @@ -93,6 +102,7 @@ namespace Penguloon.Controls BtnContinue.Draw(deltaTime); BtnQuit.Draw(deltaTime); QuitConfirmationBox.Draw(deltaTime); + BtnMute.Draw(deltaTime); } public override void Update(float deltaTime, TouchLocation[] touchLocations) @@ -109,6 +119,7 @@ namespace Penguloon.Controls BtnContinue.Update(deltaTime, touchLocations); BtnQuit.Update(deltaTime, touchLocations); + BtnMute.Update(deltaTime, touchLocations); } } } \ No newline at end of file -- cgit v1.2.3-70-g09d2