diff --git a/.voidbot/state/aetheria.cc b/.voidbot/state/aetheria.cc index e38382177..43fb51f2a 100644 Binary files a/.voidbot/state/aetheria.cc and b/.voidbot/state/aetheria.cc differ diff --git a/Assets/Scripts/Gameplay/ActionGameManager.cs b/Assets/Scripts/Gameplay/ActionGameManager.cs index 89aafd6b2..20016ed1b 100644 --- a/Assets/Scripts/Gameplay/ActionGameManager.cs +++ b/Assets/Scripts/Gameplay/ActionGameManager.cs @@ -35,7 +35,7 @@ public class ActionGameManager : MonoBehaviour get => _gameDataDirectory ??= new DirectoryInfo(Application.dataPath).Parent.CreateSubdirectory("GameData"); } - public static string AetheriaStateFilePath => LegacyCatalogBoundary.GetStateFilePath(GameDataDirectory); + public static string AetheriaStateFilePath => AetheriaStateBoundary.GetStateFilePath(GameDataDirectory); private static string LegacyAetherDatabasePath => LegacyCatalogBoundary.GetLegacyCatalogPath(GameDataDirectory); private static ILegacyCatalogReader LegacyCatalog => LegacyCatalogBoundary.GetCatalog(GameDataDirectory); diff --git a/Assets/Scripts/Gameplay/AetheriaStateBoundary.cs b/Assets/Scripts/Gameplay/AetheriaStateBoundary.cs new file mode 100644 index 000000000..1dbb894f1 --- /dev/null +++ b/Assets/Scripts/Gameplay/AetheriaStateBoundary.cs @@ -0,0 +1,11 @@ +using System.IO; + +public static class AetheriaStateBoundary +{ + public const string RuntimeStateFileName = "aetheria-world.cc"; + + public static string GetStateFilePath(DirectoryInfo gameDataDirectory) + { + return Path.Combine(gameDataDirectory.FullName, RuntimeStateFileName); + } +} diff --git a/Assets/Scripts/Gameplay/LegacyCatalogBoundary.cs b/Assets/Scripts/Gameplay/LegacyCatalogBoundary.cs index fe809f94d..00f320083 100644 --- a/Assets/Scripts/Gameplay/LegacyCatalogBoundary.cs +++ b/Assets/Scripts/Gameplay/LegacyCatalogBoundary.cs @@ -4,11 +4,6 @@ public static class LegacyCatalogBoundary { private static LegacyCatalogCache _catalogCache; - public static string GetStateFilePath(DirectoryInfo gameDataDirectory) - { - return Path.Combine(gameDataDirectory.FullName, "aetheria-world.cc"); - } - public static string GetLegacyCatalogPath(DirectoryInfo gameDataDirectory) { return Path.Combine(gameDataDirectory.FullName, "AetherDB.msgpack"); diff --git a/docs/aetheria-perfect-machine-map.md b/docs/aetheria-perfect-machine-map.md index 22ebf38f3..c164cd883 100644 --- a/docs/aetheria-perfect-machine-map.md +++ b/docs/aetheria-perfect-machine-map.md @@ -20,10 +20,13 @@ legacy catalog cache, and legacy UI paths should be migration-only or deleted. - Unity client/runtime lives under `Assets/`. Gameplay still reads the legacy item/name catalog through a private `ActionGameManager` boot helper, which is now the only runtime entrypoint that calls `LegacyCatalogBoundary.GetCatalog`. - `ActionGameManager` no longer owns a global legacy cache. Local run saves, - loadouts, player settings files, zone files, and generated keyboard layout - caches no longer write bespoke durable files. The legacy `PlayerSettings` - runtime object is no longer decorated as a MessagePack persistence shape. + `ActionGameManager` no longer owns a global legacy cache. + `AetheriaStateBoundary` owns the Unity runtime path to + `GameData/aetheria-world.cc`; `LegacyCatalogBoundary` no longer names or owns + typed state paths. Local run saves, loadouts, player settings files, zone + files, and generated keyboard layout caches no longer write bespoke durable + files. The legacy `PlayerSettings` runtime object is no longer decorated as a + MessagePack persistence shape. - Shared domain state is still partly built around `DatabaseEntry`, GUID identity, MessagePack attributes, and static cache references. Newtonsoft, JsonKnownTypes, RethinkDB, LiteNetLib client transport, and the broken @@ -126,6 +129,8 @@ legacy catalog cache, and legacy UI paths should be migration-only or deleted. - `GameData/aetheria-world.cc` is now materialized from the importer as the project-local typed state file for the checked-in catalog. The importer stores relative provenance in the state document, not machine-local absolute paths. + Unity resolves this path through `AetheriaStateBoundary`, not through the + legacy catalog boundary. Import rebuilds clear the generated `.cc`, `.cc.records`, and `.cultmesh` outputs for the selected state path after capturing legacy inputs, so schema evolution can rematerialize typed state instead of being blocked by stale @@ -189,6 +194,7 @@ legacy catalog cache, and legacy UI paths should be migration-only or deleted. ## Current Authority Map - Owner: `Aetheria.State` owns the new typed state spine for durable state. + `AetheriaStateBoundary` owns Unity's runtime typed state file path. `LegacyCatalogBoundary` is the only named owner for opening the old catalog and binding legacy `DatabaseLink` resolution until catalog migration lands. `ActionGameManager` has a private boot helper that calls it only to construct