From 609cd8b4103d193a5cb2fa789264701f96b8abfe Mon Sep 17 00:00:00 2001 From: EJClaw Date: Thu, 15 Oct 2026 23:49:29 +0900 Subject: [PATCH] =?UTF-8?q?=EC=82=AC=EA=B1=B4=20=ED=8C=8C=EC=9D=BC=20?= =?UTF-8?q?=EA=B2=B0=EA=B3=BC=20=EC=B0=BD:=20=ED=95=A8=EA=BB=98=20?= =?UTF-8?q?=ED=92=80=EA=B8=B0=EB=8A=94=20=EB=AA=A8=EB=91=90=20=EA=B0=99?= =?UTF-8?q?=EC=9D=80=20=EC=88=9C=EC=9C=84=EB=9D=BC=20'=EB=AC=B4=EC=8A=B9?= =?UTF-8?q?=EB=B6=80=EC=98=88=EC=9A=94'=EB=A1=9C=20=EB=82=98=EC=98=A4?= =?UTF-8?q?=EB=8D=98=20=EA=B2=83=EC=9D=84=20'=F0=9F=8E=89=20=EC=82=AC?= =?UTF-8?q?=EA=B1=B4=EC=9D=84=20=ED=95=B4=EA=B2=B0=ED=96=88=EC=96=B4?= =?UTF-8?q?=EC=9A=94!'=20/=20'=EC=82=AC=EA=B1=B4=EC=9D=84=20=ED=92=80?= =?UTF-8?q?=EC=A7=80=20=EB=AA=BB=ED=96=88=EC=96=B4=EC=9A=94'=EB=A1=9C,=20?= =?UTF-8?q?=EC=86=8C=EB=A6=AC=EB=8F=84=20=ED=95=B4=EA=B2=B0=EC=9D=B4?= =?UTF-8?q?=EB=A9=B4=20=EC=9D=B4=EA=B9=80=C2=B7=EC=95=84=EB=8B=88=EB=A9=B4?= =?UTF-8?q?=20=EC=A7=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- apps/web/src/pages/RoomPage.tsx | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/apps/web/src/pages/RoomPage.tsx b/apps/web/src/pages/RoomPage.tsx index 73f6e13..36b82aa 100644 --- a/apps/web/src/pages/RoomPage.tsx +++ b/apps/web/src/pages/RoomPage.tsx @@ -741,12 +741,18 @@ function ResultPanel({ room, me, players, onLeave, onAgain }: { room: RoomView; const allFirst = !solo && result.ranking.length === 1; const won = !solo && !allFirst && result.ranking[0]?.includes(me.id); const lost = !solo && !allFirst && !won && result.ranking.some((g) => g.includes(me.id)); + // 사건 파일 함께 풀기: everyone who stayed shares one rank, so it is solved or not rather than a draw. + const coop = room.gameId === 'case-file' && (room.options as { mode?: string }).mode !== 'race' && result.reason === 'normal' && !!result.ranking[0]?.includes(me.id); + const coopSolved = coop && Object.values(result.scoreText ?? {}).some((t) => t.includes('해결') && !t.includes('미해결')); useEffect(() => { if (played.current) return; played.current = true; - if (won) sounds.win(); + if (coop) { + if (coopSolved) sounds.win(); + else sounds.lose(); + } else if (won) sounds.win(); else if (lost) sounds.lose(); - }, [won, lost]); + }, [won, lost, coop, coopSolved]); if (hidden) { return (
@@ -760,7 +766,7 @@ function ResultPanel({ room, me, players, onLeave, onAgain }: { room: RoomView; } return ( setHidden(true)} label="게임 결과"> -

{allFirst ? '무승부예요' : won ? '🎉 이겼어요!' : lost ? '아쉽게 졌어요' : '게임이 끝났어요'}

+

{coop ? (coopSolved ? '🎉 사건을 해결했어요!' : '사건을 풀지 못했어요') : allFirst ? '무승부예요' : won ? '🎉 이겼어요!' : lost ? '아쉽게 졌어요' : '게임이 끝났어요'}

{result.summary}

{seatedAll.length > seated.length &&

🤖 연습 게임이라 기록에는 남지 않아요.

}