M1 기반: 모노레포, 공통 엔진, 공용 프로토콜, 오목 엔진, 서버 골격
- packages/engine: 시드 RNG(sfc32), GameDefinition 타입, 무작위 대국·정보 유출 테스트 도구 - packages/shared: WS 프로토콜 스키마, 닉네임·방 코드 규칙, 게임 카탈로그 - packages/games/omok: 한국식·렌주·자유룰, 재귀 금수 판정, 무르기·무승부·시계 (테스트 27개) - apps/server: SQLite 스키마, 게스트·디스코드 로그인, 세션, 방 관리(저장·복구·타이머·재접속), WS 게이트웨이, HTTP API Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
17
packages/shared/src/catalog.ts
Normal file
17
packages/shared/src/catalog.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
/** Game catalog metadata shared by server and web (docs/games/README.md). */
|
||||
export interface CatalogEntry {
|
||||
id: string;
|
||||
nameKo: string;
|
||||
minPlayers: number;
|
||||
maxPlayers: number;
|
||||
minutes: string;
|
||||
level: '쉬움' | '보통' | '어려움';
|
||||
blurb: string;
|
||||
available: boolean;
|
||||
}
|
||||
|
||||
export const CATALOG: CatalogEntry[] = [
|
||||
{ id: 'omok', nameKo: '오목', minPlayers: 2, maxPlayers: 2, minutes: '5~15', level: '쉬움', blurb: '먼저 다섯 개를 한 줄로!', available: true },
|
||||
];
|
||||
|
||||
export const catalogById = (id: string): CatalogEntry | undefined => CATALOG.find((g) => g.id === id);
|
||||
Reference in New Issue
Block a user