summaryrefslogtreecommitdiff
path: root/domain/src
diff options
context:
space:
mode:
authorFelix Morgner <felix.morgner@gmail.com>2024-07-24 08:57:21 +0200
committerFelix Morgner <felix.morgner@gmail.com>2024-07-24 08:57:21 +0200
commit0d61f98434b95c754f46c918af5152eda82077cb (patch)
treeb7908f53bcaabf4002cfb52daa461789b59fc9a5 /domain/src
parentcd855825de415111c55f16bf05a57f1191d97c76 (diff)
downloadturns-0d61f98434b95c754f46c918af5152eda82077cb.tar.xz
turns-0d61f98434b95c754f46c918af5152eda82077cb.zip
domain/turn_order: fix a round underflow bug
Diffstat (limited to 'domain/src')
-rw-r--r--domain/src/turn_order.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/domain/src/turn_order.cpp b/domain/src/turn_order.cpp
index e3a1e23..d3140b1 100644
--- a/domain/src/turn_order.cpp
+++ b/domain/src/turn_order.cpp
@@ -122,7 +122,7 @@ namespace turns::domain
m_data[old_active]->is_active() = false;
m_data[*m_active]->is_active() = true;
- if (m_active == 0)
+ if (m_active == 0 && m_round_number > 0)
{
m_round_number = m_round_number - 1;
}