feat(ui): D.2b-B — F12 shows the real gmInventoryUI (0x21000023)

Swap the Sub-phase A placeholder UiNineSlicePanel for LayoutImporter.Import
(0x21000023). The sub-window mount nests the paperdoll/backpack/3D-items
panels; the window starts hidden, registered under WindowNames.Inventory,
toggled by F12 via the window manager (unchanged).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Erik 2026-06-20 22:37:01 +02:00
parent 85098f535d
commit 7d971a2b3e

View file

@ -2138,18 +2138,25 @@ public sealed class GameWindow : IDisposable
} }
} }
// Phase D.2b-A — placeholder inventory window. Starts HIDDEN; F12 // Phase D.2b-B — the real inventory window from LayoutDesc 0x21000023 (gmInventoryUI),
// (InputAction.ToggleInventoryPanel) reveals it via the UiRoot window // via the LayoutImporter. The sub-window mount pulls in the nested paperdoll/backpack/
// manager. Throwaway scaffolding: Sub-phase B replaces the body with the // 3D-items panels (Type-0 leaves inheriting BaseLayoutId 0x21000024/22/21). Starts
// real gmInventoryUI (0x21000023) nested layout, keeping the same name. // HIDDEN; F12 toggles it via the window manager. Position is the dat's own (X=500,Y=138).
var inventoryWindow = new AcDream.App.UI.UiNineSlicePanel(ResolveChrome) AcDream.App.UI.Layout.ImportedLayout? invLayout;
lock (_datLock)
invLayout = AcDream.App.UI.Layout.LayoutImporter.Import(
_dats!, 0x21000023u, ResolveChrome, vitalsDatFont);
if (invLayout is not null)
{ {
Left = 220, Top = 120, Width = 320, Height = 400, var inventoryWindow = invLayout.Root;
Visible = false, inventoryWindow.Visible = false;
}; inventoryWindow.Anchors = AcDream.App.UI.AnchorEdges.None; // user-positioned
_uiHost.Root.AddChild(inventoryWindow); inventoryWindow.Draggable = true;
_uiHost.RegisterWindow(AcDream.App.UI.WindowNames.Inventory, inventoryWindow); _uiHost.Root.AddChild(inventoryWindow);
Console.WriteLine("[D.2b-A] placeholder inventory window registered (F12 toggles)."); _uiHost.RegisterWindow(AcDream.App.UI.WindowNames.Inventory, inventoryWindow);
Console.WriteLine("[D.2b-B] retail inventory window from LayoutDesc importer (0x21000023).");
}
else Console.WriteLine("[D.2b-B] inventory: LayoutDesc 0x21000023 not found.");
} }
// Phase N.4+N.5 — WB rendering pipeline foundation. The modern path is // Phase N.4+N.5 — WB rendering pipeline foundation. The modern path is