]> git.cworth.org Git - lmno.games/commitdiff
Change category voting to require fewer votes when there are more categories
authorCarl Worth <cworth@cworth.org>
Mon, 29 Jun 2020 21:54:31 +0000 (14:54 -0700)
committerCarl Worth <cworth@cworth.org>
Mon, 29 Jun 2020 21:54:31 +0000 (14:54 -0700)
Now, at the beginning, it's no longer enough for there to be a
majority of votes on a single prompt. Instead, the number of votes
required is the number of players minus the number of available
prompts.

empathy/empathy.jsx

index a9911d760188ba0736a8f8fb1db15057ab97bbc5..b9579a6893e2a9b91ea28f8da34da2182e4c75b9 100644 (file)
@@ -433,7 +433,7 @@ const PromptOptions = React.memo(props => {
 
 const LetsPlay = React.memo(props => {
 
-  const quorum = Math.round((props.num_players + 1) / 2);
+  const quorum = Math.max(0, props.num_players - props.prompts.length);
   const max_votes = props.prompts.reduce(
     (max_so_far, v) => Math.max(max_so_far, v.votes.length), 0);