Own Continue current entity by typed state key
This commit is contained in:
parent
c0aec84af4
commit
4ee0628a5a
12 changed files with 114 additions and 22 deletions
|
|
@ -1904,6 +1904,8 @@ static void RequireMainMenuContinueRunState(string root)
|
|||
"RestoreEntityGraphFromTypedRun(continuingRun)",
|
||||
"ReadEntitySnapshots(RuntimeStateFilePath)",
|
||||
"entity.RecordKey",
|
||||
"run.CurrentEntityKey",
|
||||
"ResolveCurrentEntityRecordKey(run, zoneEntityKeyPrefix)",
|
||||
"ReplaceZoneEntitiesFromTypedSnapshots",
|
||||
"Zone.Agents.Clear()",
|
||||
"FlattenEntityGraph(Zone)",
|
||||
|
|
@ -1937,6 +1939,23 @@ static void RequireMainMenuContinueRunState(string root)
|
|||
string.Join(", ", missingGameplaySymbols));
|
||||
}
|
||||
|
||||
var forbiddenGameplaySymbols = new[]
|
||||
{
|
||||
"if (run == null ||\r\n run.CurrentZoneIndex < 0 ||\r\n run.CurrentZoneEntityIndex < 0)",
|
||||
"var currentEntityKey = $\"{zoneEntityKeyPrefix}{run.CurrentZoneEntityIndex}.v1\""
|
||||
};
|
||||
|
||||
var forbiddenGameplayHits = forbiddenGameplaySymbols
|
||||
.Where(symbol => actionGameManager.Contains(symbol, StringComparison.Ordinal))
|
||||
.ToArray();
|
||||
|
||||
if (forbiddenGameplayHits.Length > 0)
|
||||
{
|
||||
throw new InvalidOperationException(
|
||||
"ActionGameManager still reconstructs Continue current-entity ownership from integer slot state: " +
|
||||
string.Join(", ", forbiddenGameplayHits));
|
||||
}
|
||||
|
||||
var requiredPackageSymbols = new[]
|
||||
{
|
||||
"public string RecordKey",
|
||||
|
|
|
|||
Loading…
Reference in a new issue