From b88bafd9e1d556d337306083d8902ba600723ebe Mon Sep 17 00:00:00 2001 From: Meta Vens Date: Mon, 6 Jul 2026 01:29:53 +0100 Subject: [PATCH] Use managed Verse target copy --- Aetheria.State.Verify/Program.cs | 66 ++++++++++++++++++- .../Gameplay/AetheriaDaemonObserver.cs | 2 +- .../UI/InputScreen/InputDisplayLayout.cs | 2 +- Assets/Scripts/UI/MainMenu.cs | 2 +- Assets/Scripts/UI/Menu/InventoryPanel.cs | 4 +- Assets/Scripts/UI/Menu/SectorRenderer.cs | 4 +- .../Runtime/AetheriaClient.cs | 2 +- ...theriaRuntimeClientTargetSurfaceBuilder.cs | 2 +- .../AetheriaRuntimeDaemonRenderQueries.cs | 2 +- 9 files changed, 75 insertions(+), 11 deletions(-) diff --git a/Aetheria.State.Verify/Program.cs b/Aetheria.State.Verify/Program.cs index c16e5d7bd..f7105cd99 100644 --- a/Aetheria.State.Verify/Program.cs +++ b/Aetheria.State.Verify/Program.cs @@ -2137,6 +2137,12 @@ static void RequireDaemonRenderQueryAuthority(string root) var querySource = File.Exists(queryPath) ? File.ReadAllText(queryPath) : throw new InvalidOperationException("Daemon render queries must live in the shared Aetheria runtime package, not in Unity ZoneRenderer."); + if (querySource.Contains("Unity XZ viewport", StringComparison.Ordinal) || + querySource.Contains("through Unity axes", StringComparison.Ordinal)) + { + throw new InvalidOperationException( + "Shared daemon render query types must use domain projection vocabulary, not runtime-specific Unity axis copy."); + } var packageSnapshotPath = Path.Combine(root, "Packages", "org.gamecult.aetheria.state", "Runtime", "AetheriaRuntimeSnapshotDocuments.cs"); var packageSnapshot = File.Exists(packageSnapshotPath) @@ -8073,6 +8079,64 @@ static void RequireUnitySharedDocumentAccessorErgonomics(string root) string.Join(", ", forbiddenMainMenuSharedDocumentHits)); } + var managedVerseCopySources = new Dictionary + { + ["Packages/org.gamecult.aetheria.state/Runtime/AetheriaClient.cs"] = File.ReadAllText(Path.Combine( + root, + "Packages", + "org.gamecult.aetheria.state", + "Runtime", + "AetheriaClient.cs")), + ["Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeClientTargetSurfaceBuilder.cs"] = File.ReadAllText(Path.Combine( + root, + "Packages", + "org.gamecult.aetheria.state", + "Runtime", + "AetheriaRuntimeClientTargetSurfaceBuilder.cs")), + ["Assets/Scripts/Gameplay/AetheriaDaemonObserver.cs"] = File.ReadAllText(Path.Combine( + root, + "Assets", + "Scripts", + "Gameplay", + "AetheriaDaemonObserver.cs")), + ["Assets/Scripts/UI/InputScreen/InputDisplayLayout.cs"] = File.ReadAllText(Path.Combine( + root, + "Assets", + "Scripts", + "UI", + "InputScreen", + "InputDisplayLayout.cs")), + ["Assets/Scripts/UI/MainMenu.cs"] = mainMenu, + ["Assets/Scripts/UI/Menu/InventoryPanel.cs"] = File.ReadAllText(Path.Combine( + root, + "Assets", + "Scripts", + "UI", + "Menu", + "InventoryPanel.cs")), + ["Assets/Scripts/UI/Menu/SectorRenderer.cs"] = File.ReadAllText(Path.Combine( + root, + "Assets", + "Scripts", + "UI", + "Menu", + "SectorRenderer.cs")) + }; + var staleLocalVerseCopyHits = managedVerseCopySources + .Where(pair => + pair.Value.Contains("local Verse state", StringComparison.Ordinal) || + pair.Value.Contains("local Aetheria Verse state", StringComparison.Ordinal) || + pair.Value.Contains("selected local Verse state file", StringComparison.Ordinal) || + pair.Value.Contains("readable local Verse state file", StringComparison.Ordinal)) + .Select(pair => pair.Key) + .ToArray(); + if (staleLocalVerseCopyHits.Length > 0) + { + throw new InvalidOperationException( + "Managed client/UI surfaces must describe typed Verse targets/documents instead of teaching local-file Verse authority: " + + string.Join(", ", staleLocalVerseCopyHits)); + } + var tradeMenu = File.ReadAllText(Path.Combine( root, "Assets", @@ -13528,7 +13592,7 @@ static void RequireMainMenuVerseHostDocumentAccess(string root) "\"Verse\"", "\"Visibility\"", "\"CultMesh\"", - "Client target edits are local. Visibility changes append provider-owned Eve requests" + "Client target edits persist through the managed target document. Visibility changes append provider-owned Eve requests against the selected Verse target." }; var missingMainMenuSymbols = requiredMainMenuSymbols .Where(symbol => !mainMenu.Contains(symbol, StringComparison.Ordinal)) diff --git a/Assets/Scripts/Gameplay/AetheriaDaemonObserver.cs b/Assets/Scripts/Gameplay/AetheriaDaemonObserver.cs index 786bceee9..489479bb0 100644 --- a/Assets/Scripts/Gameplay/AetheriaDaemonObserver.cs +++ b/Assets/Scripts/Gameplay/AetheriaDaemonObserver.cs @@ -118,7 +118,7 @@ public sealed class AetheriaDaemonObserver : MonoBehaviour if (!stateBoot.SupportsLocalStateFileRead || !stateBoot.StateFileExists) { throw new InvalidOperationException( - $"Aetheria daemon observer requires a readable local Verse state file: {stateBoot.FailureMessage}"); + $"Aetheria daemon observer requires a readable managed Verse target: {stateBoot.FailureMessage}"); } _renderDocuments = AetheriaUnityRuntimeClientProvider.DaemonRenderDocuments(stateBoot, clientId); diff --git a/Assets/Scripts/UI/InputScreen/InputDisplayLayout.cs b/Assets/Scripts/UI/InputScreen/InputDisplayLayout.cs index ff6357690..1af9bafb9 100644 --- a/Assets/Scripts/UI/InputScreen/InputDisplayLayout.cs +++ b/Assets/Scripts/UI/InputScreen/InputDisplayLayout.cs @@ -360,7 +360,7 @@ public class InputDisplayLayout : MonoBehaviour if (!stateBoot.SupportsLocalStateFileRead || !stateBoot.StateFileExists) { throw new InvalidOperationException( - $"Input settings require a readable local Aetheria Verse state file: {stateBoot.FailureMessage}"); + $"Input settings require a readable managed Aetheria Verse target: {stateBoot.FailureMessage}"); } return stateBoot; diff --git a/Assets/Scripts/UI/MainMenu.cs b/Assets/Scripts/UI/MainMenu.cs index bd2d2cf09..d99866312 100644 --- a/Assets/Scripts/UI/MainMenu.cs +++ b/Assets/Scripts/UI/MainMenu.cs @@ -704,7 +704,7 @@ public class MainMenu : MonoBehaviour if (!stateBoot.SupportsLocalStateFileRead || !stateBoot.StateFileExists) { Debug.LogWarning( - $"Cannot send {label} command because the active target is not a readable local Verse state file."); + $"Cannot send {label} command because the active Verse target is not readable."); return false; } diff --git a/Assets/Scripts/UI/Menu/InventoryPanel.cs b/Assets/Scripts/UI/Menu/InventoryPanel.cs index fd1d0ff13..cf91d01ab 100644 --- a/Assets/Scripts/UI/Menu/InventoryPanel.cs +++ b/Assets/Scripts/UI/Menu/InventoryPanel.cs @@ -385,7 +385,7 @@ public class InventoryPanel : MonoBehaviour, IPointerClickHandler } catch (Exception ex) { - Debug.LogWarning($"Failed to read Aetheria inventory panel surface from local Verse state: {ex.Message}"); + Debug.LogWarning($"Failed to read Aetheria inventory panel surface from managed Verse state: {ex.Message}"); return null; } } @@ -398,7 +398,7 @@ public class InventoryPanel : MonoBehaviour, IPointerClickHandler } catch (Exception ex) { - Debug.LogWarning($"Failed to read Aetheria inventory dropdown surface from local Verse state: {ex.Message}"); + Debug.LogWarning($"Failed to read Aetheria inventory dropdown surface from managed Verse state: {ex.Message}"); return null; } } diff --git a/Assets/Scripts/UI/Menu/SectorRenderer.cs b/Assets/Scripts/UI/Menu/SectorRenderer.cs index e687c62a8..5195f7413 100644 --- a/Assets/Scripts/UI/Menu/SectorRenderer.cs +++ b/Assets/Scripts/UI/Menu/SectorRenderer.cs @@ -137,7 +137,7 @@ public class SectorRenderer : MonoBehaviour, IBeginDragHandler, IDragHandler, IS } catch (Exception ex) { - Debug.LogWarning($"Failed to read Aetheria sector zone details surface from local Verse state: {ex.Message}"); + Debug.LogWarning($"Failed to read Aetheria sector zone details surface from managed Verse state: {ex.Message}"); return null; } } @@ -165,7 +165,7 @@ public class SectorRenderer : MonoBehaviour, IBeginDragHandler, IDragHandler, IS } catch (Exception ex) { - Debug.LogWarning($"Failed to read Aetheria sector current zone from local Verse state: {ex.Message}"); + Debug.LogWarning($"Failed to read Aetheria sector current zone from managed Verse state: {ex.Message}"); return null; } } diff --git a/Packages/org.gamecult.aetheria.state/Runtime/AetheriaClient.cs b/Packages/org.gamecult.aetheria.state/Runtime/AetheriaClient.cs index 967db3d41..6c36632d7 100644 --- a/Packages/org.gamecult.aetheria.state/Runtime/AetheriaClient.cs +++ b/Packages/org.gamecult.aetheria.state/Runtime/AetheriaClient.cs @@ -64,7 +64,7 @@ namespace GameCult.Aetheria.State.Verse if (!stateBoot.SupportsLocalStateFileRead || !stateBoot.StateFileExists) { throw new InvalidOperationException( - $"Aetheria local client requires a readable local Verse state file: {stateBoot.FailureMessage}"); + $"Aetheria client requires a readable managed Verse target: {stateBoot.FailureMessage}"); } return OpenAsync( diff --git a/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeClientTargetSurfaceBuilder.cs b/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeClientTargetSurfaceBuilder.cs index afa02ed62..cb58ad3d4 100644 --- a/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeClientTargetSurfaceBuilder.cs +++ b/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeClientTargetSurfaceBuilder.cs @@ -197,7 +197,7 @@ namespace GameCult.Aetheria.State.Verse new[] { ("title", "Ownership") }, Text( "aetheria.clientTarget.host.note", - "Client target edits are local. Visibility changes append provider-owned Eve requests against the selected local Verse state file."))), + "Client target edits persist through the managed target document. Visibility changes append provider-owned Eve requests against the selected Verse target."))), Array.Empty()), commands: new[] { diff --git a/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeDaemonRenderQueries.cs b/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeDaemonRenderQueries.cs index d31b4ec36..51a7c66f6 100644 --- a/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeDaemonRenderQueries.cs +++ b/Packages/org.gamecult.aetheria.state/Runtime/AetheriaRuntimeDaemonRenderQueries.cs @@ -16,7 +16,7 @@ namespace GameCult.Aetheria.State.Verse } /// - /// Unity XZ viewport boundary for callers that still present the world through Unity axes. + /// Horizontal X/Z viewport boundary for callers projecting the world into a two-dimensional surface. /// public readonly struct AetheriaRuntimeXzRect {