diff options
author | Joffrey Bion <joffrey.bion@booking.com> | 2020-09-18 09:38:28 +0200 |
---|---|---|
committer | Joffrey Bion <joffrey.bion@booking.com> | 2020-09-18 09:38:28 +0200 |
commit | 4c62a6444d1742a08ed1a138809892b1c98683c2 (patch) | |
tree | 3fcc591b70e20e7c72e636ddef25cea2d8ac39ec /sw-engine/src/main/kotlin | |
parent | Fix double military resolution in last age (diff) | |
download | seven-wonders-4c62a6444d1742a08ed1a138809892b1c98683c2.tar.gz seven-wonders-4c62a6444d1742a08ed1a138809892b1c98683c2.tar.bz2 seven-wonders-4c62a6444d1742a08ed1a138809892b1c98683c2.zip |
Add comment to explain fix
Diffstat (limited to 'sw-engine/src/main/kotlin')
-rw-r--r-- | sw-engine/src/main/kotlin/org/luxons/sevenwonders/engine/Game.kt | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sw-engine/src/main/kotlin/org/luxons/sevenwonders/engine/Game.kt b/sw-engine/src/main/kotlin/org/luxons/sevenwonders/engine/Game.kt index 1d4fab65..78d09b35 100644 --- a/sw-engine/src/main/kotlin/org/luxons/sevenwonders/engine/Game.kt +++ b/sw-engine/src/main/kotlin/org/luxons/sevenwonders/engine/Game.kt @@ -199,6 +199,8 @@ class Game internal constructor( private fun endOfAgeReached(): Boolean = hands.isEmpty private fun executeEndOfAgeEvents() { + // this is necessary because this method is actually called twice in the 3rd age if someone has CPY_GUILD + // TODO we should instead manage the game's state machine in a better way to avoid stuff like this if (!militaryConflictsResolved) { table.resolveMilitaryConflicts() militaryConflictsResolved = true |