컴퓨터 생각 시간을 사람처럼: 컴퓨터마다 다른 빠르기, 고를 게 많을수록 길게, 가끔 멈칫
- defaultBotDelay: 할 게 하나면 0.7~1.3초, 고르면 1.6~3.9초(+12% 확률로 1~3초 멈칫) - botPace: 컴퓨터 id로 고정된 0.7~1.5배 빠르기 - 같은 컴퓨터가 이어서 두는 동작은 절반, 사람과 같은 반응 창은 +1.5초(그대로) - 차례 시간이 있으면 남은 시간의 절반을 넘기지 않음 - e2e(bots) 컴퓨터 응답 대기 8초 → 15초, docs/06 §12 갱신 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -10,6 +10,7 @@ import { SESSION_COOKIE, Sessions } from './auth/sessions';
|
||||
import { Users, toPublicUser } from './auth/users';
|
||||
import { createHttpApp, type HttpDeps } from './http/app';
|
||||
import { RoomManager } from './rooms/manager';
|
||||
import type { BotDelayInput } from './rooms/bots';
|
||||
import { RoomStore } from './rooms/store';
|
||||
import { Replays } from './rooms/replay';
|
||||
import { Gateway, type WsData } from './ws/gateway';
|
||||
@@ -33,7 +34,7 @@ export interface StartOptions {
|
||||
staticDir?: string | null;
|
||||
discordExchange?: HttpDeps['discordExchange'];
|
||||
/** Computer players' thinking time (tests shorten it). */
|
||||
botDelay?: (choices: number, withPeople: boolean) => number;
|
||||
botDelay?: (input: BotDelayInput) => number;
|
||||
/** Upper bound for waiting on Bun's server.stop() (tests shorten it). */
|
||||
stopWaitMs?: number;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user