diff --git a/aincrad/tests.py b/aincrad/tests.py index 8f45efa9..c9974ca3 100644 --- a/aincrad/tests.py +++ b/aincrad/tests.py @@ -562,13 +562,13 @@ def test_hanabi_contest(self) -> None: ) self.assertEqual(len(resp.json()["names"]), 9) self.assertAlmostEqual( - HanabiReplay.objects.get(replay_id=812).spades_score, 4.0 + HanabiReplay.objects.get(replay_id=812).spades_score, 6.0 ) self.assertAlmostEqual( - HanabiReplay.objects.get(replay_id=811).spades_score, 3.0 + HanabiReplay.objects.get(replay_id=811).spades_score, 5.0 ) self.assertAlmostEqual( - HanabiReplay.objects.get(replay_id=271).spades_score, 0.6328125 + HanabiReplay.objects.get(replay_id=271).spades_score, 1.265625 ) self.assertEqual(HanabiParticipation.objects.all().count(), 9) self.assertEqual( diff --git a/hanabi/models.py b/hanabi/models.py index bbc6f45d..931b5db0 100644 --- a/hanabi/models.py +++ b/hanabi/models.py @@ -140,7 +140,7 @@ def get_absolute_url(self) -> str: def get_base_spades(self) -> float: num_suits = self.contest.num_suits - return 2 * (self.game_score / (5 * num_suits)) ** num_suits + return 4 * (self.game_score / (5 * num_suits)) ** 4 class HanabiParticipation(models.Model): diff --git a/hanabi/templates/hanabi/hanabicontest_list.html b/hanabi/templates/hanabi/hanabicontest_list.html index 9820aab2..2796e5b7 100644 --- a/hanabi/templates/hanabi/hanabicontest_list.html +++ b/hanabi/templates/hanabi/hanabicontest_list.html @@ -191,13 +191,11 @@
The above list is not exhaustive; spades can be awarded for other things too.