refactor: remove registry from Boop and Regicide index files
This commit is contained in:
parent
2014162819
commit
f5df1c26dc
|
|
@ -1,49 +1,41 @@
|
|||
// Types
|
||||
export type {
|
||||
PlayerType,
|
||||
PieceType,
|
||||
WinnerType,
|
||||
RegionType,
|
||||
BoopPartMeta,
|
||||
BoopPart
|
||||
} from './types';
|
||||
PlayerType,
|
||||
PieceType,
|
||||
WinnerType,
|
||||
RegionType,
|
||||
BoopPartMeta,
|
||||
BoopPart,
|
||||
} from "./types";
|
||||
|
||||
export type {BoopGame} from './types-extensions';
|
||||
export type { BoopGame } from "./types-extensions";
|
||||
|
||||
// Constants
|
||||
export {
|
||||
BOARD_SIZE,
|
||||
MAX_PIECES_PER_PLAYER,
|
||||
WIN_LENGTH
|
||||
} from './constants';
|
||||
export { BOARD_SIZE, MAX_PIECES_PER_PLAYER, WIN_LENGTH } from "./constants";
|
||||
|
||||
// State
|
||||
export {
|
||||
createInitialState,
|
||||
type BoopState
|
||||
} from './state';
|
||||
export { createInitialState, type BoopState } from "./state";
|
||||
|
||||
// Prompts
|
||||
export {prompts} from './prompts';
|
||||
export { prompts } from "./prompts";
|
||||
|
||||
// Commands
|
||||
export {
|
||||
registry,
|
||||
start,
|
||||
place as placeCmd,
|
||||
boop as boopCmd,
|
||||
checkWin as checkWinCmd,
|
||||
checkGraduates as checkGraduatesCmd,
|
||||
checkFullBoard as checkFullBoardCmd,
|
||||
turn as turnCmd
|
||||
} from './commands';
|
||||
start,
|
||||
place as placeCmd,
|
||||
boop as boopCmd,
|
||||
checkWin as checkWinCmd,
|
||||
checkGraduates as checkGraduatesCmd,
|
||||
checkFullBoard as checkFullBoardCmd,
|
||||
turn as turnCmd,
|
||||
} from "./commands";
|
||||
|
||||
// Utils
|
||||
export {
|
||||
getLineCandidates,
|
||||
isInBounds,
|
||||
isCellOccupied,
|
||||
getNeighborPositions,
|
||||
findPartInRegion,
|
||||
findPartAtPosition
|
||||
} from './utils';
|
||||
getLineCandidates,
|
||||
isInBounds,
|
||||
isCellOccupied,
|
||||
getNeighborPositions,
|
||||
findPartInRegion,
|
||||
findPartAtPosition,
|
||||
} from "./utils";
|
||||
|
|
|
|||
|
|
@ -1,67 +1,63 @@
|
|||
// Types
|
||||
export type {
|
||||
SuitType,
|
||||
CardRank,
|
||||
PlayerType,
|
||||
RegionType,
|
||||
RegicideCardMeta,
|
||||
RegicideCard,
|
||||
Enemy,
|
||||
GamePhase
|
||||
} from './types';
|
||||
SuitType,
|
||||
CardRank,
|
||||
PlayerType,
|
||||
RegionType,
|
||||
RegicideCardMeta,
|
||||
RegicideCard,
|
||||
Enemy,
|
||||
GamePhase,
|
||||
} from "./types";
|
||||
|
||||
// Constants
|
||||
export {
|
||||
ENEMY_COUNT,
|
||||
INITIAL_HAND_SIZE,
|
||||
CARD_VALUES,
|
||||
ALL_SUITS,
|
||||
ALL_RANKS,
|
||||
FACE_CARDS,
|
||||
NUMBER_CARDS
|
||||
} from './constants';
|
||||
ENEMY_COUNT,
|
||||
INITIAL_HAND_SIZE,
|
||||
CARD_VALUES,
|
||||
ALL_SUITS,
|
||||
ALL_RANKS,
|
||||
FACE_CARDS,
|
||||
NUMBER_CARDS,
|
||||
} from "./constants";
|
||||
|
||||
// State
|
||||
export {
|
||||
createInitialState,
|
||||
type RegicideState
|
||||
} from './state';
|
||||
export { createInitialState, type RegicideState } from "./state";
|
||||
|
||||
// Prompts
|
||||
export {prompts} from './prompts';
|
||||
export { prompts } from "./prompts";
|
||||
|
||||
// Commands
|
||||
export {
|
||||
registry,
|
||||
play as playCmd,
|
||||
playWithA as playWithACmd,
|
||||
pass as passCmd,
|
||||
enemyCounterattack as enemyCounterattackCmd,
|
||||
checkEnemy as checkEnemyCmd,
|
||||
checkCanPlay as checkCanPlayCmd,
|
||||
checkTavernDeck as checkTavernDeckCmd,
|
||||
nextTurn as nextTurnCmd,
|
||||
} from './commands';
|
||||
play as playCmd,
|
||||
playWithA as playWithACmd,
|
||||
pass as passCmd,
|
||||
enemyCounterattack as enemyCounterattackCmd,
|
||||
checkEnemy as checkEnemyCmd,
|
||||
checkCanPlay as checkCanPlayCmd,
|
||||
checkTavernDeck as checkTavernDeckCmd,
|
||||
nextTurn as nextTurnCmd,
|
||||
} from "./commands";
|
||||
|
||||
// Game
|
||||
export {
|
||||
setupGame,
|
||||
start,
|
||||
playTurn,
|
||||
handleCounterattack,
|
||||
getGameStatus,
|
||||
type RegicideGame
|
||||
} from './game';
|
||||
setupGame,
|
||||
start,
|
||||
playTurn,
|
||||
handleCounterattack,
|
||||
getGameStatus,
|
||||
type RegicideGame,
|
||||
} from "./game";
|
||||
|
||||
// Utils
|
||||
export {
|
||||
getCardValue,
|
||||
createCard,
|
||||
createEnemy,
|
||||
createAllCards,
|
||||
buildEnemyDeck,
|
||||
buildTavernDeck,
|
||||
drawFromDeck,
|
||||
isEnemyDefeated,
|
||||
getPlayerHandRegionId
|
||||
} from './utils';
|
||||
getCardValue,
|
||||
createCard,
|
||||
createEnemy,
|
||||
createAllCards,
|
||||
buildEnemyDeck,
|
||||
buildTavernDeck,
|
||||
drawFromDeck,
|
||||
isEnemyDefeated,
|
||||
getPlayerHandRegionId,
|
||||
} from "./utils";
|
||||
|
|
|
|||
Loading…
Reference in New Issue