crashfix: prevent division by zero when spawning too many bots

This commit is contained in:
Ramok
2025-05-30 14:26:24 +02:00
committed by GitHub
parent 76f540b426
commit 35228f6d9b
2 changed files with 5 additions and 9 deletions

View File

@@ -69,4 +69,6 @@ static inline void InitBotNames()
PlayerBotNames.push_back(L"AllyJax");
PlayerBotNames.push_back(L"secret_pommes");
PlayerBotNames.push_back(L"Twin1");
std::shuffle(PlayerBotNames.begin(), PlayerBotNames.end(), std::default_random_engine((unsigned int)time(0)));
}