feat: add playable Zhuo prologue village

This commit is contained in:
2026-07-24 01:33:36 +09:00
parent b7c90c9452
commit df1322b1f0
17 changed files with 2418 additions and 40 deletions

View File

@@ -331,7 +331,8 @@ async function advanceStoryUntilBattle(page, battleId) {
storyReady: story?.ready === true,
storyLastPage: story?.isLastPage === true,
storyTargetsBattle: story?.nextScene === 'BattleScene',
currentPageReady: story?.assetStreaming?.currentPageReady === true
currentPageReady: story?.assetStreaming?.currentPageReady === true,
villageReady: window.__HEROS_DEBUG__?.village?.()?.ready === true
};
} catch {
return {};
@@ -348,6 +349,18 @@ async function advanceStoryUntilBattle(page, battleId) {
return { startedAt, resourceEntries: entries };
}
if (state.villageReady) {
const advanced = await page.evaluate(() => {
const scene = window.__HEROS_GAME__?.scene.getScene('PrologueVillageScene');
return scene?.debugCompleteVillage?.() ?? false;
});
if (!advanced) {
throw new Error('Playable prologue village was ready but could not advance to the departure story.');
}
await page.waitForTimeout(400);
continue;
}
await page.keyboard.press('Space');
await page.waitForTimeout(220);
}