You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
AdLike2048/assets/script/battle/IBattleService.ts

24 lines
821 B

import type { Player } from '../game/Player';
import type { TableBattleConfigProvider } from './config/TableBattleConfigProvider';
import type {
BattleDeployParams,
BattleStartParams,
IBattleRuntimeHandle,
} from './types/ProjectBattleTypes';
/** 战斗模块对外契约:业务层只通过 gg.battle 访问 */
export interface IBattleService {
readonly config: TableBattleConfigProvider;
readonly match: IBattleRuntimeHandle | null;
readonly localPlayer: Player | undefined;
readonly players: readonly Player[];
readonly remotePlayer: Player | undefined;
init(): void;
start(params: BattleStartParams): IBattleRuntimeHandle | null;
end(): void;
tick(dt: number): void;
deploy(params: BattleDeployParams): boolean;
startCombat(): void;
startPrep(): void;
}