[BattleGrounds] Bots no longer needlessly dismount in BG's when near a creature (eg: AV rams). AV: attacking bots now concentrate on final GY and boss when all enemy towers are down (prevents them running back to previous GY's when they should just down the boss), attacking bots now try to get first enemy GY before first tower (helps alliance), bots respawning in cave starting area's now leave cave before selecting path (they were making bad selections due to all paths starting too far away from spawn point, defending horde bots would try to clip through walls and go directly to horde base GY), new path to get from horde cave to horde base (prevents horde defenders trying to scale the hills/walls to get in), overall balance between teams much improved. new playerbots debug bg commands (that I used to develop/test these changes)

This commit is contained in:
Fuzz
2024-07-22 09:02:00 +10:00
parent ac4d14abd4
commit 6417e836e1
4 changed files with 377 additions and 176 deletions

View File

@@ -19,6 +19,7 @@
#include "PlayerbotMgr.h"
#include "RandomPlayerbotMgr.h"
#include "ScriptMgr.h"
#include "BattleGroundTactics.h"
class playerbots_commandscript : public CommandScript
{
@@ -27,17 +28,23 @@ public:
std::vector<ChatCommand> GetCommands() const override
{
static std::vector<ChatCommand> playerbotsDebugCommandTable =
{
{ "bg", SEC_GAMEMASTER, true, &HandleDebugBGCommand, nullptr },
};
static std::vector<ChatCommand> playerbotsCommandTable =
{
{ "bot", SEC_PLAYER, false, &HandlePlayerbotCommand, nullptr },
{ "gtask", SEC_GAMEMASTER, true, &HandleGuildTaskCommand, nullptr },
{ "pmon", SEC_GAMEMASTER, true, &HandlePerfMonCommand, nullptr },
{ "rndbot", SEC_GAMEMASTER, true, &HandleRandomPlayerbotCommand, nullptr }
{ "rndbot", SEC_GAMEMASTER, true, &HandleRandomPlayerbotCommand, nullptr },
{ "debug", SEC_GAMEMASTER, true, nullptr, "", playerbotsDebugCommandTable},
};
static std::vector<ChatCommand> commandTable =
{
{ "playerbots", SEC_PLAYER, true, nullptr, "", playerbotsCommandTable },
{ "playerbots", SEC_PLAYER, true, nullptr, "", playerbotsCommandTable },
};
return commandTable;
@@ -81,6 +88,11 @@ public:
sPerformanceMonitor->PrintStats();
return true;
}
static bool HandleDebugBGCommand(ChatHandler* handler, char const* args)
{
return BGTactics::HandleConsoleCommand(handler, args);
}
};
void AddSC_playerbots_commandscript()