mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-24 03:53:12 -04:00
Make stateBasedRandom depend on turn (#11603)
This commit is contained in:
parent
99d937ee1f
commit
ca1a2816c8
@ -45,7 +45,7 @@ object Conditionals {
|
||||
|
||||
val gameInfo by lazy { relevantCiv?.gameInfo }
|
||||
|
||||
val stateBasedRandom by lazy { Random(state.hashCode()) }
|
||||
val stateBasedRandom by lazy { Random(state.hashCode() * 31 + (gameInfo?.turns?.hashCode() ?: 0)) }
|
||||
|
||||
fun getResourceAmount(resourceName: String): Int {
|
||||
if (relevantCity != null) return relevantCity!!.getAvailableResourceAmount(resourceName)
|
||||
|
Loading…
x
Reference in New Issue
Block a user