Fix window positions not saving (#35055)

Co-authored-by: Kevin Zheng <kevinz5000@gmail.com>
This commit is contained in:
metalgearsloth
2025-02-23 23:57:57 +11:00
committed by GitHub
parent fabfdd0673
commit 634c4a7780
11 changed files with 12 additions and 26 deletions

View File

@@ -17,7 +17,7 @@ public sealed class PortableGeneratorBoundUserInterface : BoundUserInterface
protected override void Open()
{
base.Open();
_window = this.CreateWindow<GeneratorWindow>();
_window = this.CreateWindowCenteredLeft<GeneratorWindow>();
_window.SetEntity(Owner);
_window.OnState += args =>
{
@@ -34,8 +34,6 @@ public sealed class PortableGeneratorBoundUserInterface : BoundUserInterface
_window.OnPower += SetTargetPower;
_window.OnEjectFuel += EjectFuel;
_window.OnSwitchOutput += SwitchOutput;
_window.OpenCenteredLeft();
}
protected override void UpdateState(BoundUserInterfaceState state)