diff options
Diffstat (limited to 'data.ts')
-rw-r--r-- | data.ts | 34 |
1 files changed, 22 insertions, 12 deletions
@@ -1,4 +1,4 @@ -import { Card, Effect, FactionId, Player, StaticData } from './types'; +import { Card, Effect, FactionId, FrontId, Player, StaticData } from './types'; const LIBERTY = 0; const COLLECTIVIZATION = 1; @@ -22,6 +22,7 @@ const NORTHERN = 'n'; const SOUTHERN = 's'; const CLOSEST_TO_DEFEAT = 'd'; const CLOSEST_TO_VICTORY = 'v'; +const FRONTS: FrontId[] = [ARAGON, MADRID, NORTHERN, SOUTHERN]; const TOWARDS_CENTER = 10; const AWAY_FROM_CENTER = 11; @@ -39,7 +40,23 @@ const ANARCHIST = 'Anarchist' as Player; const COMMUNIST = 'Communist' as Player; const MODERATE = 'Moderate' as Player; +const VICTORY = 'Victory'; +const DEFEAT = 'Defeat'; + +function create_effect( + type: Effect['type'], + target: Effect['target'], + value: Effect['value'] +): Effect { + return { + type, + target, + value, + }; +} + export { + create_effect, ANARCHIST, COMMUNIST, MODERATE, @@ -63,19 +80,12 @@ export { SELF, TOWARDS_CENTER, TRASH, + VICTORY, + DEFEAT, + FRONTS, }; -function create_effect( - type: Effect['type'], - target: Effect['target'], - value: Effect['value'] -): Effect { - return { - type, - target, - value, - }; -} + const data: StaticData = { cards: [ |