Use reactive catalog document in zone renderer
This commit is contained in:
parent
bf9c3fa501
commit
9fd1c44cee
2 changed files with 12 additions and 8 deletions
|
|
@ -7816,13 +7816,9 @@ static void RequireUnitySharedDocumentAccessorErgonomics(string root)
|
|||
"ZoneRenderer.cs"));
|
||||
var requiredZoneRendererSharedDocumentSymbols = new[]
|
||||
{
|
||||
"AetheriaRuntimeCatalogSession _catalog",
|
||||
"AetheriaRuntimeZoneContactsSession _zoneContacts",
|
||||
"ResolveClient().State.ObserveCatalog()",
|
||||
"ResolveClient().State.ObserveZoneContacts()",
|
||||
"_catalog?.Dispose()",
|
||||
"_zoneContacts?.Dispose()",
|
||||
"_catalog?.Current",
|
||||
"_zoneContacts?.Current",
|
||||
"private void OnDestroy()"
|
||||
};
|
||||
|
|
@ -7836,11 +7832,18 @@ static void RequireUnitySharedDocumentAccessorErgonomics(string root)
|
|||
string.Join(", ", missingZoneRendererSharedDocumentSymbols));
|
||||
}
|
||||
|
||||
RequireReactiveTypedDocumentAccess(
|
||||
zoneRenderer,
|
||||
"ZoneRenderer",
|
||||
"AetheriaRuntimeCatalogSnapshot",
|
||||
"_catalog",
|
||||
"ResolveClient().State.ReactiveCatalog()",
|
||||
"AetheriaRuntimeCatalogSession",
|
||||
"ResolveClient().State.ObserveCatalog()");
|
||||
|
||||
var forbiddenZoneRendererSharedDocumentSymbols = new[]
|
||||
{
|
||||
"CultMeshReactiveDocument<AetheriaRuntimeCatalogSnapshot> _catalog",
|
||||
"CultMeshReactiveDocument<AetheriaRuntimeZoneContactsDocument> _zoneContacts",
|
||||
"ResolveClient().State.ReactiveCatalog()",
|
||||
"ResolveClient().State.ReactiveZoneContacts()"
|
||||
};
|
||||
var zoneRendererRawDocumentHits = forbiddenZoneRendererSharedDocumentSymbols
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ using System.Collections.Generic;
|
|||
using System.Linq;
|
||||
using Cinemachine;
|
||||
using GameCult.Aetheria.State.Verse;
|
||||
using GameCult.Mesh;
|
||||
using UnityEngine;
|
||||
using UnityEngine.Serialization;
|
||||
using Object = UnityEngine.Object;
|
||||
|
|
@ -119,7 +120,7 @@ public class ZoneRenderer : MonoBehaviour
|
|||
private IReadOnlyList<AetheriaRuntimeBodySnapshotCommit> _zoneRenderBodies =
|
||||
Array.Empty<AetheriaRuntimeBodySnapshotCommit>();
|
||||
private string _clientStatePath = "";
|
||||
private AetheriaRuntimeCatalogSession _catalog;
|
||||
private CultMeshReactiveDocument<AetheriaRuntimeCatalogSnapshot> _catalog;
|
||||
private AetheriaRuntimeZoneContactsSession _zoneContacts;
|
||||
private AetheriaRuntimeRtsViewportBounds _objectsViewportBounds;
|
||||
private AetheriaRuntimeObjectsViewportSession _objectsViewport;
|
||||
|
|
@ -1207,7 +1208,7 @@ public class ZoneRenderer : MonoBehaviour
|
|||
|
||||
try
|
||||
{
|
||||
_catalog = ResolveClient().State.ObserveCatalog();
|
||||
_catalog = ResolveClient().State.ReactiveCatalog();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue