M9: 게임 26종 30초 요약 카드·[?] 지금 할 수 있는 것 내용
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
117
apps/web/src/games/seotda/help.test.ts
Normal file
117
apps/web/src/games/seotda/help.test.ts
Normal file
@@ -0,0 +1,117 @@
|
||||
import { expect, test } from 'bun:test';
|
||||
import { applyAction, setupGame, usersOf } from '../help-kit.test-util';
|
||||
import { GAMES } from '@bg/games';
|
||||
import { helpNow } from './help';
|
||||
|
||||
const users = usersOf(['A', 'B', 'C']);
|
||||
const view = (s: unknown, who: string | null) => GAMES.seotda!.view(s, who) as any;
|
||||
const nickOf = (id: string) => users[id]!.nickname;
|
||||
|
||||
test('섯다: 내 차례(버튼·족보) / 상대 차례 / 관전', () => {
|
||||
const { state } = setupGame('seotda', 3);
|
||||
const turn = view(state, null).toAct as string;
|
||||
const other = ['A', 'B', 'C'].find((id) => id !== turn)!;
|
||||
|
||||
const mine = helpNow(view(state, turn), turn, users);
|
||||
expect(mine).toContain('내 차례예요');
|
||||
expect(mine).toContain('첫 베팅');
|
||||
expect(mine).toContain('[다이]');
|
||||
expect(mine).toContain('[체크]');
|
||||
expect(mine).toContain('[삥]');
|
||||
expect(mine).not.toContain('[콜]');
|
||||
expect(mine).toContain('월 한 장만 받았어요');
|
||||
|
||||
const waiting = helpNow(view(state, other), other, users);
|
||||
expect(waiting).toContain(`${nickOf(turn)}님 차례예요(첫 베팅)`);
|
||||
expect(waiting).toContain('기다려 주세요');
|
||||
|
||||
const spec = helpNow(view(state, null), null, users);
|
||||
expect(spec).toContain(`${nickOf(turn)}님 차례예요`);
|
||||
expect(spec).toContain('모인 칩');
|
||||
expect(spec).not.toContain('내 족보');
|
||||
expect(spec).not.toContain('월 한 장');
|
||||
|
||||
// After a 삥 the next player sees [콜] with the amount to match.
|
||||
const s2 = applyAction('seotda', state, turn, { type: 'ping' });
|
||||
const next = view(s2, null).toAct as string;
|
||||
const t = helpNow(view(s2, next), next, users);
|
||||
expect(t).toContain('[콜]');
|
||||
expect(t).toContain('[따당]');
|
||||
expect(t).toContain('[콜]은 그만큼(10 칩) 맞추는');
|
||||
});
|
||||
|
||||
test('섯다: 2장째를 받으면 지금 내 족보와 마지막 베팅, 족보 숨기기 옵션', () => {
|
||||
let { state } = setupGame('seotda', 2);
|
||||
for (let i = 0; i < 2; i++) state = applyAction('seotda', state, view(state, null).toAct, { type: 'check' });
|
||||
const v = view(state, null);
|
||||
expect(v.street).toBe(1);
|
||||
const t = helpNow(view(state, v.toAct), v.toAct, users);
|
||||
expect(t).toContain('마지막 베팅');
|
||||
expect(t).toMatch(/지금 내 족보: .+\(|예요\./);
|
||||
|
||||
const off = setupGame('seotda', 2, { hints: false }).state;
|
||||
const p = view(off, null).toAct as string;
|
||||
expect(helpNow(view(off, p), p, users)).toContain("'족보표'를 보고");
|
||||
});
|
||||
|
||||
test('섯다: 3장 섯다 고르기 단계', () => {
|
||||
let { state } = setupGame('seotda', 3, { cardMode: 'three' });
|
||||
while (view(state, null).handPhase === 'betting') state = applyAction('seotda', state, view(state, null).toAct, { type: 'check' });
|
||||
expect(view(state, null).handPhase).toBe('choose');
|
||||
const t = helpNow(view(state, 'A'), 'A', users);
|
||||
expect(t).toContain('2장을 눌러 고르면');
|
||||
expect(t).toContain('정하기');
|
||||
expect(t).toContain('[추천 조합]');
|
||||
expect(helpNow(view(state, null), null, users)).toContain('몰래 고르는 중');
|
||||
|
||||
const v = view(state, 'A');
|
||||
const s2 = applyAction('seotda', state, 'A', { type: 'choose', cardIds: v.myCombos[0].cardIds });
|
||||
expect(helpNow(view(s2, 'A'), 'A', users)).toContain('골랐어요');
|
||||
});
|
||||
|
||||
test('섯다: 모두 다이 → 판 결과와 [다음 판으로], 다이한 사람', () => {
|
||||
let { state } = setupGame('seotda', 3);
|
||||
const first = view(state, null).toAct as string;
|
||||
state = applyAction('seotda', state, first, { type: 'die' });
|
||||
expect(helpNow(view(state, first), first, users)).toContain('이번 판은 다이했어요');
|
||||
state = applyAction('seotda', state, view(state, null).toAct, { type: 'die' });
|
||||
expect(view(state, null).handPhase).toBe('handEnd');
|
||||
const t = helpNow(view(state, 'A'), 'A', users);
|
||||
expect(t).toContain('모두 다이해서');
|
||||
expect(t).toContain('[다음 판으로]');
|
||||
});
|
||||
|
||||
test('섯다: 칩 다시 받기 / 구사 재경기 참가 / 재경기 표시', () => {
|
||||
const { state } = setupGame('seotda', 3);
|
||||
const rebuy = structuredClone(state);
|
||||
rebuy.phase = 'rebuy';
|
||||
rebuy.hand = null;
|
||||
rebuy.rebuyPending = ['B'];
|
||||
rebuy.seats.find((s: any) => s.id === 'B').status = 'busted';
|
||||
rebuy.seats.find((s: any) => s.id === 'B').stack = 0;
|
||||
const b = helpNow(view(rebuy, 'B'), 'B', users);
|
||||
expect(b).toContain('[칩 다시 받기]');
|
||||
expect(b).toContain('[그만하기]');
|
||||
expect(helpNow(view(rebuy, 'A'), 'A', users)).toContain('고양이님이 칩을 다시 받을지');
|
||||
|
||||
const rejoin = structuredClone(state);
|
||||
rejoin.hand.phase = 'rejoin';
|
||||
rejoin.hand.rejoinPending = ['C'];
|
||||
rejoin.hand.rejoinCost = 50;
|
||||
expect(helpNow(view(rejoin, 'C'), 'C', users)).toContain('[50 칩 내고 참가]');
|
||||
expect(helpNow(view(rejoin, 'A'), 'A', users)).toContain('다시 들어올지');
|
||||
|
||||
const re = structuredClone(state);
|
||||
re.hand.rematchNo = 1;
|
||||
re.hand.rematchReason = 'gusa';
|
||||
expect(helpNow(view(re, null), null, users)).toContain('재경기 1회차(구사)');
|
||||
});
|
||||
|
||||
test('섯다: 게임 끝', () => {
|
||||
const { state } = setupGame('seotda', 2);
|
||||
const end = structuredClone(state);
|
||||
end.phase = 'finished';
|
||||
end.hand = null;
|
||||
end.final = { ranking: [['A'], ['B']], scores: { A: 10, B: -10 }, summary: '20판 끝. 1위 +10칩' };
|
||||
expect(helpNow(view(end, 'A'), 'A', users)).toContain('게임이 끝났어요. 20판 끝');
|
||||
});
|
||||
160
apps/web/src/games/seotda/help.ts
Normal file
160
apps/web/src/games/seotda/help.ts
Normal file
@@ -0,0 +1,160 @@
|
||||
/** 섯다 [?] "지금 할 수 있는 것" (docs/07 §5). Pure: only reads the client view (never other players' cards). */
|
||||
import type { BetType, SeotdaSeatView, SeotdaView } from '@bg/games/seotda';
|
||||
import type { PublicUser } from '@bg/shared/lite';
|
||||
|
||||
/** Same order and labels as the bet buttons in index.tsx. */
|
||||
const BET_ORDER: BetType[] = ['die', 'check', 'ping', 'call', 'ddadang', 'quarter', 'half', 'full'];
|
||||
const BET_KO: Record<BetType, string> = { check: '체크', ping: '삥', call: '콜', ddadang: '따당', quarter: '쿼터', half: '하프', full: '풀', die: '다이' };
|
||||
const RAISES: BetType[] = ['ping', 'ddadang', 'quarter', 'half', 'full'];
|
||||
const STRENGTH_KO = { high: '센 패', mid: '중간 패', low: '약한 패' } as const;
|
||||
const REMATCH_KO = { gusa: '구사', mungGusa: '멍텅구리구사', tie: '같은 족보(동점)' } as const;
|
||||
const REASON_KO = { gusa: '구사', mungGusa: '멍텅구리구사', tie: '동점' } as const;
|
||||
|
||||
const chips = (n: number) => `${Math.max(0, Math.round(n)).toLocaleString('ko-KR')} 칩`;
|
||||
|
||||
function who(players: Record<string, PublicUser>, id: string): string {
|
||||
return `${players[id]?.nickname ?? '다른 사람'}님`;
|
||||
}
|
||||
|
||||
/** Which betting round this is, in plain words. */
|
||||
function roundText(v: SeotdaView): string {
|
||||
const o = v.options;
|
||||
if (o.cardMode === 'three')
|
||||
return v.street === 0
|
||||
? '2장을 받고 하는 첫 베팅이에요. 끝나면 1장을 더 받아 3장 중 쓸 2장을 골라요.'
|
||||
: '고른 2장으로 하는 마지막 베팅이에요. 끝나면 남은 사람끼리 패를 공개해요.';
|
||||
if (o.dealMode === 'oneRound') return '2장을 받고 한 번만 베팅해요. 끝나면 남은 사람끼리 패를 공개해요.';
|
||||
return v.street === 0
|
||||
? '1장을 받고 하는 첫 베팅이에요. 끝나면 1장을 더 받아요.'
|
||||
: '2장째를 받고 하는 마지막 베팅이에요. 끝나면 남은 사람끼리 패를 공개해요.';
|
||||
}
|
||||
|
||||
/** My current hand as the view gives it (hints option on). */
|
||||
function handLine(v: SeotdaView, seat: SeotdaSeatView): string {
|
||||
const h = v.myHand;
|
||||
if (!h) return seat.cards.length > 0 ? "이 방은 족보 이름을 따로 보여 주지 않아요. '족보표'를 보고 내 패를 맞춰 보세요." : '';
|
||||
if (h.special) return h.hint;
|
||||
if (h.value === null) return `지금은 ${h.name}만 받았어요. ${h.hint}`;
|
||||
return `지금 내 족보: ${h.name}${h.strength ? `(${STRENGTH_KO[h.strength]})` : ''}. 족보표에 '내 패'로 표시돼요.`;
|
||||
}
|
||||
|
||||
function rematchLine(v: SeotdaView): string {
|
||||
if (v.rematchNo === 0 || !v.rematchReason) return '';
|
||||
return `재경기 ${v.rematchNo}회차(${REMATCH_KO[v.rematchReason]})예요. 모인 칩은 그대로 두고, 학교(기본 칩)는 다시 내지 않아요.`;
|
||||
}
|
||||
|
||||
function resultLine(v: SeotdaView, players: Record<string, PublicUser>): string {
|
||||
if (v.foldWin) return `모두 다이해서 ${who(players, v.foldWin.winner)}이 ${chips(v.foldWin.amount)}을 가져갔어요. 이때는 패를 공개하지 않아요.`;
|
||||
if (!v.showdown) return '이번 판이 끝났어요.';
|
||||
return v.showdown.pots
|
||||
.map((p) => {
|
||||
const names = p.winners.map((id) => players[id]?.nickname ?? '다른 사람').join('·') + '님';
|
||||
const name = v.showdown!.hands.find((h) => h.id === p.winners[0])?.name ?? '';
|
||||
if (p.type === 'rematch') return `${REASON_KO[p.reason as keyof typeof REASON_KO] ?? '동점'} 재경기: ${names}이 다시 겨뤄요. 모인 칩은 그대로 남아요.`;
|
||||
if (p.type === 'split') return `${names}이 ${chips(p.amount)}을 나눠 가졌어요.`;
|
||||
return `${names}이 ${name ? `${name}(으)로 ` : ''}${chips(p.amount)}을 가져갔어요.`;
|
||||
})
|
||||
.join('\n');
|
||||
}
|
||||
|
||||
function waitingLine(v: SeotdaView, players: Record<string, PublicUser>): string {
|
||||
if (v.handPhase === 'betting') {
|
||||
const oneRound = v.options.cardMode === 'two' && v.options.dealMode === 'oneRound';
|
||||
const round = oneRound ? '베팅' : v.street === 0 ? '첫 베팅' : '마지막 베팅';
|
||||
return v.toAct ? `${who(players, v.toAct)} 차례예요(${round}).` : '카드를 나눠 주는 중이에요.';
|
||||
}
|
||||
if (v.handPhase === 'choose') return '모두 3장 중 쓸 2장을 몰래 고르는 중이에요. 다 고르면 마지막 베팅을 해요.';
|
||||
if (v.handPhase === 'rejoin') return '구사 재경기 전에, 다이했던 사람이 다시 들어올지 고르는 중이에요.';
|
||||
if (v.handPhase === 'handEnd') return resultLine(v, players);
|
||||
return '잠시만 기다려 주세요.';
|
||||
}
|
||||
|
||||
/** Spectators, eliminated or left players: describe the table neutrally (no hidden cards). */
|
||||
function watching(v: SeotdaView, players: Record<string, PublicUser>, prefix = ''): string {
|
||||
if (v.phase === 'rebuy') {
|
||||
const ids = v.rebuy?.pending ?? [];
|
||||
const names = ids.length ? ids.map((id) => players[id]?.nickname ?? '다른 사람').join('·') + '님이' : '칩을 모두 잃은 사람이';
|
||||
return `${prefix}${names} 칩을 다시 받을지 고르는 중이에요.`;
|
||||
}
|
||||
return [prefix + waitingLine(v, players), v.handPhase === 'betting' ? `모인 칩은 ${chips(v.pot)}이에요.` : '', rematchLine(v)].filter(Boolean).join('\n');
|
||||
}
|
||||
|
||||
function myBetting(v: SeotdaView, seat: SeotdaSeatView): string {
|
||||
const legal = new Map(v.legal.map((l) => [l.type, l]));
|
||||
const buttons = BET_ORDER.filter((t) => (t !== 'full' || v.options.maxRaise === 'full') && legal.has(t));
|
||||
const lines = [`내 차례예요. ${roundText(v)}`];
|
||||
const hand = handLine(v, seat);
|
||||
if (hand) lines.push(hand);
|
||||
lines.push(`누를 수 있는 버튼: ${buttons.map((t) => `[${BET_KO[t]}]`).join(' ')}. 버튼 아래 적힌 만큼 칩이 바로 나가요.`);
|
||||
const tips: string[] = [];
|
||||
const call = legal.get('call');
|
||||
if (call) tips.push(`앞사람이 칩을 걸었어요. [콜]은 그만큼(${chips(call.amount)}) 맞추는 거예요.`);
|
||||
else if (legal.has('ping')) tips.push(`[체크]는 칩을 걸지 않고 넘기고, [삥]은 학교(기본 칩)만큼 ${chips(v.baseUnit)}을 걸어요.`);
|
||||
if (!buttons.some((t) => RAISES.includes(t)) && seat.lastAction) tips.push('이번 라운드에 이미 한 번 해서 더 올릴 수는 없어요(올리기는 한 라운드에 한 번).');
|
||||
if (v.legal.some((l) => l.allIn)) tips.push('칩이 모자라면 가진 칩을 다 내는 올인이 돼요.');
|
||||
tips.push('패가 약하면 [다이]로 이번 판을 포기할 수 있어요.');
|
||||
lines.push(tips.join(' '));
|
||||
return lines.join('\n');
|
||||
}
|
||||
|
||||
export function helpNow(v: SeotdaView, me: string | null, players: Record<string, PublicUser>): string {
|
||||
if (v.phase === 'finished') return `게임이 끝났어요. ${v.result?.summary ?? ''}`.trim() + "\n'최종 순위'에서 순위를 볼 수 있어요. 결과 창에서 [한 판 더]를 누르면 다시 할 수 있어요.";
|
||||
const seat = me ? v.seats.find((s) => s.id === me) : undefined;
|
||||
if (!seat) return watching(v, players);
|
||||
if (seat.status === 'eliminated') return watching(v, players, '나는 탈락해서 구경만 할 수 있어요.\n');
|
||||
if (seat.left) return watching(v, players, '게임에서 나갔어요.\n');
|
||||
|
||||
if (v.phase === 'rebuy') {
|
||||
if (!v.rebuy?.mine) return watching(v, players) + ' 잠시 기다려 주세요.';
|
||||
const left = v.rebuy.left !== null ? `(남은 횟수 ${v.rebuy.left}번)` : '';
|
||||
return [
|
||||
`칩을 모두 잃었어요. [칩 다시 받기]를 누르면 놀이용 칩 ${chips(v.options.startingChips)}을 다시 받고 계속해요${left}.`,
|
||||
'[그만하기]를 누르면 탈락하고 구경만 해요. 다시 받은 만큼 최종 점수에서 빠져요.',
|
||||
'시간 안에 고르지 않으면 그만하는 것으로 처리돼요.',
|
||||
].join('\n');
|
||||
}
|
||||
|
||||
const notIn = v.rematchNo > 0 ? '이번 재경기에는 참가하지 않아요. 끝날 때까지 기다려 주세요.' : '이번 판에는 참가하지 않아요. 다음 판을 기다려 주세요.';
|
||||
switch (v.handPhase) {
|
||||
case 'betting': {
|
||||
const re = rematchLine(v);
|
||||
if (!seat.inHand) return [notIn, watching(v, players)].join('\n');
|
||||
if (seat.folded) return `이번 판은 다이했어요. 다음 판을 기다려 주세요. 내 패는 나만 볼 수 있어요.\n${waitingLine(v, players)}`;
|
||||
if (v.toAct === me) return [re, myBetting(v, seat)].filter(Boolean).join('\n');
|
||||
const hand = handLine(v, seat);
|
||||
if (seat.allIn) return ['올인했어요(가진 칩을 다 걸었어요). 더 걸지 않고 결과를 기다리면 돼요.', hand, re].filter(Boolean).join('\n');
|
||||
return [`${waitingLine(v, players)} 내 차례가 올 때까지 기다려 주세요.`, hand, re].filter(Boolean).join('\n');
|
||||
}
|
||||
case 'choose': {
|
||||
if (seat.chosen === null) return seat.folded ? '이번 판은 다이했어요. 다음 판을 기다려 주세요.' : [notIn, watching(v, players)].join('\n');
|
||||
if (seat.chosen) {
|
||||
const name = v.myHand ? `(${v.myHand.name})` : '';
|
||||
return `쓸 카드 2장을 골랐어요${name}. 다른 사람이 다 고를 때까지 기다려 주세요. 다 고르면 마지막 베팅을 해요.`;
|
||||
}
|
||||
const lines = ["3장 중 쓸 카드 2장을 눌러 고르면 아래 버튼이 '○○(으)로 정하기'로 바뀌어요. 그 버튼을 눌러 정해 주세요. 남는 1장은 아무에게도 보이지 않아요."];
|
||||
const best = v.options.hints ? v.myCombos?.find((c) => c.best) : undefined;
|
||||
if (best) lines.push(`[추천 조합]을 누르면 가장 센 조합(${best.name})이 골라져요.`);
|
||||
lines.push('모두 동시에 몰래 고르고, 시간이 지나면 가장 센 조합으로 저절로 골라져요.');
|
||||
return lines.join('\n');
|
||||
}
|
||||
case 'rejoin': {
|
||||
if (!v.rejoin?.mine) return `${waitingLine(v, players)} 잠시 기다려 주세요.`;
|
||||
const cost = chips(v.rejoin.cost);
|
||||
return [
|
||||
`구사 재경기가 열려요. 다이했던 나도 모인 칩에 ${cost}을 더 내면 다시 들어갈 수 있어요.`,
|
||||
v.rejoin.canAfford ? `[${cost} 내고 참가] 또는 [참가 안 함]을 눌러 주세요.` : '칩이 모자라서 참가할 수 없어요. [참가 안 함]을 눌러 주세요.',
|
||||
'시간이 지나면 참가하지 않는 것으로 처리돼요.',
|
||||
].join('\n');
|
||||
}
|
||||
case 'handEnd': {
|
||||
const lines = [resultLine(v, players)];
|
||||
if (seat.status === 'playing') {
|
||||
const label = v.next === 'rematch' ? '재경기 시작' : '다음 판으로';
|
||||
lines.push(seat.ready ? '다른 사람을 기다리는 중이에요.' : `[${label}] 버튼을 누르거나 잠시 기다리면 넘어가요.`);
|
||||
}
|
||||
return lines.join('\n');
|
||||
}
|
||||
default:
|
||||
return '잠시만 기다려 주세요.';
|
||||
}
|
||||
}
|
||||
@@ -17,6 +17,8 @@ import { HwatuCard, type HwatuInfo } from '../../components/cards/HwatuCard';
|
||||
import { Chips, PlayChipNotice, formatChips } from '../../components/cards/Chips';
|
||||
import { haptic, sounds } from '../../lib/feedback';
|
||||
import type { BoardProps, GameUI, OptionsProps } from '../types';
|
||||
import { helpNow } from './help';
|
||||
import { quickStart } from './quick';
|
||||
|
||||
const BET_ORDER: BetType[] = ['die', 'check', 'ping', 'call', 'ddadang', 'quarter', 'half', 'full'];
|
||||
const BET_KO: Record<BetType, string> = { check: '체크', ping: '삥', call: '콜', ddadang: '따당', quarter: '쿼터', half: '하프', full: '풀', die: '다이' };
|
||||
@@ -826,6 +828,8 @@ const ui: GameUI<SeotdaView, SeotdaOptions> = {
|
||||
Options,
|
||||
optionsSummary,
|
||||
Rules,
|
||||
quickStart,
|
||||
helpNow,
|
||||
};
|
||||
|
||||
export default ui;
|
||||
|
||||
92
apps/web/src/games/seotda/quick.tsx
Normal file
92
apps/web/src/games/seotda/quick.tsx
Normal file
@@ -0,0 +1,92 @@
|
||||
/** 섯다 30초 규칙 요약 (docs/07 §5). */
|
||||
import type { CSSProperties, ReactNode } from 'react';
|
||||
import { HwatuCard, type HwatuInfo } from '../../components/cards/HwatuCard';
|
||||
import type { QuickCard } from '../types';
|
||||
|
||||
/** Illustration card: month + 광/열끗 (special) or 띠/기러기. Same idea as the 족보표 in index.tsx. */
|
||||
function hw(month: number, special: boolean): HwatuInfo {
|
||||
const gwang = [1, 3, 8].includes(month);
|
||||
const kind: HwatuInfo['kind'] = special ? (gwang ? 'gwang' : 'yeol') : month === 8 ? 'pi' : 'tti';
|
||||
return {
|
||||
id: (month - 1) * 4 + (special ? 0 : 1),
|
||||
month,
|
||||
kind,
|
||||
...(kind === 'tti' ? { tti: 'plain' as const } : {}),
|
||||
name: `${month}월 ${special ? (gwang ? '광' : '열끗') : month === 8 ? '기러기' : '띠'}`,
|
||||
};
|
||||
}
|
||||
|
||||
function Pair({ a, b, label, size = 'sm' }: { a: [number, boolean]; b: [number, boolean]; label: string; size?: 'sm' | 'md' }) {
|
||||
return (
|
||||
<div style={{ display: 'flex', flexDirection: 'column', alignItems: 'center', gap: 4 }}>
|
||||
<div style={{ display: 'flex' }}>
|
||||
<HwatuCard card={hw(...a)} size={size} />
|
||||
<HwatuCard card={hw(...b)} size={size} style={{ marginLeft: size === 'md' ? 4 : -10 }} />
|
||||
</div>
|
||||
<strong style={{ fontSize: size === 'md' ? '1.1rem' : '0.85rem', whiteSpace: 'nowrap' }}>{label}</strong>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
function Row({ children, gap = 10 }: { children: ReactNode; gap?: number }) {
|
||||
return <div style={{ display: 'flex', alignItems: 'center', justifyContent: 'center', gap, maxWidth: 260 }}>{children}</div>;
|
||||
}
|
||||
|
||||
const btn = (bg: string): CSSProperties => ({
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
minWidth: 74,
|
||||
height: 40,
|
||||
borderRadius: 10,
|
||||
background: bg,
|
||||
color: '#fff',
|
||||
fontWeight: 800,
|
||||
fontSize: '1.05rem',
|
||||
});
|
||||
|
||||
function Buttons() {
|
||||
return (
|
||||
<div style={{ display: 'grid', gridTemplateColumns: 'repeat(2, 1fr)', gap: 8, width: 170 }} aria-hidden>
|
||||
<span style={btn('#dc2626')}>다이</span>
|
||||
<span style={btn('#2563eb')}>체크</span>
|
||||
<span style={btn('#2563eb')}>콜</span>
|
||||
<span style={btn('#7c3aed')}>하프</span>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
const gt = <span style={{ fontSize: '1.3rem', fontWeight: 900 }}>></span>;
|
||||
|
||||
export const quickStart: QuickCard[] = [
|
||||
{
|
||||
pic: (
|
||||
<Row>
|
||||
<Pair a={[3, true]} b={[8, true]} label="38광땡" size="md" />
|
||||
</Row>
|
||||
),
|
||||
alt: '3월 광과 8월 광 화투 두 장이 놓여 있고 38광땡이라고 적혀 있어요',
|
||||
title: '2장 조합이 센 사람이 이겨요',
|
||||
text: '화투 2장의 조합(족보)을 겨뤄요. 가장 센 족보를 가진 사람이 가운데 모인 칩을 모두 가져가요.',
|
||||
},
|
||||
{
|
||||
pic: <Buttons />,
|
||||
alt: '다이, 체크, 콜, 하프라고 적힌 버튼 네 개가 있어요',
|
||||
title: '차례가 오면 칩을 걸어요',
|
||||
text: '[체크]·[콜]·[하프] 같은 버튼으로 칩을 걸고, 패가 약하면 [다이]로 이번 판을 포기해요. 다른 사람이 다 다이하면 내가 가져가요.',
|
||||
},
|
||||
{
|
||||
pic: (
|
||||
<Row gap={6}>
|
||||
<Pair a={[10, true]} b={[10, false]} label="장땡" />
|
||||
{gt}
|
||||
<Pair a={[1, true]} b={[2, false]} label="알리" />
|
||||
{gt}
|
||||
<Pair a={[3, false]} b={[5, false]} label="8끗" />
|
||||
</Row>
|
||||
),
|
||||
alt: '장땡, 알리, 8끗 순서로 화투 두 장씩 놓여 있고 사이에 큰 쪽 표시가 있어요',
|
||||
title: '땡 > 알리 > 끗 순서예요',
|
||||
text: "광땡 > 땡(같은 달 2장) > 알리·독사 등 > 끗(두 달을 더한 일의 자리) 순으로 세요. 화면의 '족보표'를 보면 쉬워요.",
|
||||
},
|
||||
];
|
||||
Reference in New Issue
Block a user