summaryrefslogtreecommitdiffstats
path: root/src/MobSpawner.cpp
diff options
context:
space:
mode:
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 98c428bab..2ddf60bbd 100644
--- a/src/MobSpawner.cpp
+++ b/src/MobSpawner.cpp
@@ -112,7 +112,8 @@ eMonsterType cMobSpawner::ChooseMobType(EMCSBiome a_Biome)
{
std::set<eMonsterType>::iterator itr = allowedMobs.begin();
- std::advance(itr, GetRandomProvider().RandInt<size_t>(allowedMobsSize - 1));
+ using DiffType = decltype(itr)::difference_type;
+ std::advance(itr, GetRandomProvider().RandInt<DiffType>(allowedMobsSize - 1));
return *itr;
}