Move trade cargo selector into runtime projection

This commit is contained in:
Meta Vens 2026-06-21 21:36:35 +01:00
commit 3738826fd5
3 changed files with 216 additions and 50 deletions

View file

@ -4536,14 +4536,18 @@ static void RequireTradeCargoSelectorUseEveSurface(string root)
var requiredSymbols = new[]
{
"RenderCargoSelectorSurface(",
"BuildCargoSelectionCommands(",
"_cargoSelectorSurfaceProjection = ProjectTradeCargoSelectorSurface();",
"HandleCargoSelectorSurfaceCommand(",
"AetheriaEveUnitySurfaceHost.RenderRuntime(",
"AetheriaEveUnitySurfaceHost.Hide(_cargoSelectorSurfaceDocument)",
"AetheriaRuntimeTradeCargoSelectorSurfaceBuilder.Build(ProjectTradeCargoSelectorSurfaceState(",
"ProjectTradeCargoSelectorSurfaceState(",
"AetheriaRuntimeTradeCargoSelectorSurfaceBuilder.DockingBay",
"AetheriaRuntimeTradeCargoSelectorSurfaceBuilder.ShipBayCommand(",
"AetheriaRuntimeTradeCargoSelectorSurfaceBuilder.Build(_cargoSelectorSurfaceProjection.State)",
"ProjectTradeCargoSelectorSurface(",
"AetheriaRuntimeTradeCargoSelectorSurfaceBuilder.Project(",
"_cargoSelectorSurfaceProjection?.TryResolve(command.Command, out var selection) == true",
"ApplyCargoSelection(",
"new AetheriaRuntimeTradeCargoProjectionOption(",
"AetheriaRuntimeTradeCargoTargetKind.DockingBay",
"AetheriaRuntimeTradeCargoTargetKind.ShipBay",
"AetheriaRuntimeTradeCargoSelectorSurfaceCommands.TryRead(request, out var command)",
"AetheriaRuntimeTradeCargoSelectorCommandKind.Close",
"AetheriaRuntimeTradeCargoSelectorCommandKind.Select",
@ -4578,6 +4582,9 @@ static void RequireTradeCargoSelectorUseEveSurface(string root)
"new EveSurfaceComponent(",
"string.Equals(request.Command, AetheriaRuntimeTradeCargoSelectorSurfaceBuilder.Close",
"_cargoSelectionCommands.TryGetValue(request.Command",
"private readonly Dictionary<string, (EquippedCargoBay Cargo, string Label)> _cargoSelectionCommands",
"BuildCargoSelectionCommands(",
"ProjectTradeCargoSelectorSurfaceState(",
"GameManager.DockedEntity.Children",
"GameManager.CurrentEntity.Parent.Children",
"GameManager.DockedEntity == null",
@ -4608,7 +4615,13 @@ static void RequireTradeCargoSelectorUseEveSurface(string root)
"public static bool TryRead(",
"AetheriaRuntimeTradeCargoSelectorSurfaceState",
"AetheriaRuntimeTradeCargoTargetOption",
"AetheriaRuntimeTradeCargoProjectionOption",
"AetheriaRuntimeTradeCargoTargetKind",
"AetheriaRuntimeTradeCargoSelection",
"AetheriaRuntimeTradeCargoSelectorSurfaceProjection",
"public static string ShipBayCommand(",
"public static AetheriaRuntimeTradeCargoSelectorSurfaceProjection Project(",
"public bool TryResolve(string command, out AetheriaRuntimeTradeCargoSelection selection)",
"public static AetheriaRuntimeSurfaceDocument Build(",
"providerKind: \"trade.menu\"",
"The observing client projects available cargo targets; the shared runtime surface owns the cargo selector contract."