mirror of https://github.com/captn3m0/modernart.git synced 2024-07-12 09:27:56 +00:00
2020-07-20 17:21:13 +05:30

19 lines
815 B

array[Rounds,Players,Artists] of var bool: DrawOneCard;
% Total Playable Cards for any round are set equal to the Starting Hand
array[Rounds,Players] of var int: PlayableCards;
% Playable Cards in any round = Starting Cards + Draw One cards that give you an extra playable card
constraint forall(p in Players, r in Rounds) (
PlayableCards[r,p] = StartingCardsInHand[r,p] + sum(a in Artists) (DrawOneCard[r,p,a])
% Every artist only has a single Draw One Card
constraint forall(a in Artists) (
sum(p in Players, r in Rounds) (DrawOneCard[r,p,a]) = 1
% Isolated count for DrawOne, you can only play your draw one, if you've atleast played that artist this round
constraint forall(p in Players, r in Rounds, a in Artists) (
visible_count_per_round_per_artist_per_player[r,p,a] >= DrawOneCard[r,p,a]