mirror of
https://github.com/ErikasKontenis/SabrehavenServer.git
synced 2025-04-30 17:49:20 +02:00
make monsters spawning time more random which will increase the spawn rate
This commit is contained in:
parent
99ea898868
commit
8271185cba
@ -89,7 +89,7 @@ bool Spawns::loadFromXml(const std::string& filename)
|
||||
spawnList.emplace_front(pos, radius);
|
||||
Spawn& spawn = spawnList.front();
|
||||
|
||||
uint32_t interval = pugi::cast<uint32_t>(childNode.attribute("spawntime").value()) * 500;
|
||||
uint32_t interval = uniform_random(pugi::cast<uint32_t>(childNode.attribute("spawntime").value()) * 250, pugi::cast<uint32_t>(childNode.attribute("spawntime").value()) * 500);
|
||||
if (interval > MINSPAWN_INTERVAL) {
|
||||
uint32_t exInterval = g_config.getNumber(ConfigManager::RATE_SPAWN);
|
||||
if (exInterval) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user