From 8d8d7888641ed88883260acb37a935d6879bc5b2 Mon Sep 17 00:00:00 2001 From: whipowill Date: Fri, 20 May 2022 13:04:02 -0500 Subject: [PATCH] Compile bug fixes. --- src/PlayerbotAIConfig.cpp | 44 +++++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/src/PlayerbotAIConfig.cpp b/src/PlayerbotAIConfig.cpp index ac0acfab..e8a02a5c 100644 --- a/src/PlayerbotAIConfig.cpp +++ b/src/PlayerbotAIConfig.cpp @@ -65,23 +65,23 @@ bool PlayerbotAIConfig::Initialize() returnDelay = sConfigMgr->GetOption("AiPlayerbot.ReturnDelay", 7000); lootDelay = sConfigMgr->GetOption("AiPlayerbot.LootDelay", 1000); - farDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.FarDistance", 20.0f); - sightDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.SightDistance", 75.0f); - spellDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.SpellDistance", 22.0f); - shootDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.ShootDistance", 25.0f); - healDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.HealDistance", 20.0f); - lootDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.LootDistance", 15.0f); - fleeDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.FleeDistance", 7.5f); - aggroDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.AggroDistance", 22.0f); - tooCloseDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.TooCloseDistance", 5.0f); - meleeDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.MeleeDistance", 1.5f); - followDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.FollowDistance", 1.5f); - whisperDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.WhisperDistance", 6000.0f); - contactDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.ContactDistance", 0.5f); - aoeRadius = sConfigMgr->GetFloatDefault("AiPlayerbot.AoeRadius", 5.0f); - rpgDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.RpgDistance", 200.0f); - grindDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.GrindDistance", 75.0f); - reactDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.ReactDistance", 150.0f); + farDistance = sConfigMgr->GetOption("AiPlayerbot.FarDistance", 20.0f); + sightDistance = sConfigMgr->GetOption("AiPlayerbot.SightDistance", 75.0f); + spellDistance = sConfigMgr->GetOption("AiPlayerbot.SpellDistance", 22.0f); + shootDistance = sConfigMgr->GetOption("AiPlayerbot.ShootDistance", 25.0f); + healDistance = sConfigMgr->GetOption("AiPlayerbot.HealDistance", 20.0f); + lootDistance = sConfigMgr->GetOption("AiPlayerbot.LootDistance", 15.0f); + fleeDistance = sConfigMgr->GetOption("AiPlayerbot.FleeDistance", 7.5f); + aggroDistance = sConfigMgr->GetOption("AiPlayerbot.AggroDistance", 22.0f); + tooCloseDistance = sConfigMgr->GetOption("AiPlayerbot.TooCloseDistance", 5.0f); + meleeDistance = sConfigMgr->GetOption("AiPlayerbot.MeleeDistance", 1.5f); + followDistance = sConfigMgr->GetOption("AiPlayerbot.FollowDistance", 1.5f); + whisperDistance = sConfigMgr->GetOption("AiPlayerbot.WhisperDistance", 6000.0f); + contactDistance = sConfigMgr->GetOption("AiPlayerbot.ContactDistance", 0.5f); + aoeRadius = sConfigMgr->GetOption("AiPlayerbot.AoeRadius", 5.0f); + rpgDistance = sConfigMgr->GetOption("AiPlayerbot.RpgDistance", 200.0f); + grindDistance = sConfigMgr->GetOption("AiPlayerbot.GrindDistance", 75.0f); + reactDistance = sConfigMgr->GetOption("AiPlayerbot.ReactDistance", 150.0f); criticalHealth = sConfigMgr->GetOption("AiPlayerbot.CriticalHealth", 20); lowHealth = sConfigMgr->GetOption("AiPlayerbot.LowHealth", 45); @@ -90,9 +90,9 @@ bool PlayerbotAIConfig::Initialize() lowMana = sConfigMgr->GetOption("AiPlayerbot.LowMana", 15); mediumMana = sConfigMgr->GetOption("AiPlayerbot.MediumMana", 40); - randomGearLoweringChance = sConfigMgr->GetFloatDefault("AiPlayerbot.RandomGearLoweringChance", 0.15f); - randomBotMaxLevelChance = sConfigMgr->GetFloatDefault("AiPlayerbot.RandomBotMaxLevelChance", 0.15f); - randomBotRpgChance = sConfigMgr->GetFloatDefault("AiPlayerbot.RandomBotRpgChance", 0.20f); + randomGearLoweringChance = sConfigMgr->GetOption("AiPlayerbot.RandomGearLoweringChance", 0.15f); + randomBotMaxLevelChance = sConfigMgr->GetOption("AiPlayerbot.RandomBotMaxLevelChance", 0.15f); + randomBotRpgChance = sConfigMgr->GetOption("AiPlayerbot.RandomBotRpgChance", 0.20f); iterationsPerTick = sConfigMgr->GetOption("AiPlayerbot.IterationsPerTick", 100); @@ -138,7 +138,7 @@ bool PlayerbotAIConfig::Initialize() randomBotTeleLevel = sConfigMgr->GetOption("AiPlayerbot.RandomBotTeleLevel", 5); openGoSpell = sConfigMgr->GetOption("AiPlayerbot.OpenGoSpell", 6477); - randomChangeMultiplier = sConfigMgr->GetFloatDefault("AiPlayerbot.RandomChangeMultiplier", 1.0); + randomChangeMultiplier = sConfigMgr->GetOption("AiPlayerbot.RandomChangeMultiplier", 1.0); randomBotCombatStrategies = sConfigMgr->GetOption("AiPlayerbot.RandomBotCombatStrategies", "-threat"); randomBotNonCombatStrategies = sConfigMgr->GetOption("AiPlayerbot.RandomBotNonCombatStrategies", ""); @@ -264,7 +264,7 @@ bool PlayerbotAIConfig::Initialize() maxGuildTaskRewardTime = sConfigMgr->GetOption("AiPlayerbot.MaxGuildTaskRewardTime", 3600); guildTaskAdvertCleanupTime = sConfigMgr->GetOption("AiPlayerbot.GuildTaskAdvertCleanupTime", 300); guildTaskKillTaskDistance = sConfigMgr->GetOption("AiPlayerbot.GuildTaskKillTaskDistance", 2000); - targetPosRecalcDistance = sConfigMgr->GetFloatDefault("AiPlayerbot.TargetPosRecalcDistance", 0.1f); + targetPosRecalcDistance = sConfigMgr->GetOption("AiPlayerbot.TargetPosRecalcDistance", 0.1f); // cosmetics (by lidocain) randomBotShowCloak = sConfigMgr->GetOption("AiPlayerbot.RandomBotShowCloak", true);