summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2015-02-20 22:55:19 +0100
committerMattes D <github@xoft.cz>2015-02-20 22:55:19 +0100
commit22d3a6a47f89ae1bb36f4f5f93c1694658b92bed (patch)
treed60cc646210f1994b1c8327c710384a6518e6b10
parentFixed crash when logging nil values. (diff)
downloadcuberite-22d3a6a47f89ae1bb36f4f5f93c1694658b92bed.tar
cuberite-22d3a6a47f89ae1bb36f4f5f93c1694658b92bed.tar.gz
cuberite-22d3a6a47f89ae1bb36f4f5f93c1694658b92bed.tar.bz2
cuberite-22d3a6a47f89ae1bb36f4f5f93c1694658b92bed.tar.lz
cuberite-22d3a6a47f89ae1bb36f4f5f93c1694658b92bed.tar.xz
cuberite-22d3a6a47f89ae1bb36f4f5f93c1694658b92bed.tar.zst
cuberite-22d3a6a47f89ae1bb36f4f5f93c1694658b92bed.zip
Diffstat (limited to '')
-rw-r--r--src/MobSpawner.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/MobSpawner.cpp b/src/MobSpawner.cpp
index 0a32d17ef..541135996 100644
--- a/src/MobSpawner.cpp
+++ b/src/MobSpawner.cpp
@@ -110,7 +110,8 @@ eMonsterType cMobSpawner::ChooseMobType(EMCSBiome a_Biome)
if (allowedMobsSize > 0)
{
std::set<eMonsterType>::iterator itr = allowedMobs.begin();
- int iRandom = m_Random.NextInt((int)allowedMobsSize, a_Biome);
+ static int Counter = 0;
+ int iRandom = m_Random.NextInt((int)allowedMobsSize, Counter++);
for (int i = 0; i < iRandom; i++)
{