chore(merge): 合并 develop 并整合 Day2 梦境剧情与演出
This commit is contained in:
@@ -142,10 +142,27 @@ namespace AibisDream
|
||||
details = string.Empty;
|
||||
|
||||
RestoreResult result = null;
|
||||
yield return SaveRestoreOrchestrator.RestoreFromFile(
|
||||
var completed = false;
|
||||
var accepted = GameManager.Instance.TryRestoreFile(
|
||||
entry.SnapshotPathWithoutExtension,
|
||||
RestoreOptions.DevJump,
|
||||
value => result = value);
|
||||
value =>
|
||||
{
|
||||
result = value;
|
||||
completed = true;
|
||||
});
|
||||
|
||||
if (!accepted)
|
||||
{
|
||||
status = $"跳转失败:{entry.Label}(当前存在其他会话命令)";
|
||||
isJumping = false;
|
||||
yield break;
|
||||
}
|
||||
|
||||
while (!completed)
|
||||
{
|
||||
yield return null;
|
||||
}
|
||||
|
||||
if (result?.Success == true)
|
||||
{
|
||||
@@ -181,14 +198,20 @@ namespace AibisDream
|
||||
status = $"冒烟测试 {i + 1}/{entries.Count}:{entry.Label}";
|
||||
RestoreResult result = null;
|
||||
var completed = false;
|
||||
var routine = StartCoroutine(SaveRestoreOrchestrator.RestoreFromFile(
|
||||
var accepted = GameManager.Instance.TryRestoreFile(
|
||||
entry.SnapshotPathWithoutExtension,
|
||||
RestoreOptions.DevJump,
|
||||
value =>
|
||||
{
|
||||
result = value;
|
||||
completed = true;
|
||||
}));
|
||||
});
|
||||
|
||||
if (!accepted)
|
||||
{
|
||||
failures.Add($"{entry.Label}: 当前存在其他会话命令");
|
||||
break;
|
||||
}
|
||||
|
||||
const float timeoutSeconds = 60f;
|
||||
var elapsed = 0f;
|
||||
@@ -200,7 +223,7 @@ namespace AibisDream
|
||||
|
||||
if (!completed)
|
||||
{
|
||||
StopCoroutine(routine);
|
||||
GameManager.Instance.TryReturnToMainMenu();
|
||||
failures.Add($"{entry.Label}: 超过 {timeoutSeconds:0} 秒");
|
||||
break;
|
||||
}
|
||||
@@ -378,11 +401,6 @@ namespace AibisDream
|
||||
|
||||
try
|
||||
{
|
||||
if (SnapshotPersistence.IsLegacyFormat(SnapshotPathWithoutExtension))
|
||||
{
|
||||
Error = "不支持旧格式存档";
|
||||
return;
|
||||
}
|
||||
Snapshot = SnapshotPersistence.Load(SnapshotPathWithoutExtension);
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
Reference in New Issue
Block a user