mirror of
https://github.com/mod-playerbots/mod-playerbots.git
synced 2026-01-15 01:49:09 +00:00
Autoscale latency modifier
This commit is contained in:
@@ -234,16 +234,15 @@ bool BGJoinAction::shouldJoinBg(BattlegroundQueueTypeId queueTypeId, Battlegroun
|
||||
return false;
|
||||
|
||||
TeamId teamId = bot->GetTeamId();
|
||||
bool noLag = sWorldUpdateTime.GetAverageUpdateTime() < (sRandomPlayerbotMgr->GetPlayers().empty()
|
||||
? sPlayerbotAIConfig->diffEmpty
|
||||
: sPlayerbotAIConfig->diffWithPlayer) *
|
||||
1.1;
|
||||
bool noLag = sWorldUpdateTime.GetAverageUpdateTime() < (sRandomPlayerbotMgr->GetPlayers().empty() ?
|
||||
sPlayerbotAIConfig->botActiveAloneSmartScaleDiffEmpty :
|
||||
sPlayerbotAIConfig->botActiveAloneSmartScaleDiffWithPlayer) * 1.1;
|
||||
|
||||
uint32 BracketSize = bg->GetMaxPlayersPerTeam() * 2;
|
||||
uint32 TeamSize = bg->GetMaxPlayersPerTeam();
|
||||
|
||||
// If performance diff is enabled, only queue if there is no lag
|
||||
if (sPlayerbotAIConfig->enablePrototypePerformanceDiff && !noLag)
|
||||
if (sPlayerbotAIConfig->botActiveAloneSmartScale && !noLag)
|
||||
return false;
|
||||
|
||||
// If the bot is in a group, only the leader can queue
|
||||
@@ -578,16 +577,15 @@ bool FreeBGJoinAction::shouldJoinBg(BattlegroundQueueTypeId queueTypeId, Battleg
|
||||
return false;
|
||||
|
||||
TeamId teamId = bot->GetTeamId();
|
||||
bool noLag = sWorldUpdateTime.GetAverageUpdateTime() < (sRandomPlayerbotMgr->GetPlayers().empty()
|
||||
? sPlayerbotAIConfig->diffEmpty
|
||||
: sPlayerbotAIConfig->diffWithPlayer) *
|
||||
1.1;
|
||||
bool noLag = sWorldUpdateTime.GetAverageUpdateTime() < (sRandomPlayerbotMgr->GetPlayers().empty() ?
|
||||
sPlayerbotAIConfig->botActiveAloneSmartScaleDiffEmpty :
|
||||
sPlayerbotAIConfig->botActiveAloneSmartScaleDiffWithPlayer) * 1.1;
|
||||
|
||||
uint32 BracketSize = bg->GetMaxPlayersPerTeam() * 2;
|
||||
uint32 TeamSize = bg->GetMaxPlayersPerTeam();
|
||||
|
||||
// If performance diff is enabled, only queue if there is no lag
|
||||
if (sPlayerbotAIConfig->enablePrototypePerformanceDiff && !noLag)
|
||||
if (sPlayerbotAIConfig->botActiveAloneSmartScale && !noLag)
|
||||
return false;
|
||||
|
||||
// If the bot is in a group, only the leader can queue
|
||||
|
||||
Reference in New Issue
Block a user