diff --git a/src/PlayerbotAI.cpp b/src/PlayerbotAI.cpp index e7d9552b..5ff7fd7d 100644 --- a/src/PlayerbotAI.cpp +++ b/src/PlayerbotAI.cpp @@ -3123,7 +3123,7 @@ bool PlayerbotAI::HasAuraToDispel(Unit* target, uint32 dispelType) #ifndef WIN32 inline int strcmpi(char const* s1, char const* s2) { - for (; *s1 && *s2 && (toupper(*s1) == toupper(*s2)); ++s1, ++s2); + for (; *s1 && *s2 && (toupper(*s1) == toupper(*s2)); ++s1, ++s2) {} return *s1 - *s2; } #endif @@ -3951,6 +3951,8 @@ std::string const PlayerbotAI::HandleRemoteCommand(std::string const command) case NeedMoneyFor::guild: out << "guild"; break; + default: + break; } out << " | " << ChatHelper::formatMoney(AI_VALUE2(uint32, "free money for", i)) << " / " << ChatHelper::formatMoney(AI_VALUE2(uint32, "money needed for", i)) << "\n"; diff --git a/src/RandomPlayerbotMgr.cpp b/src/RandomPlayerbotMgr.cpp index f7ff76cc..a2c96a62 100644 --- a/src/RandomPlayerbotMgr.cpp +++ b/src/RandomPlayerbotMgr.cpp @@ -1285,7 +1285,7 @@ void RandomPlayerbotMgr::PrepareTeleportCache() "ROUND( position_z / 50), " "t.entry " "HAVING " - "count(*) > 10) AS g " + "count(*) > 7) AS g " "INNER JOIN creature c ON g.guid = c.guid " "INNER JOIN creature_template t on c.id1 = t.entry " "ORDER BY " diff --git a/src/strategy/values/ItemUsageValue.cpp b/src/strategy/values/ItemUsageValue.cpp index 8c05803a..ad4deb03 100644 --- a/src/strategy/values/ItemUsageValue.cpp +++ b/src/strategy/values/ItemUsageValue.cpp @@ -199,8 +199,9 @@ ItemUsage ItemUsageValue::QueryItemUsageForEquip(ItemTemplate const* itemProto) if (!oldItem) if (shouldEquip) return ITEM_USAGE_EQUIP; - else + else { return ITEM_USAGE_BAD_EQUIP; + } ItemTemplate const* oldItemProto = oldItem->GetTemplate(); float oldScore = PlayerbotFactory::CalculateItemScore(oldItemProto->ItemId, bot); @@ -217,8 +218,9 @@ ItemUsage ItemUsageValue::QueryItemUsageForEquip(ItemTemplate const* itemProto) if (itemProto->Class == ITEM_CLASS_QUIVER) if (!oldItem || oldItemProto->ContainerSlots < itemProto->ContainerSlots) return ITEM_USAGE_EQUIP; - else + else { return ITEM_USAGE_NONE; + } bool existingShouldEquip = true; if (oldItemProto->Class == ITEM_CLASS_WEAPON && !sRandomItemMgr->CanEquipWeapon(bot->getClass(), oldItemProto)) diff --git a/src/strategy/values/PartyMemberValue.h b/src/strategy/values/PartyMemberValue.h index ab9c97ef..2924c99b 100644 --- a/src/strategy/values/PartyMemberValue.h +++ b/src/strategy/values/PartyMemberValue.h @@ -13,6 +13,7 @@ class PlayerbotAI; class FindPlayerPredicate { public: + virtual ~FindPlayerPredicate() = default; virtual bool Check(Unit* /*unit*/) = 0; };