From 99b67df6be5657db591b3b8a4f284be415ae595c Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Fri, 5 Jun 2020 21:01:53 +0200 Subject: [PATCH] fixed being able to fade out the ui while swiping --- TouchyTickets/Ui.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/TouchyTickets/Ui.cs b/TouchyTickets/Ui.cs index 883ff7d..3721709 100644 --- a/TouchyTickets/Ui.cs +++ b/TouchyTickets/Ui.cs @@ -110,6 +110,8 @@ namespace TouchyTickets { map.Draw(time, batch, pos, scale, alpha, false, new RectangleF(Vector2.Zero, mapSize * scale)); }, OnPressed = e => { + if (this.swipeProgress != 0) + return; var map = GameImpl.Instance.Map; var infoUi = new Group(Anchor.BottomLeft, new Vector2(1)); infoUi.AddChild(new Button(Anchor.AutoInlineIgnoreOverflow, new Vector2(0.5F, 30), Localization.Get("Back")) { @@ -145,6 +147,8 @@ namespace TouchyTickets { ChildPadding = new Vector2(4), PositionOffset = new Vector2(0, 1), OnPressed = e => { + if (this.swipeProgress != 0) + return; var map = GameImpl.Instance.Map; map.PlacingAttraction = attraction.Value.Create(); // set placing position to center of camera's view