1
0
mirror of https://github.com/captn3m0/modernart.git synced 2024-07-13 03:27:54 +00:00
modernart/sanity.mzn

32 lines
992 B
MiniZinc
Raw Normal View History

2020-06-10 18:44:01 +00:00
% Sanity check
constraint forall (a in Artists, r in Rounds) (
CardsForArtist[r,a]>=0
2020-06-10 18:44:01 +00:00
);
% So they don't go negative
constraint forall (a in Artists, r in Rounds, p in Players) (
visible_count_per_round_per_artist_per_player[r,p, a]>=0
);
% Score sanity per round
constraint forall (a in Artists, r in Rounds) (
ranking_score_per_artist_per_round[r,a] >=0
);
% No game can have less than 1 Nominal Turn (Number of turns played by the Closing Player)
constraint forall(r in Rounds) (NominalTurnCount[r] >=1);
constraint forall(r in Rounds, p in Players) (
StartingCardsInHand[r,p] >=0
);
2020-06-10 18:44:01 +00:00
% Round 1 Player 1
2020-07-20 21:01:58 +00:00
constraint first_player[Round1] = Player1;
2020-06-10 19:17:54 +00:00
% Visible Cards per round per player for every artist > 0
constraint forall(a in Artists) (
sum(p in Players, r in Rounds) (visible_count_per_round_per_artist_per_player[r,p,a])>=0
);
% This is a 2-5 player game
2020-06-11 10:26:20 +00:00
constraint assert(card(Players) <=5, "Max Players is 5");
constraint assert(card(Players) >=1, "MinPlayers is 2");