New icon for settings and make the top left text more user friendly

This commit is contained in:
Evil Factory
2026-04-18 16:36:36 -03:00
parent f5f7eb7af9
commit bb21a09244
4 changed files with 28 additions and 4 deletions
@@ -43,11 +43,31 @@ internal class MainMenuPatch : ISystem, IEventScreenSelected
{
if (mainMenuUIAdded) { return; }
new GUITextBlock(new RectTransform(new Point(300, 30), screen.Frame.RectTransform, Anchor.TopLeft) { AbsoluteOffset = new Point(10, 10) }, $"Using LuaCsForBarotrauma revision {AssemblyInfo.GitRevision}", Color.Red)
var textBlock = new GUITextBlock(new RectTransform(new Point(300, 30), screen.Frame.RectTransform, Anchor.TopLeft) { AbsoluteOffset = new Point(10, 10) }, "", Color.Red)
{
IgnoreLayoutGroups = false
};
textBlock.OnAddedToGUIUpdateList = (GUIComponent component) =>
{
string mode = LuaCsSetup.Instance.CsRunPolicyValue;
if (mode is "Prompt")
{
mode = "Enabled (prompt mode)";
}
else if (mode is "Enabled")
{
mode = "Always enabled";
}
else
{
mode = "Disabled";
}
textBlock.Text = $"LuaCsForBarotrauma active (revision {AssemblyInfo.GitRevision}), csharp is currently {mode}\nNew settings available in the game settings menu.";
};
mainMenuUIAdded = true;
}
#endif