mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
5-8 percent performance increase when when botActiveAlone is 100% and smartScale disabled (#803)
Diff-wise. By moving the when botActiveAlone is 100% and smartScale disabled return to the very top.
This commit is contained in:
@@ -4135,6 +4135,12 @@ inline bool ZoneHasRealPlayers(Player* bot)
|
||||
|
||||
bool PlayerbotAI::AllowActive(ActivityType activityType)
|
||||
{
|
||||
// when botActiveAlone is 100% and smartScale disabled
|
||||
if (sPlayerbotAIConfig->botActiveAlone >= 100 && !sPlayerbotAIConfig->botActiveAloneSmartScale)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// Is in combat. Always defend yourself.
|
||||
if (activityType != OUT_OF_PARTY_ACTIVITY && activityType != PACKET_ACTIVITY)
|
||||
{
|
||||
@@ -4163,12 +4169,6 @@ bool PlayerbotAI::AllowActive(ActivityType activityType)
|
||||
return true;
|
||||
}
|
||||
|
||||
// when botActiveAlone is 100% and smartScale disabled
|
||||
if (sPlayerbotAIConfig->botActiveAlone >= 100 && !sPlayerbotAIConfig->botActiveAloneSmartScale)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// bg, raid, dungeon
|
||||
if (!WorldPosition(bot).isOverworld())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user