feat: 턴 데몬 명령 처리 및 결과 응답 기능 추가

This commit is contained in:
2026-01-04 16:05:22 +00:00
parent b2a625d4e7
commit 2753b85a26
12 changed files with 716 additions and 63 deletions
@@ -248,6 +248,7 @@ export const createDatabaseTurnHooks = async (
cities,
nations,
troops,
deletedTroops,
diplomacy,
logs,
createdGenerals,
@@ -293,6 +294,11 @@ export const createDatabaseTurnHooks = async (
data: createdDiplomacy.map(buildDiplomacyCreate),
});
}
if (deletedTroops.length > 0) {
await prisma.troop.deleteMany({
where: { troopLeaderId: { in: deletedTroops } },
});
}
await Promise.all([
...generals