(01452b66f) Fixed "maintain position" indicators & inputs being relative to the center of the screen, not the center of the sub. Flash the docking button when ready to dock.

This commit is contained in:
Joonas Rikkonen
2019-05-03 13:41:42 +03:00
parent fbb7daed00
commit 32a8b97ad4
11 changed files with 57 additions and 144 deletions
@@ -105,6 +105,12 @@ namespace Barotrauma
set { textBlock.TextColor = value; }
}
public override float FlashTimer
{
get { return Frame.FlashTimer; }
}
public override ScalableFont Font
{
get
@@ -128,7 +128,7 @@ namespace Barotrauma
protected Color flashColor;
protected float flashDuration = 1.5f;
private bool useRectangleFlash;
public float FlashTimer
public virtual float FlashTimer
{
get { return flashTimer; }
}
@@ -77,6 +77,12 @@ namespace Barotrauma
Content = new GUILayoutGroup(new RectTransform(new Vector2(0.9f, 0.85f), InnerFrame.RectTransform, Anchor.Center)) { AbsoluteSpacing = 5 };
Tag = tag;
InnerFrame = new GUIFrame(new RectTransform(new Point(width, height), RectTransform, Anchor.Center) { IsFixedSize = false }, style: null);
GUI.Style.Apply(InnerFrame, "", this);
Content = new GUILayoutGroup(new RectTransform(new Vector2(0.9f, 0.85f), InnerFrame.RectTransform, Anchor.Center)) { AbsoluteSpacing = 5 };
Tag = tag;
if (height == 0)
{
string wrappedText = ToolBox.WrapText(text, Content.Rect.Width, GUI.Font);