Improve random accounts creation (#942)

* Duplicate name check and improve name cache

* Sync wait for the first time creation of random bots
This commit is contained in:
Yunfan Li
2025-02-03 23:39:45 +08:00
committed by GitHub
parent 1c2ec60e6b
commit 9bbe183763
2 changed files with 78 additions and 31 deletions

View File

@@ -567,9 +567,7 @@ void RandomPlayerbotMgr::LoadBattleMastersCache()
{
BattleMastersCache.clear();
LOG_INFO("playerbots", "---------------------------------------");
LOG_INFO("playerbots", " Loading BattleMasters Cache ");
LOG_INFO("playerbots", "---------------------------------------");
LOG_INFO("playerbots", "Loading BattleMasters Cache...");
QueryResult result = WorldDatabase.Query("SELECT `entry`,`bg_template` FROM `battlemaster_entry`");
@@ -1534,9 +1532,9 @@ void RandomPlayerbotMgr::PrepareTeleportCache()
}
LOG_INFO("playerbots", ">> {} locations for level collected.", collected_locs);
LOG_INFO("playerbots", "Preparing innkeepers locations for level...");
if (sPlayerbotAIConfig->enableNewRpgStrategy)
{
LOG_INFO("playerbots", "Preparing innkeepers locations for level...");
results = WorldDatabase.Query(
"SELECT "
"map, "