Add WoW Forever Bots by Karrz (optional, -DBUILD_PLAYERBOT_V2=1, default off)

Imported from Karrz's karrz-bots branch (12a3d94547) on top of forever: the
PlayerbotV2 module, the ForeverBots add-on (/fb), the bot SQL, the core hooks
and API it needs, and the Classic battleground, raid, auction house and road
navigation changes it was tested with.

Left out of this import: the world editor, tests, protocol research and data
generator tools, dev setup scripts, the realm example config, the design notes,
the older PlayerbotControl add-on, and changes to sql/create, the Boost
minimum, and the build revision files. These stay in Karrz's own repository.
This commit is contained in:
Karrz1
2026-10-13 09:21:34 +08:00
committed by Advocaite
parent 8c5325b37d
commit d13cdf728d
927 changed files with 369512 additions and 483 deletions
+106
View File
@@ -0,0 +1,106 @@
# WoW Forever Bots
**WoW Forever Bots by Karrz**, for WoW Forever. Built on agatho's PlayerbotV2. If you reuse these bots, keep this name, the credits below and the license notices.
This is the bot system for advocaite's TrinityCore `forever` tree (this branch is his tree plus the bots): party companions you add with
one click, raid / dungeon / battleground bots, an optional ambient population of bots around
real players, and a vanilla-style auction house bot. Take what is useful.
Base: `advocaite/TrinityCore` branch `forever` at `440d365e`. With `-DBUILD_PLAYERBOT_V2=0` (the default) the module is not built.
## What is in it
| Part | Where |
|---|---|
| Bot module (AI, raid brain, BG scripts, world bots, fleet, travel) | `src/modules/PlayerbotV2/` |
| Core side: a small API plus hooks | `src/server/game/Playerbot/`, `src/server/game/Modules/`, `src/server/scripts/Commands/cs_playerbot_v2.cpp`, hooks in login, group, chat, spell, threat, BG/LFG queue, map, session |
| Bot database migrations and seed data | `sql/playerbot_v2/`, `sql/playerbot_shared/` |
| Settings | `src/modules/PlayerbotV2/conf/playerbot.conf.dist` (every key documented), `examples/zz-forever-bots.conf` (optional extras, off unless you copy it in) |
| In-game window (addon) | `src/modules/PlayerbotV2/Addon/ForeverBots/` |
| Everything players can type or click | `src/modules/PlayerbotV2/BOT_COMMANDS.md` |
Besides the module, this tree carries Classic changes the bots depend on or were tested with:
vanilla auction house seller (`src/server/game/AuctionHouseBot/`), road-aware pathing
(`HandcraftedRoad*`, `dtQueryFilterTC`, `RoadOverrides`), Classic battleground scripts
(`src/server/scripts/Custom/Classic/battlegrounds/`), the code that uses vanilla (1.12) spell, creature and mana numbers, some Classic
data fixes (`sql/custom/world/2026_10_*`), and several smaller core fixes.
The vanilla numbers themselves are **not** in the repository: `tools/classic_spell_values/` builds them from the VMaNGOS database dump that you download
yourself (`tools/classic_spell_values/README.md`). Without them the tables stay empty and the client's own values apply.
Extras that are not Blizzlike are server switches, **all off in `worldserver.conf.dist`**: `Instance.IgnoreRaid`, `Instance.BindOnEntry`,
`Instance.PersistRaidTrash`, `Instance.MoltenCoreSkipRunes`, `Instance.IgnoreAttunement`, `Instance.AhnQirajGatesOpen`,
`Instance.MoltenCoreHoundsLinked` (Molten Core is Blizzlike except that the core hound packs are not linked). They are described in
`doc/OptionalServerOptions.md`; `examples/zz-forever-bots.conf` turns them on if you copy it in.
## Build
The module is only built with `-DBUILD_PLAYERBOT_V2=1` (default `0`). Without it the hooks
compile to empty inlines and `WorldSession::IsBot()` is a constant `false`.
```
cmake -S . -B build -DSERVERS=1 -DSCRIPTS=static -DBUILD_PLAYERBOT_V2=1
cmake --build build --config RelWithDebInfo --target worldserver
```
Status: compile-checked on Linux (GCC 13, Ninja, Release, static scripts): `-DBUILD_PLAYERBOT_V2=1` and `-DBUILD_PLAYERBOT_V2=0` both build and link `worldserver` and the binaries start. Not compiled on Windows in exactly this combination; our own tree (the same code plus files left out here) builds and runs on Windows (Visual Studio 2022, MySQL 8.4) and was played on client 70338.
## Enable
1. Configure with `-DBUILD_PLAYERBOT_V2=1` as above.
2. Create the shared database and seed it (once):
```
mysql -u<user> -p < sql/playerbot_shared/playerbot_shared_schema.sql
mysql -u<user> -p playerbot < sql/playerbot_shared/playerbot_shared_data.sql
```
3. Rename the module config the build copies into `worldserver.conf.d` from
`playerbot.conf.dist` to `playerbot.conf`. Optionally copy `examples/zz-forever-bots.conf`
there too (optional extras and recommended values; it is read after `playerbot.conf`).
4. Start worldserver. `sql/playerbot_v2/*.sql` migrations are applied on boot to the characters
and `playerbot` databases (back up `characters` first). If the binary runs on a machine
without the source tree, set `SourceDirectory` in `worldserver.conf`.
5. Add `Logger.playerbot.v2=3` to see the module's log lines (written to `Playerbot.log`).
6. Install the addon: copy `src/modules/PlayerbotV2/Addon/ForeverBots` into `Interface/AddOns/`, and
make your account a GM account for the `.bot` commands.
The server prints "WoW Forever Bots ..." at start-up, `.bot about` shows the same line, and the in-game addon (folder `ForeverBots`, slash command `/fb`) is titled "WoW Forever Bots".
Step by step: `INSTALL-BOTS.md`. More: `src/modules/PlayerbotV2/INSTALL.md`, `WORLD_BOTS.md`.
## Main config keys (all in `playerbot.conf`)
| Key | Default | What it does |
|---|---|---|
| `Playerbot.SharedDatabase` | `playerbot` | name of the shared database |
| `Playerbot.AiWorkerThreads` | `0` | AI worker threads (0 = automatic) |
| `Playerbot.World.Enable` | `0` | ambient bots around real players |
| `Playerbot.World.MaxBots` / `BotsPerPlayer` / `ActivityRadius` | `100` / `25` / `300` | size and reach of that population |
| `Playerbot.World.RssBudgetMb` | `0` | memory cap for the spawner (0 = off) |
| `Playerbot.Bg.AutoJoin` / `Bg.AutoSeed.*` | `0` | bots queue for and fill battlegrounds |
| `Playerbot.Raid.Enable` | `1` | raid brain; only acts for bot groups |
| `Playerbot.Cast.Enable` | `0` | human-like cast speed per context |
| `Playerbot.Behavior.*` | see file | individual behaviours (formation, pull back, spreading, ...) |
Without a player summoning bots nothing spawns, and with `World.Enable = 0` no ambient bots exist.
## Credits
- **Karrz (Karrz1)**: WoW Forever Bots, i.e. the Classic adaptation, raid, battleground, world
population and auction house work, and the Classic data and core fixes in this tree.
- **agatho**: PlayerbotV2, the base of the module (https://github.com/agatho/TrinityCore, branch `playerbot-v2`).
- **advocaite**: the Forever TrinityCore core this is built on.
- **ike3 / cmangos playerbots**, **VMaNGOS** and **cMaNGOS**: behaviour that was ported, and the 1.12 numbers the builder reads from the VMaNGOS database (see `NOTICE.md`).
- **mod-playerbots (AzerothCore)**: read as a reference for behaviour ideas only; no code copied.
- **SimulationCraft**: reference for rotation and talent data.
## Licenses
- This tree, the bot module and the core changes: **GPL-2.0** (`COPYING`), like TrinityCore.
- agatho's PlayerbotV2: GPL-2.0. ike3 / cmangos playerbots, VMaNGOS, cMaNGOS: GPL-2.0.
- mod-playerbots (AzerothCore): AGPL-3.0. Reference only; none of its code is in this tree.
- SimulationCraft: GPL-3.0. Data and action lists used as reference (`sql/playerbot_v2/0004_simc_seed.sql`).
- Third-party libraries under `dep/` keep their own licenses.
- The VMaNGOS database dump is not included; it belongs to its authors. World of Warcraft data, names and client files belong to Blizzard Entertainment and are not
included.
See `src/modules/PlayerbotV2/NOTICE.md` for details.
+86
View File
@@ -0,0 +1,86 @@
# Installing the ForeverBots bots
You get: party companions you add with one click, raid/dungeon/battleground bots, bots roaming the
world (about 300), an auction house that is stocked and trades, and the in-game `ForeverBots` window.
This is advocaite's `forever` tree with the bots in it. Feedback and logs are welcome (see the end).
Two ways to get a server with the bots. Both end with the same steps 3-6.
## A. You already run the Forever repack (Windows)
The bots are part of the server program, so you need a `worldserver.exe` that was built with them.
1. **Get that worldserver.exe.** Either use a prebuilt one if the person who gave you this
package included it, or build it yourself (section B, steps 1-2). Close the server, then
**back up your `characters` database** (the bots add a few tables to it) and keep a copy of
your old `worldserver.exe`.
2. Copy the new `worldserver.exe` over the old one. If a `worldserver.conf.d` folder does not
exist next to it, create it.
## B. Building from source
1. Build as for the plain Forever server, adding one option:
`cmake -S . -B build -DSERVERS=1 -DSCRIPTS=static -DBUILD_PLAYERBOT_V2=1`
then `cmake --build build --config RelWithDebInfo --target worldserver`. Needs the usual
TrinityCore requirements (Visual Studio 2022 or newer on Windows, Boost, OpenSSL, MySQL
8 client). Without `-DBUILD_PLAYERBOT_V2=1` you get the unchanged server and no bots.
2. The build puts `playerbot.conf.dist` into `worldserver.conf.d`. Run `cmake --install` or copy
the files from `build\...\worldserver.conf.d` next to your `worldserver.exe`.
Keep `SourceDirectory` in `worldserver.conf` pointing at this checkout: on first start the
server applies the SQL files in `sql\playerbot_v2` from there.
## Steps for everyone
Optional first: the vanilla (1.12) numbers. They are not in the repository; you build them from the VMaNGOS database dump you download yourself
(`tools/classic_spell_values/README.md`, one command). Without them the bots and the server use the client's own values.
3. **Create the shared bot database (once).** In a command prompt, from this folder
(use your own MySQL user; `mysql.exe` is in your MySQL `bin` folder):
```
mysql -u root -p < sql\playerbot_shared\playerbot_shared_schema.sql
mysql -u root -p playerbot < sql\playerbot_shared\playerbot_shared_data.sql
```
Your database user needs rights on the new `playerbot` database
(`GRANT ALL ON playerbot.* TO '<your db user>'@'%';`). The server reads and writes it with the
same login as your other databases. The files do not drop anything.
4. **Settings.** In `worldserver.conf.d`, rename `playerbot.conf.dist` to `playerbot.conf`, and copy
`examples\zz-forever-bots.conf` into the same folder. That file is optional and turns on
extras that are **not** Blizzlike: solo raid entry and saving on entry (`Instance.IgnoreRaid`, `Instance.BindOnEntry`), killed raid trash staying dead (`Instance.PersistRaidTrash`),
no Molten Core runes, no attunements, open Ahn'Qiraj gates (see `doc/OptionalServerOptions.md`), the
auction house bot, faster raid casting, and world bots (stage A, 300 bots, `Playerbot.World.*`).
Change a value and restart to tune; set `Playerbot.World.Enable = 0` for no roaming bots,
`AuctionHouseBot.Seller.Enabled = 0` for no auction bot. Weak PC: set `Playerbot.World.MaxBots = 100`
and `Playerbot.World.GlobalFill = 0`. Expect 4-6 GB of extra RAM at 300 bots.
5. **Start the server** (bnetserver, then worldserver). The first start takes longer while the bot
tables are created. Bot log lines go to `Playerbot.log` in your logs folder.
6. **Install the addon.** Copy the folder `src\modules\PlayerbotV2\Addon\ForeverBots` into
`<your WoW folder>\_classic_beta_\Interface\AddOns\` (so you have `...\AddOns\ForeverBots\ForeverBots.toc`).
On the character screen open AddOns and tick "Load out of date AddOns" if it is greyed out.
## Using the bots in game
Your account must be a GM account for the `.bot` commands and the window (in the worldserver
console: `account set gmlevel <accountname> 3 -1`).
- `/fb` opens the window: one button per class and role adds a bot to your group at your level,
fully geared. Buttons for Follow, Stay, Attack, Pull, Flee, Release (after a wipe), formations, raid
icons and tank assignments. Everything also works by typing the word in party/raid chat.
- Full command list (chat orders, `.bot`, addon, marks, raids): `src/modules/PlayerbotV2/BOT_COMMANDS.md`.
- Commands: `.bot add <class> <role>`, `.bot call all`, `.bot dismiss`, `.bot regear`, `.bot save <name|all>`,
`.bot delete <name>`, `.bot world` (shows the roaming population). `.bot` lists the rest.
- Raids: add the bots, enter the instance, use the window's Pull and Release. A good Molten Core
group is 4 tanks, 12 healers, 6 mages, 4 warlocks, 3 hunters, 5 rogues, 4 warriors.
- Battlegrounds: queue yourself; bots fill the other places.
## Updating, removing, reporting problems
- Update: replace `worldserver.exe`, the `examples` file and the addon; new SQL is
applied by the server at start. Back up `characters` first.
- Remove: delete `playerbot.conf` and `zz-forever-bots.conf` (if you used it), and use a worldserver built without the
option. The extra tables are harmless.
- Report a problem with: what you did, `Playerbot.log`, `Server.log`, and the time it happened. Useful
lines are tagged `[raid_*]`, `[bot_death]`, `[cast_fail]`, `[world]`. Harmless messages:
"Invalid BattlegroundMapScript", "OpenSSL failed to load legacy.dll".
- Needs 40-player raid content from the Forever core; the bots do not change which content exists.
Credits and licence: `BOTS.md`, `src/modules/PlayerbotV2/NOTICE.md` (GPL-2.0).
+37
View File
@@ -0,0 +1,37 @@
# Notice and credits: WoW Forever Bots (this repository)
"WoW Forever Bots" by Karrz is the name of this bot system. Every upstream credit and license below stays in force.
This module is part of a TrinityCore-based tree and is distributed under the GNU General
Public License version 2 (`COPYING`), the same terms as TrinityCore.
- **PlayerbotV2** was written by agatho (https://github.com/agatho/TrinityCore, branch
`playerbot-v2`), whose README states "GPL-2.0, same as TrinityCore". The core API, the
module layout and most of the bot brain, travel and fleet code come from there.
- **Classic (1.12) adaptation, raid, battleground, world-population and auction house work**
was added for WoW Forever by Karrz (Karrz1).
- **ike3 / cmangos playerbots** (Ike's mangosbot for cMaNGOS; GPL-2.0): several behaviours
(raid brain, speech lines, rpg, battleground paths and objectives, travel) were ported from a
VMaNGOS-based bot tree that derives from ike3 bots, VMaNGOS and cMaNGOS (all GPL-2.0).
Source comments name the routines they follow.
- **mod-playerbots** (AzerothCore, AGPL-3.0) was read as a reference for behaviour ideas
(for example dungeon dispersal and fleeing rules). Its code was not copied; the logic was
re-written here. Comments mark where an idea came from.
- **Vanilla encounter data and scripts** follow VMaNGOS (GPL-2.0), as do the Classic ports
already in `src/server/scripts/Custom/Classic`.
- **SimulationCraft (simc)** (GPL-3.0) action lists and talent loadouts were used as
reference for the retail-era rotations and `sql/playerbot_v2/0004_simc_seed.sql`.
Keep these notices, and the copyright and licence headers that individual files carry, when
redistributing. Source files of the module do not carry per-file headers; this notice and
`COPYING` apply to all of them.
## This repository
- This branch is advocaite's TrinityCore `forever` tree (https://github.com/advocaite/TrinityCore, GPL-2.0, copyright the TrinityCore
project and contributors) plus WoW Forever Bots. The files that were changed are derived from TrinityCore and stay under its GPL-2.0.
- The 1.12 numbers (spell values, creature stats, ...) are read from the VMaNGOS database dump by `tools/classic_spell_values/`. The dump is
not part of this repository; it belongs to its authors.
- Libraries under `dep/` keep their own licenses (see each folder).
- mod-playerbots (AzerothCore) is AGPL-3.0: used only as a reference for ideas, no code copied. SimulationCraft is GPL-3.0: data used as reference.
- World of Warcraft data, names and client files belong to Blizzard Entertainment and are not included.
+4
View File
@@ -48,6 +48,10 @@ if("${CMAKE_MAKE_PROGRAM}" MATCHES "MSBuild")
target_compile_options(trinity-compile-option-interface
INTERFACE
/MP)
# Forces writes to the PDB file to be serialized through mspdbsrv.exe (/FS) - needed for Debug builds
target_compile_options(trinity-compile-option-interface
INTERFACE
$<$<CONFIG:Debug,RelWithDebInfo>:/FS>)
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
# Forces writes to the PDB file to be serialized through mspdbsrv.exe (/FS)
# Enable faster PDB generation in parallel builds by minimizing RPC calls to mspdbsrv.exe (/Zf)
+1
View File
@@ -34,6 +34,7 @@ foreach(SCRIPT_MODULE ${SCRIPT_MODULE_LIST})
endforeach()
option(TOOLS "Build map/vmap/mmap extraction/assembler tools" 1)
option(BUILD_PLAYERBOT_V2 "Build the Playerbot V2 module (next-generation, see v2/REQUIREMENTS.md)" 0)
option(USE_SCRIPTPCH "Use precompiled headers when compiling scripts" 1)
option(USE_COREPCH "Use precompiled headers when compiling servers" 1)
option(WITH_DYNAMIC_LINKING "Enable dynamic library linking." 0)
@@ -39,6 +39,14 @@ target_link_libraries(Detour
PRIVATE
trinity-dependency-interface)
# Road-aware mmaps Phase 3: enable dtQueryFilter::getCost / passFilter as
# virtual so TC's dtQueryFilterTC subclass can override the cost formula
# with slope penalty + per-bot road-bonus disable. Without this define
# the Detour vtable is empty and override is a no-op.
target_compile_definitions(Detour
PUBLIC
DT_VIRTUAL_QUERYFILTER=1)
set_target_properties(Detour
PROPERTIES
FOLDER
@@ -1094,10 +1094,18 @@ dtStatus dtNavMeshQuery::findPath(dtPolyRef startRef, dtPolyRef endRef,
// The node is already in open list and the new result is worse, skip.
if ((neighbourNode->flags & DT_NODE_OPEN) && total >= neighbourNode->total)
continue;
// The node is already visited and process, and the new result is worse, skip.
if ((neighbourNode->flags & DT_NODE_CLOSED) && total >= neighbourNode->total)
// Never update a closed node's parent even if a cheaper route is found.
// TC's road-bonus area cost (areaCost < 1.0) makes the heuristic
// inadmissible: a cheaper path through a road polygon can arrive at a
// node that is already CLOSED, and the original code would update its
// pidx. If that node is an ancestor of bestNode, a parent-chain cycle
// forms (A.pidx=B while B.pidx=A). getPathToNode then loops forever,
// hanging the world thread until FreezeDetector aborts. Skipping the
// update means paths through roads may be slightly non-optimal, which
// is completely acceptable for bot navigation.
if (neighbourNode->flags & DT_NODE_CLOSED)
continue;
// Add or update the node.
neighbourNode->pidx = m_nodePool->getNodeIdx(bestNode);
neighbourNode->id = neighbourRef;
@@ -1142,9 +1150,20 @@ dtStatus dtNavMeshQuery::getPathToNode(dtNode* endNode, dtPolyRef* path, int* pa
// Find the length of the entire path.
dtNode* curNode = endNode;
int length = 0;
// Guard against infinite loops from parent-chain cycles. A cycle can form
// when findPath updates a CLOSED node's parent (prevented above), or from
// navmesh data corruption. The chain can never be longer than the pool.
int const maxChainLen = m_nodePool->getMaxNodes() + 1;
do
{
length++;
if (length > maxChainLen)
{
// Cycle detected — return failure so PathGenerator treats this as
// PATHFIND_NOPATH rather than hanging the world thread.
*pathCount = 0;
return DT_FAILURE;
}
curNode = m_nodePool->getNodeAtIdx(curNode->pidx);
} while (curNode);
@@ -108,7 +108,24 @@ bool rcBuildHeightfieldLayers(rcContext* ctx, rcCompactHeightfield& chf,
}
memset(srcReg,0xff,sizeof(unsigned char)*chf.spanCount);
const int nsweeps = chf.width;
// TRINITYCORE FIX (same class as recastnavigation issue #317): the sweep
// buffer was sized per grid COLUMN (chf.width) but sweep ids are
// allocated per SPAN below (sid = sweepId++) — a row whose total span
// count exceeds the width (tall stacked geometry; rcCompactCell::count
// is 8 bits, so up to 255 spans per cell) writes sweeps[sid] past the
// allocation. Size by the exact worst case: the maximum total span
// count over any single row. Capped at 256 because sid is an unsigned
// char with 0xff reserved as the "no sweep" sentinel — the sweepId
// exhaustion guard below fails soft before that bound can be exceeded.
int maxSpansPerRow = 0;
for (int y = 0; y < chf.height; ++y)
{
int rowSpans = 0;
for (int x = 0; x < chf.width; ++x)
rowSpans += (int)chf.cells[x+y*chf.width].count;
maxSpansPerRow = rcMax(maxSpansPerRow, rowSpans);
}
const int nsweeps = rcMin(maxSpansPerRow + 2, 256);
rcScopedDelete<rcLayerSweepSpan> sweeps((rcLayerSweepSpan*)rcAlloc(sizeof(rcLayerSweepSpan)*nsweeps, RC_ALLOC_TEMP));
if (!sweeps)
{
@@ -149,6 +166,15 @@ bool rcBuildHeightfieldLayers(rcContext* ctx, rcCompactHeightfield& chf,
if (sid == 0xff)
{
// TRINITYCORE FIX: sweepId is an unsigned char with 0xff
// reserved as the sentinel — 255 sweeps in one row would
// hand out sid==0xff (corrupting the sentinel semantics)
// and then wrap. Fail soft instead.
if (sweepId == 0xff)
{
ctx->log(RC_LOG_ERROR, "rcBuildHeightfieldLayers: too many sweeps in one row (>= 255).");
return false;
}
sid = sweepId++;
sweeps[sid].nei = 0xff;
sweeps[sid].ns = 0;
@@ -62,6 +62,15 @@ static bool buildMeshAdjacency(unsigned short* polys, const int npolys,
if (t[j] == RC_MESH_NULL_IDX) break;
unsigned short v0 = t[j];
unsigned short v1 = (j+1 >= vertsPerPoly || t[j+1] == RC_MESH_NULL_IDX) ? t[0] : t[j+1];
// TRINITYCORE FIX: a polygon referencing a vertex index >= nverts would
// write firstEdge[v0] past the end of the allocation (heap corruption).
// Such indices can only come from corrupted/degenerate input; fail soft.
if (v0 >= nverts || v1 >= nverts)
{
rcFree(firstEdge);
rcFree(edges);
return false;
}
if (v0 < v1)
{
rcEdge& edge = edges[edgeCount];
@@ -87,6 +96,16 @@ static bool buildMeshAdjacency(unsigned short* polys, const int npolys,
if (t[j] == RC_MESH_NULL_IDX) break;
unsigned short v0 = t[j];
unsigned short v1 = (j+1 >= vertsPerPoly || t[j+1] == RC_MESH_NULL_IDX) ? t[0] : t[j+1];
// TRINITYCORE FIX: see matching bounds check in the first edge pass.
// firstEdge[v1] below must not be indexed with a corrupt vertex index;
// a wild value would follow a bogus edge chain and write out of bounds
// through edges[e].
if (v0 >= nverts || v1 >= nverts)
{
rcFree(firstEdge);
rcFree(edges);
return false;
}
if (v0 > v1)
{
for (unsigned short e = firstEdge[v1]; e != RC_MESH_NULL_IDX; e = nextEdge[e])
@@ -340,7 +359,18 @@ static int triangulate(int n, const int* verts, int* indices, int* tris)
{
int ntris = 0;
int* dst = tris;
// TRINITYCORE FIX (no upstream equivalent as of recastnavigation main, 2026-06):
// A degenerate input polygon (n < 3) used to fall through to the final
// "append remaining triangle" block below, reading indices[1]/indices[2]
// out of bounds of the caller's buffer and emitting a triangle with garbage
// indices. removeVertex() can produce such input (nhole < 3) from degenerate
// source polygons; the garbage vertex indices then propagate into
// rcPolyMesh::polys and corrupt the heap in buildMeshAdjacency().
// Fail soft instead: report 0 triangles.
if (n < 3)
return 0;
// The last bit of the index is used to indicate if the vertex can be removed.
for (int i = 0; i < n; i++)
{
@@ -822,6 +852,21 @@ static bool removeVertex(rcContext* ctx, rcPolyMesh& mesh, const unsigned short
break;
}
// TRINITYCORE FIX (no upstream equivalent as of recastnavigation main, 2026-06):
// Degenerate input polygons (e.g. the removed vertex occurring more than once
// in a single polygon, produced by overlapping/duplicated collision geometry)
// can pass canRemoveVertex() yet leave a hole boundary with fewer than 3
// vertices here. Triangulating such a hole read past 'thole'/'hole' and fed
// garbage vertex indices into mesh.polys, corrupting the heap later in
// buildMeshAdjacency(). The mesh is still consistent at this point (the
// degenerate polygons and the vertex have been removed), so leave the
// degenerate hole unfilled and report success.
if (nhole < 3)
{
ctx->log(RC_LOG_WARNING, "removeVertex: Degenerate hole boundary (nhole=%d) while removing vertex %d. Skipping hole triangulation.", nhole, (int)rem);
return true;
}
rcScopedDelete<int> tris((int*)rcAlloc(sizeof(int)*nhole*3, RC_ALLOC_TEMP));
if (!tris)
{
@@ -890,6 +935,15 @@ static bool removeVertex(rcContext* ctx, rcPolyMesh& mesh, const unsigned short
for (int j = 0; j < ntris; ++j)
{
int* t = &tris[j*3];
// TRINITYCORE FIX: defend against out-of-range triangle indices. All
// indices triangulate() emits must address the 'hole'/'hreg'/'harea'
// arrays (size nhole); anything else would read wild memory and store
// garbage vertex indices into mesh.polys (heap corruption downstream).
if (t[0] < 0 || t[0] >= nhole || t[1] < 0 || t[1] >= nhole || t[2] < 0 || t[2] >= nhole)
{
ctx->log(RC_LOG_WARNING, "removeVertex: triangulate() returned out of range index (%d/%d/%d, nhole=%d). Skipping triangle.", t[0], t[1], t[2], nhole);
continue;
}
if (t[0] != t[1] && t[0] != t[2] && t[1] != t[2])
{
polys[npolys*nvp+0] = (unsigned short)hole[t[0]];
@@ -1331,6 +1331,29 @@ struct rcSweepSpan
unsigned short nei; // neighbour id
};
// TRINITYCORE FIX (upstream issue #317, still unfixed in recastnavigation main
// as of 2026-06): rcBuildRegionsMonotone and rcBuildLayerRegions sized their
// 'sweeps' buffer as rcMax(width, height), i.e. one entry per grid column.
// But a new sweep id is allocated per *span* that does not inherit a region
// from its -x neighbour, and a single cell can stack up to 255 spans (layered
// geometry such as multi-floor raid WMOs). On span-dense rows the sweep id
// counter exceeds the buffer size and 'sweeps[previd] = ...' writes past the
// rcAlloc'd allocation (heap corruption). Size the buffer by the worst-case
// span count of any single row instead; each span can introduce at most one
// new sweep id and 'rid' starts at 1, so maxRowSpans+2 entries always suffice.
static int countMaxSpansPerRow(const rcCompactHeightfield& chf)
{
int maxRowSpans = 0;
for (int y = 0; y < chf.height; ++y)
{
int rowSpans = 0;
for (int x = 0; x < chf.width; ++x)
rowSpans += (int)chf.cells[x + y*chf.width].count;
maxRowSpans = rcMax(maxRowSpans, rowSpans);
}
return maxRowSpans;
}
/// @par
///
/// Non-null regions will consist of connected, non-overlapping walkable spans that form a single contour.
@@ -1369,7 +1392,9 @@ bool rcBuildRegionsMonotone(rcContext* ctx, rcCompactHeightfield& chf,
}
memset(srcReg,0,sizeof(unsigned short)*chf.spanCount);
const int nsweeps = rcMax(chf.width,chf.height);
// TRINITYCORE FIX: was rcMax(chf.width,chf.height) — too small for rows with
// stacked spans, leading to out-of-bounds writes. See countMaxSpansPerRow.
const int nsweeps = countMaxSpansPerRow(chf) + 2;
rcScopedDelete<rcSweepSpan> sweeps((rcSweepSpan*)rcAlloc(sizeof(rcSweepSpan)*nsweeps, RC_ALLOC_TEMP));
if (!sweeps)
{
@@ -1425,6 +1450,15 @@ bool rcBuildRegionsMonotone(rcContext* ctx, rcCompactHeightfield& chf,
if (!previd)
{
// TRINITYCORE FIX: 'rid' is 16-bit; if a single row produces
// more than 0xFFFE sweep spans it would wrap and alias earlier
// sweeps (sweeps[] itself is sized for the worst case above).
// Fail soft instead of producing a corrupt region partition.
if (rid == 0xFFFF)
{
ctx->log(RC_LOG_ERROR, "rcBuildRegions(Monotone/Layer): sweep id overflow on row %d.", y);
return false;
}
previd = rid++;
sweeps[previd].rid = previd;
sweeps[previd].ns = 0;
@@ -1467,6 +1501,16 @@ bool rcBuildRegionsMonotone(rcContext* ctx, rcCompactHeightfield& chf,
}
else
{
// TRINITYCORE FIX: region ids share their 16-bit value space with
// the RC_BORDER_REG flag (0x8000). An id reaching that bit would be
// misinterpreted as a border region, and a full 16-bit wrap would
// shrink the 'prev' table below the ids still referenced by
// 'prev[nr]++' (heap corruption). Fail soft before either happens.
if (id >= RC_BORDER_REG)
{
ctx->log(RC_LOG_ERROR, "rcBuildRegions(Monotone/Layer): region id overflow (%d regions).", (int)id);
return false;
}
sweeps[i].id = id++;
}
}
@@ -1678,7 +1722,9 @@ bool rcBuildLayerRegions(rcContext* ctx, rcCompactHeightfield& chf,
}
memset(srcReg,0,sizeof(unsigned short)*chf.spanCount);
const int nsweeps = rcMax(chf.width,chf.height);
// TRINITYCORE FIX: was rcMax(chf.width,chf.height) — too small for rows with
// stacked spans, leading to out-of-bounds writes. See countMaxSpansPerRow.
const int nsweeps = countMaxSpansPerRow(chf) + 2;
rcScopedDelete<rcSweepSpan> sweeps((rcSweepSpan*)rcAlloc(sizeof(rcSweepSpan)*nsweeps, RC_ALLOC_TEMP));
if (!sweeps)
{
@@ -1734,6 +1780,15 @@ bool rcBuildLayerRegions(rcContext* ctx, rcCompactHeightfield& chf,
if (!previd)
{
// TRINITYCORE FIX: 'rid' is 16-bit; if a single row produces
// more than 0xFFFE sweep spans it would wrap and alias earlier
// sweeps (sweeps[] itself is sized for the worst case above).
// Fail soft instead of producing a corrupt region partition.
if (rid == 0xFFFF)
{
ctx->log(RC_LOG_ERROR, "rcBuildRegions(Monotone/Layer): sweep id overflow on row %d.", y);
return false;
}
previd = rid++;
sweeps[previd].rid = previd;
sweeps[previd].ns = 0;
@@ -1776,6 +1831,16 @@ bool rcBuildLayerRegions(rcContext* ctx, rcCompactHeightfield& chf,
}
else
{
// TRINITYCORE FIX: region ids share their 16-bit value space with
// the RC_BORDER_REG flag (0x8000). An id reaching that bit would be
// misinterpreted as a border region, and a full 16-bit wrap would
// shrink the 'prev' table below the ids still referenced by
// 'prev[nr]++' (heap corruption). Fail soft before either happens.
if (id >= RC_BORDER_REG)
{
ctx->log(RC_LOG_ERROR, "rcBuildRegions(Monotone/Layer): region id overflow (%d regions).", (int)id);
return false;
}
sweeps[i].id = id++;
}
}
+13
View File
@@ -0,0 +1,13 @@
# Optional server-owner options
Every option below is OFF in the shipped `worldserver.conf.dist`, which gives the Blizzlike (1.12) behaviour. Turn one on by setting it to `1` in your `worldserver.conf`. No SQL is involved.
| Option | What it does when on | Default |
|---|---|---|
| `Instance.MoltenCoreSkipRunes` | Molten Core without the runes: the seven runes count as doused (no Aqual Quintessence), Majordomo Executus stands in his hall, Ragnaros is in his lair and attackable. A boss already killed in the lockout stays dead. | 0 |
| `Instance.IgnoreAttunement` | No attunement item or quest is needed to enter an instance (Molten Core, Onyxia, Blackwing Lair, Naxxramas and so on). Level limits are separate: `Instance.IgnoreLevel`. | 0 |
| `Instance.AhnQirajGatesOpen` | The Gate of Ahn'Qiraj stands open, so the war effort and the Scarab Gong are not needed to reach Ruins and Temple of Ahn'Qiraj. | 0 |
| `Instance.PersistRaidTrash` | Raid trash that was killed stays dead until the lockout resets, including after you leave the instance, the instance unloads or the server restarts. Needs `Instance.BindOnEntry = 1` for players without a lockout yet. | 0 |
| `Instance.MoltenCoreHoundsLinked` | Core Hounds as in 1.12 (feign death and rise again unless the whole pack dies together). Off (standard): hound packs are unlinked and can be killed one by one. | 0 |
Note: the first four switch off Blizzlike rules; `MoltenCoreHoundsLinked` is the reverse, its off state is the shared default for this project (packs unlinked).
+48
View File
@@ -0,0 +1,48 @@
# Auction house bot
The core already ships TrinityCore's AuctionHouseBot (seller lists items in the neutral/Alliance/Horde
houses, buyer buys player listings, `.ahbot` commands). This branch adds a vanilla-era item filter in
its own files (`AuctionHouseBotVanilla.{h,cpp}`) and a conf preset (`ahbot-vanilla.conf.snippet`).
Seller.cpp has a 3-line hook. Everything stays off unless `AuctionHouseBot.Seller.Enabled = 1`.
Filter (`AuctionHouseBot.Vanilla.Only = 1`): no gems/glyphs, no later-expansion items, quality up to epic,
required level <= `Vanilla.MaxReqLevel` (60), item level <= `Vanilla.MaxItemLevel` (100). Force-include list
(`AuctionHouseBot.forceIncludeItems`) bypasses it. Prices come from vendor buy/sell price x the
`AuctionHouseBot.*.Price.Ratio` keys. Per-bot posting/buying lives separately in
`Bot/States/Rules/AuctionRules.cpp`.
Not built or run in the cloud (no full toolchain): first test is on the PC. Check the startup log for
"AuctionHouseBot seller will use N items" (log channel `ahbot` at debug) and `.ahbot status`.
## Seller names
`AuctionHouseBot.Account` = an account id and `AuctionHouseBot.Sellers.Count` = N: at startup
`AuctionHouseBotSellers.cpp` tops that account up to N named level-60 characters (bare `characters` rows, mixed
Alliance/Horde races, never logged in) so listings show a real seller name. make-configs.ps1 uses account
2000000001 (no real account has it; must stay below 2^31) and 12 characters. Listings made before this change stay nameless.
## Buyer rules and commands
The core buyer (bids/buyouts on player listings, random chance by price) now also follows
`AuctionHouseBotBuyerPolicy.cpp`. Keys (worldserver.conf; all optional):
- `AuctionHouseBot.Buyer.<Alliance|Horde|Neutral>.Enabled` per-house on/off (stock, default 0).
- `AuctionHouseBot.Buyer.Commodities` (0): also buy stackable listings (herbs, ore, cloth), always the whole listing.
- `AuctionHouseBot.Buyer.MaxPriceMultiplier` (1.5): never pay more than this times the fair price per unit
(item vendor buy price, or 4x vendor sell price). 0 = no cap.
- `AuctionHouseBot.Buyer.MinDelay` / `MaxDelay` (30 / 600 seconds): a listing is left alone for a delay in that
range (stable per listing) so purchases don't look instant.
- `AuctionHouseBot.Buyer.DailyBudgetGold` (0 = unlimited) and `AuctionHouseBot.Buyer.MaxBuysPerHour` (60).
- Existing stock keys still apply: `Buyer.ChanceFactor`, `Buyer.ChanceMultiplier.<quality>`, `Buyer.Recheck.Interval`.
The bot never buys its own listings. Each purchase logs `[ahbot] buy <item> xN for <gold> in <house>` (channel `ahbot`, info).
GM commands (console or in game): `.ahbot status [all]` counts per house and quality, `.ahbot stats` buyer spend today and
limits, `.ahbot reload` re-read config, `.ahbot refresh` expire the bot's unbid listings now and restock,
`.ahbot add [n]` raise every active quality target by n per house (default 500) until the next reload,
`.ahbot rebuild [all]` stock command (`all` also expires bid-on bot listings), `.ahbot items ...` / `.ahbot ratio ...` stock.
## Fair-price buying
`AuctionHouseBot.Buyer.Enabled = 1` is the master switch; the per-house keys do nothing without it.
`AuctionHouseBot.Buyer.FairPricing = 1` replaces the stock chance roll: a listing at or under the fair price
(vendor buy price, or 4x vendor sell) is bought with certainty (once past its delay), above that the chance falls
linearly to `Buyer.FairMinChance` (35) percent at `Buyer.MaxPriceMultiplier` times fair, and nothing above the cap sells.
Unsold listings are rechecked every `Buyer.Recheck.Interval` minutes, so a fairly priced item sells in about the listing
delay (30 to 600 s) plus a few rechecks. `AllowTwoSide.Interaction.Auction = 1` (the dist default) puts every auctioneer on
the Neutral house, so stock and buy only there.
+38
View File
@@ -0,0 +1,38 @@
# Vanilla auction house bot preset. Paste into worldserver.conf (server-bot).
# The AH bot is the core's AuctionHouseBot (src/server/game/AuctionHouseBot): the seller lists items
# in all three houses, the buyer buys player listings. Everything is off by default.
# Seller on, filtered to stock level-60 vanilla items (no gems/glyphs, no later expansions).
AuctionHouseBot.Seller.Enabled = 1
AuctionHouseBot.Vanilla.Only = 1
AuctionHouseBot.Vanilla.MaxReqLevel = 60
AuctionHouseBot.Vanilla.MaxItemLevel = 100
# Buyer on in all houses (buys player listings; prices follow vendor price x ratios below).
AuctionHouseBot.Buyer.Alliance.Enabled = 1
AuctionHouseBot.Buyer.Horde.Enabled = 1
AuctionHouseBot.Buyer.Neutral.Enabled = 1
# Items per faction: Amount.<quality> is the target count per house; Ratio scales a house (0 = off).
AuctionHouseBot.Alliance.Items.Amount.Ratio = 100
AuctionHouseBot.Horde.Items.Amount.Ratio = 100
AuctionHouseBot.Neutral.Items.Amount.Ratio = 100
AuctionHouseBot.Items.Amount.Gray = 0
AuctionHouseBot.Items.Amount.White = 1500
AuctionHouseBot.Items.Amount.Green = 1500
AuctionHouseBot.Items.Amount.Blue = 600
AuctionHouseBot.Items.Amount.Purple = 100
# How fast it fills: items per update cycle (Boost applies while a house is under-filled).
AuctionHouseBot.Update.Interval = 20
AuctionHouseBot.ItemsPerCycle.Boost = 1000
AuctionHouseBot.ItemsPerCycle.Normal = 20
# Buy interval: minutes between buyer passes (1..1440).
AuctionHouseBot.Buyer.Recheck.Interval = 5
# Vanilla has no gems/glyphs; keep the gear pool to dropped/crafted items plus vendor stock.
AuctionHouseBot.Items.Vendor = 1
AuctionHouseBot.Items.Loot = 1
AuctionHouseBot.Bind.Pickup = 0
# Optional: list as the characters of a bot account (shows real seller names). Set to an account id.
# AuctionHouseBot.Account = 0
+96
View File
@@ -0,0 +1,96 @@
###################################################################################################
# WoW Forever Bots - OPTIONAL EXTRAS
# Optional extras, not Blizzlike, only applied if you copy this file in.
# Copy it into worldserver.conf.d\ as zz-forever-bots.conf (it is read after playerbot.conf, so it wins).
# The stock worldserver.conf.dist and playerbot.conf.dist keep every one of these OFF. Delete the file to go back.
###################################################################################################
# Raids and instances (core keys)
###################################################################################################
# Not Blizzlike: a solo player may enter a raid (no 40-player raid group needed), so you can walk in and call bots inside.
Instance.IgnoreRaid = 1
# Vanilla lockout rule: you are saved to the raid on entry.
Instance.BindOnEntry = 1
# Killed raid trash stays dead after you leave and come back (it does not respawn until the weekly reset).
Instance.PersistRaidTrash = 1
# Molten Core: Majordomo and Ragnaros are up without dousing the runes.
Instance.MoltenCoreSkipRunes = 1
# No attunement item or quest is needed to enter a raid.
Instance.IgnoreAttunement = 1
# The Gates of Ahn'Qiraj start open.
Instance.AhnQirajGatesOpen = 1
# Stock value (0), listed so you can see it: Molten Core core hound packs are unlinked by default, so they die one by one. See doc/OptionalServerOptions.md.
Instance.MoltenCoreHoundsLinked = 0
###################################################################################################
# Auction house bot (core keys): fills all three houses with level 1-60 vanilla items, buys listings
###################################################################################################
AuctionHouseBot.Seller.Enabled = 1
AuctionHouseBot.Buyer.Alliance.Enabled = 1
AuctionHouseBot.Buyer.Horde.Enabled = 1
AuctionHouseBot.Buyer.Neutral.Enabled = 1
# Reserved account id for the seller characters (no real account; keep it below 2147483647).
AuctionHouseBot.Account = 2000000001
AuctionHouseBot.Sellers.Count = 12
AuctionHouseBot.Vanilla.Only = 1
AuctionHouseBot.Vanilla.MaxReqLevel = 60
AuctionHouseBot.Vanilla.MaxItemLevel = 100
AuctionHouseBot.Items.Amount.White = 3500
AuctionHouseBot.Items.Amount.Green = 3500
AuctionHouseBot.Items.Amount.Blue = 1200
AuctionHouseBot.Items.Amount.Purple = 250
AuctionHouseBot.Items.Vendor = 1
AuctionHouseBot.Class.TradeGood = 10
AuctionHouseBot.Class.Consumable = 8
AuctionHouseBot.Class.Recipe = 6
AuctionHouseBot.Class.Container = 5
AuctionHouseBot.Class.Weapon = 4
AuctionHouseBot.Class.Armor = 4
AuctionHouseBot.Class.Reagent = 2
AuctionHouseBot.Class.Projectile = 3
AuctionHouseBot.Class.Misc = 2
AuctionHouseBot.Class.Quest = 0
AuctionHouseBot.Class.Key = 0
AuctionHouseBot.Class.Gem = 0
AuctionHouseBot.Class.Glyph = 0
AuctionHouseBot.Update.Interval = 10
AuctionHouseBot.ItemsPerCycle.Normal = 100
###################################################################################################
# Logging: bot module lines go to Playerbot.log (rewritten at each start), not the console
###################################################################################################
Appender.Playerbot = 2,3,0,Playerbot.log,w
Logger.playerbot.v2 = 3,Playerbot
Logger.playerbot.api = 3,Playerbot
Logger.ahbot = 3,Console Server
###################################################################################################
# Bots (module keys; every key is documented in playerbot.conf.dist)
###################################################################################################
Playerbot.SharedDatabase = "playerbot"
Playerbot.Raid.Enable = 1
# Cast speed, percent of normal cast time and GCD (GCD never under 750 ms): quicker in raids, slower in PvP.
Playerbot.Cast.Enable = 1
Playerbot.Cast.RaidSpeedPct = 75
Playerbot.Cast.DungeonSpeedPct = 90
Playerbot.Cast.WorldSpeedPct = 100
Playerbot.Cast.BgSpeedPct = 115
Playerbot.Cast.WorldPvpSpeedPct = 115
# Battlegrounds: bots join only when a real player queues.
Playerbot.Bg.AutoSeed.Matches = 0
Playerbot.Bg.AutoJoin = 0
# World bots, stage A: about 300 bots roaming the world (around 4 GB of RAM for the server).
# Weak machine? Use MaxBots 100 and GlobalFill 0 (bots then only appear around you). To switch off: Enable = 0.
Playerbot.Population.TotalTarget = 0
Playerbot.World.Enable = 1
Playerbot.World.FriendlyPct = 100
Playerbot.World.GlobalFill = 1
Playerbot.World.MaxBots = 300
Playerbot.World.BotsPerPlayer = 60
Playerbot.World.PoolMax = 600
Playerbot.World.FillerHubOnly = 1
# The spawner stops adding bots when the worldserver process passes this many MB (0 = no limit).
Playerbot.World.RssBudgetMb = 6000
+1
View File
@@ -2477,6 +2477,7 @@ INSERT INTO `rbac_linked_permissions` VALUES
(195,5),
(195,6),
(195,24),
(195,528),
(195,49),
(195,199),
(196,10),
@@ -5,4 +5,4 @@ INSERT INTO `build_info` (`build`,`majorVersion`,`minorVersion`,`bugfixVersion`,
-- No auth key is known for Win-x64-WoWB 70291 yet; see Network.SkipBuildAuthKeyCheck in worldserver.conf
UPDATE `realmlist` SET `gamebuild`=70291 WHERE `id` IN (70,71,72,73);
-- Forever (this fork): upstream moves realmlist.gamebuild to 70291 here; ours does it in 2026_10_09_01_auth_forever_move_to_70291.sql, so this file no longer touches the realm.
@@ -0,0 +1,18 @@
-- Auth database of the headless test realm ONLY (a throwaway database, never the live one): one game account the headless client logs in
-- with. The 64 byte key is what the Battle.net login would store in account.session_key_bnet; the client derives the world session key
-- from it, so both sides must hold the same bytes (HEADLESS_KEY = the hex below).
--
-- SAFETY: the key is public and the account is GM level 3. Every statement below inserts NOTHING unless the current database name
-- contains "headless" or "test" (case-insensitive), so running this file by hand against a real auth database is a no-op.
-- Name the throwaway auth database accordingly (for example auth_headless_test).
INSERT INTO `battlenet_accounts` (`id`, `email`, `srp_version`, `salt`, `verifier`)
SELECT 900001, '[email protected]', 1, UNHEX(REPEAT('00', 32)), ''
FROM DUAL WHERE LOWER(DATABASE()) REGEXP 'headless|test';
INSERT INTO `account` (`id`, `username`, `salt`, `verifier`, `session_key_bnet`, `email`, `reg_mail`, `expansion`, `client_build`, `battlenet_account`, `battlenet_index`)
SELECT 900001, '900001#1', UNHEX(REPEAT('00', 32)), UNHEX(REPEAT('00', 32)), UNHEX(REPEAT('A5', 64)), '[email protected]', '', 11, 70291, 900001, 1
FROM DUAL WHERE LOWER(DATABASE()) REGEXP 'headless|test';
INSERT INTO `account_access` (`AccountID`, `SecurityLevel`, `RealmID`)
SELECT 900001, 3, -1
FROM DUAL WHERE LOWER(DATABASE()) REGEXP 'headless|test';
@@ -0,0 +1,198 @@
-- Fix for 2026_09_30_01_world_classic_graveyards.sql: its team-only graveyard conditions
-- (CONDITION_SOURCE_TYPE_GRAVEYARD = 27) have SourceGroup and SourceEntry swapped. TrinityCore keys them as
-- SourceGroup = zone (graveyard_zone.GhostZone), SourceEntry = graveyard id (graveyard_zone.ID): see
-- ConditionMgr (FindGraveyardData(SourceEntry, SourceGroup)) and ObjectMgr::AddGraveyardLink. Swapped, no row
-- matched a graveyard_zone link, so every team-only Classic graveyard was open to both factions.
-- Deletes the swapped rows and inserts them with the columns the right way round.
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 27 AND (`SourceGroup`, `SourceEntry`) IN (
(34,215),
(90,141),
(90,1657),
(93,141),
(94,85),
(97,130),
(98,36),
(98,267),
(100,1),
(105,12),
(106,12),
(106,717),
(106,1519),
(106,2257),
(106,2918),
(149,36),
(149,130),
(149,209),
(149,267),
(189,15),
(189,2159),
(289,85),
(429,85),
(429,1497),
(489,11),
(509,28),
(509,2057),
(569,28),
(569,85),
(569,2057),
(610,2597),
(611,2597),
(631,15),
(631,2159),
(649,14),
(709,14),
(729,2597),
(749,2597),
(750,2597),
(751,2597),
(769,3277),
(770,3277),
(771,3277),
(772,3277),
(850,14),
(850,1637),
(850,2437),
(850,2917),
(851,215),
(851,1638),
(852,1),
(852,1537),
(853,85),
(853,1497),
(854,717),
(854,1519),
(854,2257),
(889,3358),
(890,3358),
(893,3358),
(895,3358),
(898,3358),
(899,3358));
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 27 AND (`SourceGroup`, `SourceEntry`) IN (
(215,34),
(141,90),
(1657,90),
(141,93),
(85,94),
(130,97),
(36,98),
(267,98),
(1,100),
(12,105),
(12,106),
(717,106),
(1519,106),
(2257,106),
(2918,106),
(36,149),
(130,149),
(209,149),
(267,149),
(15,189),
(2159,189),
(85,289),
(85,429),
(1497,429),
(11,489),
(28,509),
(2057,509),
(28,569),
(85,569),
(2057,569),
(2597,610),
(2597,611),
(15,631),
(2159,631),
(14,649),
(14,709),
(2597,729),
(2597,749),
(2597,750),
(2597,751),
(3277,769),
(3277,770),
(3277,771),
(3277,772),
(14,850),
(1637,850),
(2437,850),
(2917,850),
(215,851),
(1638,851),
(1,852),
(1537,852),
(85,853),
(1497,853),
(717,854),
(1519,854),
(2257,854),
(3358,889),
(3358,890),
(3358,893),
(3358,895),
(3358,898),
(3358,899));
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `ConditionStringValue1`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(27, 215, 34, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 34 (Mulgore) - Horde only'),
(27, 141, 90, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 90 (Teldrassil) - Alliance only'),
(27, 1657, 90, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 90 (Darnassus) - Alliance only'),
(27, 141, 93, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 93 (Teldrassil) - Alliance only'),
(27, 85, 94, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 94 (Tirisfal Glades) - Horde only'),
(27, 130, 97, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 97 (Silverpine Forest) - Horde only'),
(27, 36, 98, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 98 (Alterac Mountains) - Horde only'),
(27, 267, 98, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 98 (Hillsbrad Foothills) - Horde only'),
(27, 1, 100, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 100 (Dun Morogh) - Alliance only'),
(27, 12, 105, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 105 (Elwynn Forest) - Alliance only'),
(27, 12, 106, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 106 (Elwynn Forest) - Alliance only'),
(27, 717, 106, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 106 (The Stockade) - Alliance only'),
(27, 1519, 106, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 106 (Stormwind City) - Alliance only'),
(27, 2257, 106, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 106 (Deeprun Tram) - Alliance only'),
(27, 2918, 106, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 106 (Champions'' Hall) - Alliance only'),
(27, 36, 149, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 149 (Alterac Mountains) - Alliance only'),
(27, 130, 149, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 149 (Silverpine Forest) - Alliance only'),
(27, 209, 149, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 149 (Shadowfang Keep) - Alliance only'),
(27, 267, 149, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 149 (Hillsbrad Foothills) - Alliance only'),
(27, 15, 189, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 189 (Dustwallow Marsh) - Alliance only'),
(27, 2159, 189, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 189 (Onyxia''s Lair) - Alliance only'),
(27, 85, 289, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 289 (Tirisfal Glades) - Horde only'),
(27, 85, 429, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 429 (Tirisfal Glades) - Alliance only'),
(27, 1497, 429, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 429 (Undercity) - Alliance only'),
(27, 11, 489, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 489 (Wetlands) - Alliance only'),
(27, 28, 509, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 509 (Western Plaguelands) - Alliance only'),
(27, 2057, 509, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 509 (Scholomance) - Alliance only'),
(27, 28, 569, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 569 (Western Plaguelands) - Horde only'),
(27, 85, 569, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 569 (Tirisfal Glades) - Horde only'),
(27, 2057, 569, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 569 (Scholomance) - Horde only'),
(27, 2597, 610, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 610 (Alterac Valley) - Horde only'),
(27, 2597, 611, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 611 (Alterac Valley) - Alliance only'),
(27, 15, 631, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 631 (Dustwallow Marsh) - Horde only'),
(27, 2159, 631, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 631 (Onyxia''s Lair) - Horde only'),
(27, 14, 649, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 649 (Durotar) - Horde only'),
(27, 14, 709, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 709 (Durotar) - Horde only'),
(27, 2597, 729, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 729 (Alterac Valley) - Alliance only'),
(27, 2597, 749, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 749 (Alterac Valley) - Horde only'),
(27, 2597, 750, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 750 (Alterac Valley) - Horde only'),
(27, 2597, 751, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 751 (Alterac Valley) - Alliance only'),
(27, 3277, 769, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 769 (Warsong Gulch) - Alliance only'),
(27, 3277, 770, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 770 (Warsong Gulch) - Horde only'),
(27, 3277, 771, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 771 (Warsong Gulch) - Alliance only'),
(27, 3277, 772, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 772 (Warsong Gulch) - Horde only'),
(27, 14, 850, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 850 (Durotar) - Horde only'),
(27, 1637, 850, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 850 (Orgrimmar) - Horde only'),
(27, 2437, 850, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 850 (Ragefire Chasm) - Horde only'),
(27, 2917, 850, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 850 (Hall of Legends) - Horde only'),
(27, 215, 851, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 851 (Mulgore) - Horde only'),
(27, 1638, 851, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 851 (Thunder Bluff) - Horde only'),
(27, 1, 852, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 852 (Dun Morogh) - Alliance only'),
(27, 1537, 852, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 852 (Ironforge) - Alliance only'),
(27, 85, 853, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 853 (Tirisfal Glades) - Horde only'),
(27, 1497, 853, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 853 (Undercity) - Horde only'),
(27, 717, 854, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 854 (The Stockade) - Horde only'),
(27, 1519, 854, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 854 (Stormwind City) - Horde only'),
(27, 2257, 854, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 854 (Deeprun Tram) - Horde only'),
(27, 3358, 889, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 889 (Arathi Basin) - Horde only'),
(27, 3358, 890, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 890 (Arathi Basin) - Alliance only'),
(27, 3358, 893, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 893 (Arathi Basin) - Horde only'),
(27, 3358, 895, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 895 (Arathi Basin) - Alliance only'),
(27, 3358, 898, 0, 0, 6, 0, 469, 0, 0, '', 0, 0, 0, '', 'Graveyard 898 (Arathi Basin) - Alliance only'),
(27, 3358, 899, 0, 0, 6, 0, 67, 0, 0, '', 0, 0, 0, '', 'Graveyard 899 (Arathi Basin) - Horde only');
@@ -0,0 +1,127 @@
-- Classic Alterac Valley (map 30): classic_battleground_alterac_valley.cpp drives the 1.12 battle on the VMaNGOS spawns
-- (towers, graveyards, captains, generals, mines). It replaces the retail script on map 30, which only knows the retail
-- capture objects. The banners call into the map script through GameObject AI; the world states it sets must belong to
-- map 30 (a world state without map ids is realm-wide); the graveyards go by team and node ownership.
DELETE FROM `battleground_scripts` WHERE `MapId` = 30;
INSERT INTO `battleground_scripts` (`MapId`, `BattlemasterListId`, `ScriptName`) VALUES
(30, 0, 'classic_battleground_alterac_valley');
-- Graveyard banners 178365/178364 (Alliance/Horde), 179286/179287 (assaulted by the Alliance/Horde), Snowfall 180418;
-- bunker banners 178925/179435, tower banners 178943/178940.
UPDATE `gameobject_template` SET `ScriptName` = 'go_classic_av_banner' WHERE `entry` IN (178364, 178365, 179286, 179287, 180418, 178925, 179435, 178943, 178940);
INSERT IGNORE INTO `world_state` (`ID`, `DefaultValue`, `MapIDs`, `AreaIDs`, `ScriptName`, `Comment`) VALUES
(601, 0, '30', NULL, '', 'Classic AV - Drek''Thar alive'),
(602, 0, '30', NULL, '', 'Classic AV - Vanndar alive'),
(1301, 0, '30', NULL, '', 'Classic AV - Stonehearth Graveyard Horde controlled'),
(1302, 0, '30', NULL, '', 'Classic AV - Stonehearth Graveyard Alliance controlled'),
(1303, 0, '30', NULL, '', 'Classic AV - Stonehearth Graveyard assaulted by the Horde'),
(1304, 0, '30', NULL, '', 'Classic AV - Stonehearth Graveyard assaulted by the Alliance'),
(1325, 0, '30', NULL, '', 'Classic AV - Stormpike Aid Station Alliance controlled'),
(1326, 0, '30', NULL, '', 'Classic AV - Stormpike Aid Station assaulted by the Alliance'),
(1327, 0, '30', NULL, '', 'Classic AV - Stormpike Aid Station Horde controlled'),
(1328, 0, '30', NULL, '', 'Classic AV - Stormpike Aid Station assaulted by the Horde'),
(1329, 0, '30', NULL, '', 'Classic AV - Frostwolf Relief Hut Alliance controlled'),
(1330, 0, '30', NULL, '', 'Classic AV - Frostwolf Relief Hut Horde controlled'),
(1331, 0, '30', NULL, '', 'Classic AV - Frostwolf Relief Hut assaulted by the Alliance'),
(1332, 0, '30', NULL, '', 'Classic AV - Frostwolf Relief Hut assaulted by the Horde'),
(1333, 0, '30', NULL, '', 'Classic AV - Stormpike Graveyard Alliance controlled'),
(1334, 0, '30', NULL, '', 'Classic AV - Stormpike Graveyard Horde controlled'),
(1335, 0, '30', NULL, '', 'Classic AV - Stormpike Graveyard assaulted by the Alliance'),
(1336, 0, '30', NULL, '', 'Classic AV - Stormpike Graveyard assaulted by the Horde'),
(1337, 0, '30', NULL, '', 'Classic AV - Frostwolf Graveyard Alliance controlled'),
(1338, 0, '30', NULL, '', 'Classic AV - Frostwolf Graveyard Horde controlled'),
(1339, 0, '30', NULL, '', 'Classic AV - Frostwolf Graveyard assaulted by the Alliance'),
(1340, 0, '30', NULL, '', 'Classic AV - Frostwolf Graveyard assaulted by the Horde'),
(1341, 0, '30', NULL, '', 'Classic AV - Snowfall Graveyard Alliance controlled'),
(1342, 0, '30', NULL, '', 'Classic AV - Snowfall Graveyard Horde controlled'),
(1343, 0, '30', NULL, '', 'Classic AV - Snowfall Graveyard assaulted by the Alliance'),
(1344, 0, '30', NULL, '', 'Classic AV - Snowfall Graveyard assaulted by the Horde'),
(1346, 0, '30', NULL, '', 'Classic AV - Iceblood Graveyard Alliance controlled'),
(1347, 0, '30', NULL, '', 'Classic AV - Iceblood Graveyard Horde controlled'),
(1348, 0, '30', NULL, '', 'Classic AV - Iceblood Graveyard assaulted by the Alliance'),
(1349, 0, '30', NULL, '', 'Classic AV - Iceblood Graveyard assaulted by the Horde'),
(1351, 0, '30', NULL, '', 'Classic AV - Balinda alive'),
(1352, 0, '30', NULL, '', 'Classic AV - Galvangar alive'),
(1355, 0, '30', NULL, '', 'Classic AV - Coldtooth Mine Alliance'),
(1356, 0, '30', NULL, '', 'Classic AV - Coldtooth Mine Horde'),
(1357, 0, '30', NULL, '', 'Classic AV - Coldtooth Mine kobolds'),
(1358, 0, '30', NULL, '', 'Classic AV - Irondeep Mine Alliance'),
(1359, 0, '30', NULL, '', 'Classic AV - Irondeep Mine Horde'),
(1360, 0, '30', NULL, '', 'Classic AV - Irondeep Mine troggs'),
(1361, 0, '30', NULL, '', 'Classic AV - Dun Baldar South Bunker Alliance controlled'),
(1362, 0, '30', NULL, '', 'Classic AV - Dun Baldar North Bunker Alliance controlled'),
(1363, 0, '30', NULL, '', 'Classic AV - Icewing Bunker Alliance controlled'),
(1364, 0, '30', NULL, '', 'Classic AV - Stonehearth Bunker Alliance controlled'),
(1365, 0, '30', NULL, '', 'Classic AV - West Frostwolf Tower destroyed by the Alliance'),
(1366, 0, '30', NULL, '', 'Classic AV - East Frostwolf Tower destroyed by the Alliance'),
(1367, 0, '30', NULL, '', 'Classic AV - Tower Point destroyed by the Alliance'),
(1368, 0, '30', NULL, '', 'Classic AV - Iceblood Tower destroyed by the Alliance'),
(1370, 0, '30', NULL, '', 'Classic AV - Dun Baldar South Bunker destroyed by the Horde'),
(1371, 0, '30', NULL, '', 'Classic AV - Dun Baldar North Bunker destroyed by the Horde'),
(1372, 0, '30', NULL, '', 'Classic AV - Icewing Bunker destroyed by the Horde'),
(1373, 0, '30', NULL, '', 'Classic AV - Stonehearth Bunker destroyed by the Horde'),
(1374, 0, '30', NULL, '', 'Classic AV - Dun Baldar North Bunker assaulted by the Alliance'),
(1375, 0, '30', NULL, '', 'Classic AV - Dun Baldar South Bunker assaulted by the Alliance'),
(1376, 0, '30', NULL, '', 'Classic AV - Icewing Bunker assaulted by the Alliance'),
(1377, 0, '30', NULL, '', 'Classic AV - Stonehearth Bunker assaulted by the Alliance'),
(1378, 0, '30', NULL, '', 'Classic AV - Dun Baldar South Bunker assaulted by the Horde'),
(1379, 0, '30', NULL, '', 'Classic AV - Dun Baldar North Bunker assaulted by the Horde'),
(1380, 0, '30', NULL, '', 'Classic AV - Icewing Bunker assaulted by the Horde'),
(1381, 0, '30', NULL, '', 'Classic AV - Stonehearth Bunker assaulted by the Horde'),
(1382, 0, '30', NULL, '', 'Classic AV - West Frostwolf Tower Horde controlled'),
(1383, 0, '30', NULL, '', 'Classic AV - East Frostwolf Tower Horde controlled'),
(1384, 0, '30', NULL, '', 'Classic AV - Tower Point Horde controlled'),
(1385, 0, '30', NULL, '', 'Classic AV - Iceblood Tower Horde controlled'),
(1387, 0, '30', NULL, '', 'Classic AV - West Frostwolf Tower assaulted by the Alliance'),
(1388, 0, '30', NULL, '', 'Classic AV - East Frostwolf Tower assaulted by the Alliance'),
(1389, 0, '30', NULL, '', 'Classic AV - Tower Point assaulted by the Alliance'),
(1390, 0, '30', NULL, '', 'Classic AV - Iceblood Tower assaulted by the Alliance'),
(1392, 0, '30', NULL, '', 'Classic AV - West Frostwolf Tower assaulted by the Horde'),
(1393, 0, '30', NULL, '', 'Classic AV - East Frostwolf Tower assaulted by the Horde'),
(1394, 0, '30', NULL, '', 'Classic AV - Tower Point assaulted by the Horde'),
(1395, 0, '30', NULL, '', 'Classic AV - Iceblood Tower assaulted by the Horde'),
(1966, 0, '30', NULL, '', 'Classic AV - Snowfall Graveyard neutral'),
(3127, 0, '30', NULL, '', 'Classic AV - Alliance reinforcements'),
(3128, 0, '30', NULL, '', 'Classic AV - Horde reinforcements'),
(3133, 0, '30', NULL, '', 'Classic AV - Show Horde reinforcements'),
(3134, 0, '30', NULL, '', 'Classic AV - Show Alliance reinforcements');
UPDATE `world_state` SET `MapIDs` = CONCAT(`MapIDs`, ',30') WHERE `ID` IN (601,602,1301,1302,1303,1304,1325,1326,1327,1328,1329,1330,1331,1332,1333,1334,1335,1336,1337,1338,1339,1340,1341,1342,1343,1344,1346,1347,1348,1349,1351,1352,1355,1356,1357,1358,1359,1360,1361,1362,1363,1364,1365,1366,1367,1368,1370,1371,1372,1373,1374,1375,1376,1377,1378,1379,1380,1381,1382,1383,1384,1385,1387,1388,1389,1390,1392,1393,1394,1395,1966,3127,3128,3133,3134) AND `MapIDs` IS NOT NULL AND `MapIDs` <> '' AND FIND_IN_SET('30', `MapIDs`) = 0;
-- Graveyards (VMaNGOS GetClosestGraveYard): the cave graveyards by team; a node graveyard while the team controls the
-- node (its node world state). The classic graveyard list has every one but Frostwolf Graveyard (690).
INSERT IGNORE INTO `graveyard_zone` (`ID`, `GhostZone`, `Comment`) VALUES
(690, 2597, 'Alterac Valley - Alterac Valley, Frostwolf Graveyard');
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 27 AND `SourceGroup` = 2597 AND `SourceEntry` IN (610,611,169,689,690,729,749,750,751);
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `ConditionStringValue1`, `NegativeCondition`, `Comment`) VALUES
(27, 2597, 611, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Alliance cave graveyard - Alliance only'),
(27, 2597, 610, 0, 0, 6, 0, 67, 0, 0, '', 0, 'Classic AV Horde cave graveyard - Horde only'),
(27, 2597, 751, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Stormpike Aid Station - Alliance'),
(27, 2597, 751, 0, 0, 11, 0, 1325, 1, 0, '', 0, 'Classic AV Stormpike Aid Station - while the Alliance controls it'),
(27, 2597, 751, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AV Stormpike Aid Station - Horde'),
(27, 2597, 751, 0, 1, 11, 0, 1327, 1, 0, '', 0, 'Classic AV Stormpike Aid Station - while the Horde controls it'),
(27, 2597, 689, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Stormpike Graveyard - Alliance'),
(27, 2597, 689, 0, 0, 11, 0, 1333, 1, 0, '', 0, 'Classic AV Stormpike Graveyard - while the Alliance controls it'),
(27, 2597, 689, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AV Stormpike Graveyard - Horde'),
(27, 2597, 689, 0, 1, 11, 0, 1334, 1, 0, '', 0, 'Classic AV Stormpike Graveyard - while the Horde controls it'),
(27, 2597, 729, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Stonehearth Graveyard - Alliance'),
(27, 2597, 729, 0, 0, 11, 0, 1302, 1, 0, '', 0, 'Classic AV Stonehearth Graveyard - while the Alliance controls it'),
(27, 2597, 729, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AV Stonehearth Graveyard - Horde'),
(27, 2597, 729, 0, 1, 11, 0, 1301, 1, 0, '', 0, 'Classic AV Stonehearth Graveyard - while the Horde controls it'),
(27, 2597, 169, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Snowfall Graveyard - Alliance'),
(27, 2597, 169, 0, 0, 11, 0, 1341, 1, 0, '', 0, 'Classic AV Snowfall Graveyard - while the Alliance controls it'),
(27, 2597, 169, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AV Snowfall Graveyard - Horde'),
(27, 2597, 169, 0, 1, 11, 0, 1342, 1, 0, '', 0, 'Classic AV Snowfall Graveyard - while the Horde controls it'),
(27, 2597, 749, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Iceblood Graveyard - Alliance'),
(27, 2597, 749, 0, 0, 11, 0, 1346, 1, 0, '', 0, 'Classic AV Iceblood Graveyard - while the Alliance controls it'),
(27, 2597, 749, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AV Iceblood Graveyard - Horde'),
(27, 2597, 749, 0, 1, 11, 0, 1347, 1, 0, '', 0, 'Classic AV Iceblood Graveyard - while the Horde controls it'),
(27, 2597, 690, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Frostwolf Graveyard - Alliance'),
(27, 2597, 690, 0, 0, 11, 0, 1337, 1, 0, '', 0, 'Classic AV Frostwolf Graveyard - while the Alliance controls it'),
(27, 2597, 690, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AV Frostwolf Graveyard - Horde'),
(27, 2597, 690, 0, 1, 11, 0, 1338, 1, 0, '', 0, 'Classic AV Frostwolf Graveyard - while the Horde controls it'),
(27, 2597, 750, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AV Frostwolf Relief Hut - Alliance'),
(27, 2597, 750, 0, 0, 11, 0, 1329, 1, 0, '', 0, 'Classic AV Frostwolf Relief Hut - while the Alliance controls it'),
(27, 2597, 750, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AV Frostwolf Relief Hut - Horde'),
(27, 2597, 750, 0, 1, 11, 0, 1330, 1, 0, '', 0, 'Classic AV Frostwolf Relief Hut - while the Horde controls it');
@@ -0,0 +1,96 @@
-- Sorts after 2026_10_06_90_world_classic_graveyard_conditions_fix.sql on purpose: that file rewrites every Classic
-- graveyard condition, including the WSG/AB ones, and the AB node graveyards here depend on the node world states.
-- Classic Warsong Gulch (map 489) and Arathi Basin (map 529): classic_battleground_warsong_gulch.cpp and
-- classic_battleground_arathi_basin.cpp drive the 1.12 flags and banners. Their objects call into the map script
-- through GameObject AI, and the world states they set must belong to the classic maps (a world state without
-- map ids is realm-wide). Existing rows (the retail remakes on 2106/2107 use the same ids) get the classic map added.
-- The map scripts bind by name through battleground_scripts (none existed for the classic maps).
DELETE FROM `battleground_scripts` WHERE `MapId` IN (489, 529);
INSERT INTO `battleground_scripts` (`MapId`, `BattlemasterListId`, `ScriptName`) VALUES
(489, 0, 'classic_battleground_warsong_gulch'),
(529, 0, 'classic_battleground_arathi_basin');
UPDATE `gameobject_template` SET `ScriptName` = 'go_classic_wsg_flag' WHERE `entry` IN (179830, 179831, 179785, 179786);
UPDATE `gameobject_template` SET `ScriptName` = 'go_classic_ab_banner' WHERE `entry` IN (180058, 180059, 180060, 180061, 180087, 180088, 180089, 180090, 180091);
-- Warsong Gulch
INSERT IGNORE INTO `world_state` (`ID`, `DefaultValue`, `MapIDs`, `AreaIDs`, `ScriptName`, `Comment`) VALUES
(1545, 0, '489', NULL, '', 'Classic WSG - Alliance flag taken'),
(1546, 0, '489', NULL, '', 'Classic WSG - Horde flag taken'),
(1581, 0, '489', NULL, '', 'Classic WSG - Alliance flag captures'),
(1582, 0, '489', NULL, '', 'Classic WSG - Horde flag captures'),
(1601, 0, '489', NULL, '', 'Classic WSG - Max flag captures'),
(2338, 0, '489', NULL, '', 'Classic WSG - Horde flag carrier state'),
(2339, 0, '489', NULL, '', 'Classic WSG - Alliance flag carrier state');
UPDATE `world_state` SET `MapIDs` = CONCAT(`MapIDs`, ',489') WHERE `ID` IN (1545,1546,1581,1582,1601,2338,2339) AND `MapIDs` IS NOT NULL AND `MapIDs` <> '' AND FIND_IN_SET('489', `MapIDs`) = 0;
-- Arathi Basin
INSERT IGNORE INTO `world_state` (`ID`, `DefaultValue`, `MapIDs`, `AreaIDs`, `ScriptName`, `Comment`) VALUES
(1767, 0, '529', NULL, '', 'Classic AB - Stables Alliance'),
(1768, 0, '529', NULL, '', 'Classic AB - Stables Horde'),
(1769, 0, '529', NULL, '', 'Classic AB - Stables contested by Alliance'),
(1770, 0, '529', NULL, '', 'Classic AB - Stables contested by Horde'),
(1772, 0, '529', NULL, '', 'Classic AB - Farm Alliance'),
(1773, 0, '529', NULL, '', 'Classic AB - Farm Horde'),
(1774, 0, '529', NULL, '', 'Classic AB - Farm contested by Alliance'),
(1775, 0, '529', NULL, '', 'Classic AB - Farm contested by Horde'),
(1776, 0, '529', NULL, '', 'Classic AB - Alliance resources'),
(1777, 0, '529', NULL, '', 'Classic AB - Horde resources'),
(1778, 0, '529', NULL, '', 'Classic AB - Horde occupied bases'),
(1779, 0, '529', NULL, '', 'Classic AB - Alliance occupied bases'),
(1780, 0, '529', NULL, '', 'Classic AB - Max resources'),
(1782, 0, '529', NULL, '', 'Classic AB - Blacksmith Alliance'),
(1783, 0, '529', NULL, '', 'Classic AB - Blacksmith Horde'),
(1784, 0, '529', NULL, '', 'Classic AB - Blacksmith contested by Alliance'),
(1785, 0, '529', NULL, '', 'Classic AB - Blacksmith contested by Horde'),
(1787, 0, '529', NULL, '', 'Classic AB - Gold Mine Alliance'),
(1788, 0, '529', NULL, '', 'Classic AB - Gold Mine Horde'),
(1789, 0, '529', NULL, '', 'Classic AB - Gold Mine contested by Alliance'),
(1790, 0, '529', NULL, '', 'Classic AB - Gold Mine contested by Horde'),
(1792, 0, '529', NULL, '', 'Classic AB - Lumber Mill Alliance'),
(1793, 0, '529', NULL, '', 'Classic AB - Lumber Mill Horde'),
(1794, 0, '529', NULL, '', 'Classic AB - Lumber Mill contested by Alliance'),
(1795, 0, '529', NULL, '', 'Classic AB - Lumber Mill contested by Horde'),
(1842, 0, '529', NULL, '', 'Classic AB - Stables neutral icon'),
(1843, 0, '529', NULL, '', 'Classic AB - Gold Mine neutral icon'),
(1844, 0, '529', NULL, '', 'Classic AB - Lumber Mill neutral icon'),
(1845, 0, '529', NULL, '', 'Classic AB - Farm neutral icon'),
(1846, 0, '529', NULL, '', 'Classic AB - Blacksmith neutral icon'),
(1861, 0, '529', NULL, '', 'Classic AB - Unknown (1.12 sends 2)'),
(1955, 0, '529', NULL, '', 'Classic AB - Resources warning');
UPDATE `world_state` SET `MapIDs` = CONCAT(`MapIDs`, ',529') WHERE `ID` IN (1767,1768,1769,1770,1772,1773,1774,1775,1776,1777,1778,1779,1780,1782,1783,1784,1785,1787,1788,1789,1790,1792,1793,1794,1795,1842,1843,1844,1845,1846,1861,1955) AND `MapIDs` IS NOT NULL AND `MapIDs` <> '' AND FIND_IN_SET('529', `MapIDs`) = 0;
-- Graveyards. graveyard_zone already lists the classic graveyards (WSG 769-772, AB 889-899); without conditions every team
-- could release at every one of them. Bases/entrances go by team; an AB node graveyard only while that team holds the
-- node (the 1.12 node world states the AB script sets). 1.12 had no other rule (VMaNGOS GetClosestGraveYard).
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 27 AND `SourceGroup` IN (3277, 3358) AND `SourceEntry` IN (769,770,771,772,889,890,893,894,895,896,897,898,899);
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `ConditionStringValue1`, `NegativeCondition`, `Comment`) VALUES
(27, 3277, 769, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic WSG Alliance start graveyard - Alliance only'),
(27, 3277, 771, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic WSG Alliance base graveyard - Alliance only'),
(27, 3277, 770, 0, 0, 6, 0, 67, 0, 0, '', 0, 'Classic WSG Horde start graveyard - Horde only'),
(27, 3277, 772, 0, 0, 6, 0, 67, 0, 0, '', 0, 'Classic WSG Horde base graveyard - Horde only'),
(27, 3358, 890, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AB Alliance entrance graveyard - Alliance only'),
(27, 3358, 898, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AB Trollbane Hall graveyard - Alliance only'),
(27, 3358, 889, 0, 0, 6, 0, 67, 0, 0, '', 0, 'Classic AB Horde entrance graveyard - Horde only'),
(27, 3358, 899, 0, 0, 6, 0, 67, 0, 0, '', 0, 'Classic AB Defiler\'s Den graveyard - Horde only'),
(27, 3358, 895, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AB Stables graveyard - Alliance'),
(27, 3358, 895, 0, 0, 11, 0, 1767, 1, 0, '', 0, 'Classic AB Stables graveyard - while the Alliance holds it'),
(27, 3358, 895, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AB Stables graveyard - Horde'),
(27, 3358, 895, 0, 1, 11, 0, 1768, 1, 0, '', 0, 'Classic AB Stables graveyard - while the Horde holds it'),
(27, 3358, 894, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AB Blacksmith graveyard - Alliance'),
(27, 3358, 894, 0, 0, 11, 0, 1782, 1, 0, '', 0, 'Classic AB Blacksmith graveyard - while the Alliance holds it'),
(27, 3358, 894, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AB Blacksmith graveyard - Horde'),
(27, 3358, 894, 0, 1, 11, 0, 1783, 1, 0, '', 0, 'Classic AB Blacksmith graveyard - while the Horde holds it'),
(27, 3358, 893, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AB Farm graveyard - Alliance'),
(27, 3358, 893, 0, 0, 11, 0, 1772, 1, 0, '', 0, 'Classic AB Farm graveyard - while the Alliance holds it'),
(27, 3358, 893, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AB Farm graveyard - Horde'),
(27, 3358, 893, 0, 1, 11, 0, 1773, 1, 0, '', 0, 'Classic AB Farm graveyard - while the Horde holds it'),
(27, 3358, 897, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AB Lumber Mill graveyard - Alliance'),
(27, 3358, 897, 0, 0, 11, 0, 1792, 1, 0, '', 0, 'Classic AB Lumber Mill graveyard - while the Alliance holds it'),
(27, 3358, 897, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AB Lumber Mill graveyard - Horde'),
(27, 3358, 897, 0, 1, 11, 0, 1793, 1, 0, '', 0, 'Classic AB Lumber Mill graveyard - while the Horde holds it'),
(27, 3358, 896, 0, 0, 6, 0, 469, 0, 0, '', 0, 'Classic AB Gold Mine graveyard - Alliance'),
(27, 3358, 896, 0, 0, 11, 0, 1787, 1, 0, '', 0, 'Classic AB Gold Mine graveyard - while the Alliance holds it'),
(27, 3358, 896, 0, 1, 6, 0, 67, 0, 0, '', 0, 'Classic AB Gold Mine graveyard - Horde'),
(27, 3358, 896, 0, 1, 11, 0, 1788, 1, 0, '', 0, 'Classic AB Gold Mine graveyard - while the Horde holds it');
@@ -0,0 +1,10 @@
-- Classic Life Tap (all six ranks) did nothing: the client spell data has a dummy effect no core code handled.
-- 1454 was bound to the retail trigger script; replace it with the Classic implementation.
DELETE FROM `spell_script_names` WHERE `spell_id` IN (1454, 1455, 1456, 11687, 11688, 11689);
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
(1454, 'spell_warl_classic_life_tap'),
(1455, 'spell_warl_classic_life_tap'),
(1456, 'spell_warl_classic_life_tap'),
(11687, 'spell_warl_classic_life_tap'),
(11688, 'spell_warl_classic_life_tap'),
(11689, 'spell_warl_classic_life_tap');
@@ -0,0 +1,14 @@
DROP TABLE IF EXISTS `classic_creature_spell_value`;
-- Classic 1.60: table for the vanilla (1.12) spell values (classic_spell_value). No rows here: they are built from the server owner's own VMaNGOS dump by
-- tools/classic_spell_values/build_vanilla_data.py (see tools/classic_spell_values/README.md). An empty table changes nothing. Safe to run again.
CREATE TABLE IF NOT EXISTS `classic_spell_value` (
`spell_id` int unsigned NOT NULL,
`effect_index` tinyint unsigned NOT NULL,
`effect` smallint unsigned NOT NULL COMMENT 'SpellEffects, must equal the client effect at that index',
`apply_aura` smallint unsigned NOT NULL DEFAULT 0 COMMENT 'AuraType of an aura effect, must equal the client one',
`base_points` int NOT NULL COMMENT 'vanilla base points; the die comes on top',
`die_sides` int NOT NULL DEFAULT 0 COMMENT 'vanilla die sides: 0 none, n adds 1..n',
`points_per_level` float NOT NULL DEFAULT 0 COMMENT 'vanilla real points per level',
`spell_name` varchar(100) NOT NULL DEFAULT '',
PRIMARY KEY (`spell_id`,`effect_index`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='Classic 1.60: vanilla 1.12 spell values for every caster';
@@ -0,0 +1,8 @@
-- Molten Core Flame Imp (11669, 50 spawns) uses CreatureDisplayID 12190, which the 70291 client cannot draw (`.morph 12190`
-- shows the blue-white checkered box). Move only the Flame Imp to display 4449 (the plain imp model, confirmed with `.morph 4449`).
-- Other 12190 users are left alone. Safe to run again.
UPDATE `creature_template_model` SET `CreatureDisplayID`=4449 WHERE `CreatureID`=11669 AND `CreatureDisplayID`=12190;
-- Only if 4449 has no creature_model_info row: copy the size values of the old display.
INSERT INTO `creature_model_info` (`DisplayID`,`BoundingRadius`,`CombatReach`,`VerifiedBuild`)
SELECT 4449,`BoundingRadius`,`CombatReach`,`VerifiedBuild` FROM `creature_model_info` WHERE `DisplayID`=12190
AND NOT EXISTS (SELECT 1 FROM (SELECT `DisplayID` FROM `creature_model_info` WHERE `DisplayID`=4449) x);
@@ -0,0 +1,27 @@
-- Classic 1.60: schema for taking more of the VMaNGOS 1.12 numbers across. No data here (the generated files that follow fill it);
-- an empty column or table changes nothing. Safe to run again.
-- * classic_spell_value.misc_value / points_per_combo / bonus_coeff: aura effects are matched on their misc value, finishers get their vanilla points per combo point
-- * classic_spell_cost: vanilla mana cost of the legacy spells (flat + percent of base mana)
-- * player_classlevelstats.basemana: vanilla base mana of the class at the level (0 = keep the client's game table value)
SET @sql := IF((SELECT COUNT(*) FROM information_schema.COLUMNS WHERE TABLE_SCHEMA = DATABASE() AND TABLE_NAME = 'classic_spell_value' AND COLUMN_NAME = 'misc_value') = 0,
'ALTER TABLE `classic_spell_value` ADD COLUMN `misc_value` int NOT NULL DEFAULT 0 COMMENT ''vanilla effectMiscValue, must equal the client one for aura effects'' AFTER `points_per_level`', 'SELECT 1');
PREPARE stmt FROM @sql; EXECUTE stmt; DEALLOCATE PREPARE stmt;
SET @sql := IF((SELECT COUNT(*) FROM information_schema.COLUMNS WHERE TABLE_SCHEMA = DATABASE() AND TABLE_NAME = 'classic_spell_value' AND COLUMN_NAME = 'points_per_combo') = 0,
'ALTER TABLE `classic_spell_value` ADD COLUMN `points_per_combo` float NOT NULL DEFAULT 0 COMMENT ''vanilla effectPointsPerComboPoint'' AFTER `misc_value`', 'SELECT 1');
PREPARE stmt FROM @sql; EXECUTE stmt; DEALLOCATE PREPARE stmt;
SET @sql := IF((SELECT COUNT(*) FROM information_schema.COLUMNS WHERE TABLE_SCHEMA = DATABASE() AND TABLE_NAME = 'classic_spell_value' AND COLUMN_NAME = 'bonus_coeff') = 0,
'ALTER TABLE `classic_spell_value` ADD COLUMN `bonus_coeff` float NOT NULL DEFAULT -1 COMMENT ''vanilla effectBonusCoefficient (spell / healing power factor), -1 = keep the client one'' AFTER `points_per_combo`', 'SELECT 1');
PREPARE stmt FROM @sql; EXECUTE stmt; DEALLOCATE PREPARE stmt;
CREATE TABLE IF NOT EXISTS `classic_spell_cost` (
`spell_id` int unsigned NOT NULL,
`mana_cost` int NOT NULL DEFAULT 0 COMMENT 'vanilla manaCost',
`mana_cost_pct` int NOT NULL DEFAULT 0 COMMENT 'vanilla manaCostPercentage, of the caster base mana',
`spell_name` varchar(100) NOT NULL DEFAULT '',
PRIMARY KEY (`spell_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='Classic 1.60: vanilla 1.12 mana cost of the legacy spells';
SET @sql := IF((SELECT COUNT(*) FROM information_schema.COLUMNS WHERE TABLE_SCHEMA = DATABASE() AND TABLE_NAME = 'player_classlevelstats' AND COLUMN_NAME = 'basemana') = 0,
'ALTER TABLE `player_classlevelstats` ADD COLUMN `basemana` int unsigned NOT NULL DEFAULT 0 COMMENT ''vanilla base mana (VMaNGOS), 0 = client game table''', 'SELECT 1');
PREPARE stmt FROM @sql; EXECUTE stmt; DEALLOCATE PREPARE stmt;
@@ -0,0 +1,6 @@
-- Classic 1.60: table for the vanilla creature melee numbers (creature_classic_melee). No rows here: they are built from the server owner's own VMaNGOS dump by
-- tools/classic_spell_values/build_vanilla_data.py (see tools/classic_spell_values/README.md). An empty table changes nothing. Safe to run again.
CREATE TABLE IF NOT EXISTS `creature_classic_melee` (
`entry` int unsigned NOT NULL, `dmg_min` float NOT NULL, `dmg_max` float NOT NULL, `attack_ms` int unsigned NOT NULL, `ranged_attack_ms` int unsigned NOT NULL,
PRIMARY KEY (`entry`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
@@ -0,0 +1,7 @@
-- Classic 1.60: table for the vanilla spell timing (classic_spell_info). No rows here: they are built from the server owner's own VMaNGOS dump by
-- tools/classic_spell_values/build_vanilla_data.py (see tools/classic_spell_values/README.md). An empty table changes nothing. Safe to run again.
CREATE TABLE IF NOT EXISTS `classic_spell_info` (
`spell_id` int unsigned NOT NULL, `cast_ms` int DEFAULT NULL, `recovery_ms` int DEFAULT NULL, `category_recovery_ms` int DEFAULT NULL,
`duration_ms` int DEFAULT NULL, `range_max` float DEFAULT NULL, `radius1` float DEFAULT NULL, `radius2` float DEFAULT NULL, `radius3` float DEFAULT NULL,
`spell_name` varchar(100) NOT NULL DEFAULT '', PRIMARY KEY (`spell_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
@@ -0,0 +1,3 @@
-- Classic 1.60: table for the Forever twins of vanilla spells (classic_spell_twin). No rows here: they are built from the server owner's own VMaNGOS dump by
-- tools/classic_spell_values/build_vanilla_data.py (see tools/classic_spell_values/README.md). An empty table changes nothing. Safe to run again.
CREATE TABLE IF NOT EXISTS `classic_spell_twin` (`spell_id` int unsigned NOT NULL, `vanilla_spell_id` int unsigned NOT NULL, `spell_name` varchar(100) NOT NULL DEFAULT '', PRIMARY KEY (`spell_id`)) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
@@ -0,0 +1,10 @@
-- Classic 1.60: Alterac Valley has a level 60 hostile "Grimtooth" (entry 603) at (-1594, -410, 81.5) that vanilla never spawned (the VMaNGOS dump has the
-- template but no spawn anywhere). Removes his spawns on map 30, with the rows that hang off those spawns. Safe to run again.
-- The spawn guids are read from `creature` itself (still holding the rows until the last statement): a TEMPORARY table cannot be named twice in one statement.
DELETE FROM `creature_addon` WHERE `guid` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603);
DELETE FROM `creature_formations` WHERE `memberGUID` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603) OR `leaderGUID` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603);
DELETE FROM `creature_movement_override` WHERE `SpawnId` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603);
DELETE FROM `linked_respawn` WHERE `guid` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603) OR `linkedGuid` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603);
DELETE FROM `game_event_creature` WHERE `guid` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603);
DELETE FROM `pool_members` WHERE `type` = 0 AND `spawnId` IN (SELECT `guid` FROM `creature` WHERE `map` = 30 AND `id` = 603);
DELETE FROM `creature` WHERE `map` = 30 AND `id` = 603;
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
+84
View File
@@ -0,0 +1,84 @@
-- Migration: 0001_init
-- Date: 2026-05-01
-- Purpose: Bootstrap V2 schema. Creates the version table and the minimal
-- set of bot-specific tables documented in v2/SCHEMA.md.
-- Reverts: yes (all DROP TABLE).
-- Per v2/SCHEMA.md: bot character data lives in TrinityCore's `characters`
-- table. V2 owns ONLY what TrinityCore doesn't already store. No mirror
-- tables are permitted.
CREATE TABLE IF NOT EXISTS playerbot_v2_schema_version (
version INT UNSIGNED NOT NULL PRIMARY KEY,
applied_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
sha256 CHAR(64) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS playerbot_v2_account (
account_id INT UNSIGNED NOT NULL PRIMARY KEY,
pseudo_account_idx INT UNSIGNED NOT NULL,
created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
last_used_at DATETIME NULL,
KEY idx_pseudo (pseudo_account_idx)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS playerbot_v2_character (
character_guid_low BIGINT UNSIGNED NOT NULL PRIMARY KEY,
spawned_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
last_active_at DATETIME NULL,
rng_seed BIGINT UNSIGNED NOT NULL,
spawn_state TINYINT UNSIGNED NOT NULL,
KEY idx_active (last_active_at),
KEY idx_state (spawn_state)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS playerbot_v2_personality (
character_guid_low BIGINT UNSIGNED NOT NULL PRIMARY KEY,
skill_tier TINYINT UNSIGNED NOT NULL,
verbosity TINYINT UNSIGNED NOT NULL,
aggression TINYINT UNSIGNED NOT NULL,
risk_tolerance TINYINT UNSIGNED NOT NULL,
politeness TINYINT UNSIGNED NOT NULL,
loyalty TINYINT UNSIGNED NOT NULL,
activity_pref TINYINT UNSIGNED NOT NULL,
response_delay_ms SMALLINT UNSIGNED NOT NULL,
response_jitter_ms SMALLINT UNSIGNED NOT NULL,
mistake_rate TINYINT UNSIGNED NOT NULL,
CONSTRAINT fk_pers_char FOREIGN KEY (character_guid_low)
REFERENCES playerbot_v2_character (character_guid_low)
ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS playerbot_v2_preferences (
character_guid_low BIGINT UNSIGNED NOT NULL PRIMARY KEY,
preferred_neighborhood INT UNSIGNED NULL,
preferred_house_template INT UNSIGNED NULL,
opt_in_dungeons BOOLEAN NOT NULL DEFAULT TRUE,
opt_in_raids BOOLEAN NOT NULL DEFAULT TRUE,
opt_in_pvp BOOLEAN NOT NULL DEFAULT TRUE,
opt_in_arena BOOLEAN NOT NULL DEFAULT TRUE,
opt_in_delves BOOLEAN NOT NULL DEFAULT TRUE,
opt_in_professions BOOLEAN NOT NULL DEFAULT TRUE,
opt_in_housing BOOLEAN NOT NULL DEFAULT TRUE,
accept_player_invites TINYINT UNSIGNED NOT NULL DEFAULT 1,
follow_distance_yd FLOAT NOT NULL DEFAULT 5.0,
CONSTRAINT fk_prefs_char FOREIGN KEY (character_guid_low)
REFERENCES playerbot_v2_character (character_guid_low)
ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS playerbot_v2_population_target (
target_id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
realm_id INT UNSIGNED NOT NULL,
effective_at DATETIME NOT NULL,
total_target INT UNSIGNED NOT NULL,
floor INT UNSIGNED NOT NULL,
ceiling INT UNSIGNED NOT NULL,
horde_pct TINYINT UNSIGNED NOT NULL,
payload_json TEXT NOT NULL,
KEY idx_realm_effective (realm_id, effective_at)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (1, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
@@ -0,0 +1,44 @@
-- Migration: 0002_owner_squad_control
-- Date: 2026-05-06
-- Purpose: Owner-bot binding + squad-control state. Adds persistent
-- owner_account_id / owner_player_guid so a bot's authority
-- model survives logout / group disband. Also adds squad-
-- control state (formation type/slot, follow distance,
-- verbose flag) so commands like /follow, /formation wedge,
-- and /verbose persist across restarts.
-- Reverts: yes (DROP COLUMN ... and DROP TABLE on the squad preset).
-- Per-character owner + squad state. All columns default to "no owner /
-- autonomous defaults" so existing rows keep current behaviour.
ALTER TABLE playerbot_v2_character
ADD COLUMN owner_account_id INT UNSIGNED NOT NULL DEFAULT 0
AFTER spawn_state,
ADD COLUMN owner_player_guid BIGINT UNSIGNED NOT NULL DEFAULT 0
AFTER owner_account_id,
ADD COLUMN formation_type TINYINT UNSIGNED NOT NULL DEFAULT 0
AFTER owner_player_guid,
ADD COLUMN formation_slot TINYINT UNSIGNED NOT NULL DEFAULT 0
AFTER formation_type,
ADD COLUMN follow_distance_yd FLOAT NOT NULL DEFAULT 5.0
AFTER formation_slot,
ADD COLUMN owner_verbose TINYINT(1) NOT NULL DEFAULT 0
AFTER follow_distance_yd,
ADD KEY idx_owner_account (owner_account_id),
ADD KEY idx_owner_player (owner_player_guid);
-- Owner-saved squad presets (formation per role/class snapshots that an
-- owner can re-apply after a wipe / new dungeon entry / etc).
-- One row per (owner_account_id, preset_name); the payload_json stores
-- {bot_guid → {slot, type}} mappings. We use TEXT (JSON in 8.0+) for
-- forward compat; the application layer parses.
CREATE TABLE IF NOT EXISTS playerbot_v2_squad_preset (
owner_account_id INT UNSIGNED NOT NULL,
preset_name VARCHAR(64) NOT NULL,
saved_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
payload_json TEXT NOT NULL,
PRIMARY KEY (owner_account_id, preset_name)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (2, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
+41
View File
@@ -0,0 +1,41 @@
-- Migration: 0003_talent_builds
-- Date: 2026-05-07
-- Purpose: Curated per-spec talent build storage. Each (class, spec, context)
-- row stores a complete trait spend as a CSV of colon-triples.
-- The bot loads these on demand, picks the row matching its
-- current context (Raid / MythicPlus / PvP / Default), and applies
-- via TraitMgr commit.
-- Reverts: yes (DROP TABLE).
CREATE TABLE IF NOT EXISTS playerbot_v2_talent_build (
class_id TINYINT UNSIGNED NOT NULL,
spec_id INT UNSIGNED NOT NULL,
context TINYINT UNSIGNED NOT NULL,
label VARCHAR(128) NOT NULL DEFAULT '',
entries_json MEDIUMTEXT NOT NULL,
source_url VARCHAR(512) NOT NULL DEFAULT '',
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP
ON UPDATE CURRENT_TIMESTAMP,
PRIMARY KEY (class_id, spec_id, context),
KEY idx_spec (spec_id, context)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- Column docs (kept here below the CREATE so the migration body stays
-- a single statement free of comment-embedded semicolons that the
-- migration parser used to choke on):
-- class_id ChrClasses.db2 id (1=Warrior, 2=Paladin, 3=Hunter...)
-- spec_id ChrSpecialization.db2 id (e.g., 71=Arms, 72=Fury)
-- context 0=Default, 1=Raid, 2=MythicPlus, 3=PvP, 4=Leveling.
-- Default is the fallback when no context-specific row
-- exists for the bot.
-- label Human-readable name for diagnostics
-- ("Arms Slaughterhouse 11.1.5").
-- entries_json CSV of colon-triples: nodeID:entryID:ranks separated
-- by commas. Loader parses into a TraitConfig.Entries
-- vector. Empty string is allowed (bot falls back to
-- TraitMgr starter build).
-- source_url wowhead / simc origin URL for human reference.
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (3, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
+59
View File
@@ -0,0 +1,59 @@
-- Migration: 0004_simc_seed
-- Date: 2026-05-07
-- Purpose: Seed playerbot_v2_talent_build with raid-context talent
-- loadouts decoded from simc/midnight via decode_simc.py.
-- Each row is REPLACE INTO upsert — re-running the
-- migration overwrites existing rows for (class, spec, context).
-- Trait build: WoW 12.0.5.67314. Trait node IDs in entries_json reference
-- this client build. If the server runs a newer build that
-- renumbered nodes, TraitMgr::ValidateConfig will reject
-- rows on apply and bots fall back to TraitMgr starter.
-- Coverage: 31 of 39 specs (DPS + tanks). Healers (Restoration Druid,
-- Holy/Disc Priest, Holy Paladin, Mistweaver Monk,
-- Restoration Shaman, Preservation Evoker) plus Augmentation
-- Evoker absent from simc; populate via separate sources.
-- Reverts: yes (DELETE rows; re-run the migration to repopulate).
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 71, 1, 'simc/midnight MID1_Warrior_Arms', '90269:112121:1,90270:112122:1,90271:112123:1,90273:112125:1,90274:112126:1,90276:112128:1,90277:112129:1,90279:112131:1,90282:112134:1,90283:112135:2,90285:112137:1,90290:112144:1,90291:112145:1,90292:112146:1,90322:112179:2,90326:112183:1,90327:112184:1,90328:112185:1,90331:112188:1,90337:112198:1,90344:112206:1,90346:112208:1,90347:112209:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90438:112310:1,90439:112311:1,90441:112314:1,90444:112317:2,90445:112318:1,90447:112320:2,92537:114643:1,92614:114733:1,94784:117381:1,94786:117383:1,94787:117384:1,94788:117385:1,94795:117392:1,94801:117398:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94818:117415:1,94820:117417:1,95956:118850:1,99853:123390:1,108543:134032:1,108544:134033:1,108676:134216:1,108686:134226:1,108705:136627:1,109391:135597:1,109680:135934:1,109684:135940:1,109685:135941:1,109687:135944:2,109815:136074:1,109816:136075:1,109817:136076:1,110118:136625:1,110119:136626:1,110176:136703:1,110407:136989:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 72, 1, 'simc/midnight MID1_Warrior_Fury', '90325:112182:1,90326:112183:1,90328:112185:1,90331:112188:1,90337:112198:1,90344:112206:1,90346:112208:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90373:112240:2,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90387:112255:1,90388:119139:1,90390:112259:1,90392:112261:1,90394:112263:1,90395:112264:1,90396:112265:1,90397:112266:2,90398:112267:1,90399:112268:1,90401:112270:1,90402:112271:1,90403:112272:1,90406:112275:1,90408:112277:1,90410:112279:1,90412:112281:1,90415:112284:1,90421:112292:2,90428:112299:2,90429:112300:1,90430:112301:1,92538:114644:1,94784:117381:1,94786:117383:1,94787:117384:1,94788:117385:1,94795:117392:1,94801:117398:1,94803:117400:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94820:117417:1,95956:118850:1,99852:123389:1,108542:134031:1,108543:134032:1,108544:134033:1,108674:134213:1,108686:134226:1,108705:136627:1,109391:135597:1,109815:136074:1,109816:136075:1,109817:136076:1,109963:136448:1,109966:136451:1,109968:136453:1,109969:136454:1,110118:136625:1,110119:136626:1,110203:136735:1,110412:137004:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 73, 1, 'simc/midnight MID1_Warrior_Protection', '90261:112112:1,90264:132884:1,90265:112116:1,90295:112149:1,90296:112150:1,90297:112151:1,90298:112152:1,90301:112155:1,90302:112156:1,90303:112157:1,90304:112158:1,90305:112159:1,90306:112160:1,90308:112162:1,90309:112163:1,90310:112165:1,90311:112166:2,90312:132885:1,90314:112170:1,90317:112173:1,90318:112174:1,90319:112176:1,90320:112177:1,90324:112181:2,90326:112183:1,90328:112185:1,90329:112186:1,90330:112187:1,90331:112188:1,90343:112205:1,90346:112208:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90432:112304:1,90433:112305:1,90448:112321:1,90449:112323:1,90451:112325:1,94785:117382:1,94792:118834:1,94797:117394:1,94798:117395:1,94800:117397:1,94803:117400:1,94805:117402:1,94807:117404:1,94808:117405:1,94816:117413:1,94817:118835:1,95956:118850:1,95959:118853:1,99851:123388:1,107577:132882:1,107578:132883:1,108542:134031:1,108543:134032:1,108544:134033:1,108686:134226:1,108705:136627:1,109391:135597:1,109809:136068:1,109810:136069:1,109811:136070:1,110118:136625:1,110119:136626:1,110411:137001:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 65, 1, 'method.gg Holy Paladin (Herald of the Sun)', '81496:102465:1,81508:102477:1,81510:133481:1,81554:102533:1,81555:102534:1,81557:102536:1,81558:102537:1,81560:102539:1,81561:102540:1,81564:102544:1,81565:102545:1,81567:102548:1,81568:102549:1,81569:102550:1,81570:102551:1,81571:102552:1,81575:102558:1,81578:102562:1,81580:102564:1,81583:102567:2,81584:102569:1,81585:102570:1,81588:133501:1,81589:102574:1,81590:102575:1,81591:102577:1,81592:102578:1,81594:102580:1,81595:102581:1,81597:102583:1,81598:102584:1,81600:102587:1,81605:102592:1,81609:102597:1,81613:102601:1,81614:102602:1,81615:102603:1,81616:102604:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92220:114292:1,93009:115034:2,93180:115465:1,93191:128246:1,93520:115872:1,93521:115873:1,93522:115874:1,93927:116376:1,95069:117666:1,95071:117668:1,95072:117669:1,95073:117778:1,95080:117677:1,95086:117683:1,95094:117691:1,95095:117692:1,95098:117777:1,95099:117696:1,95105:117702:1,99839:123362:1,103851:128241:2,103856:128309:1,103858:128254:2,103861:128257:1,103863:128259:1,103864:128260:1,103866:128262:1,109748:136006:1,109749:136007:1,109750:136008:1,109998:136486:1,109999:136487:1,110012:136503:1,110092:136593:1,110257:136795:1,110417:137019:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 66, 1, 'simc/midnight MID1_Paladin_Protection', '81469:102431:1,81470:102432:1,81471:102433:2,81472:102435:1,81477:102440:1,81479:102443:1,81481:102445:1,81482:102446:2,81483:102448:1,81485:102450:2,81486:102452:1,81487:102453:1,81489:102455:1,81490:102456:1,81493:102461:1,81494:102463:1,81495:102464:1,81498:102467:1,81499:102468:1,81501:102470:1,81502:102471:1,81503:102472:1,81505:136732:1,81506:102475:1,81507:102476:1,81510:133481:1,81597:102583:1,81600:102587:1,81603:102590:1,81604:102591:1,81605:102592:1,81607:102595:1,81609:102597:1,81612:102600:1,81614:102602:1,81616:102604:1,81617:102606:1,81621:102612:2,81629:102621:1,81630:102622:2,81631:128251:1,81632:102625:1,90062:111886:1,93010:102623:1,93187:115479:1,93192:128244:1,93357:115673:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117819:1,95186:117822:1,95187:117823:1,95234:117882:1,99838:123358:1,101927:102451:1,103851:128241:2,103855:128250:1,103857:128253:1,103858:128254:2,103859:128255:1,103860:128256:1,103867:128263:1,103868:128264:1,103877:128278:1,109745:136003:1,109746:136004:1,109747:136005:1,109999:136487:1,110006:136496:1,110012:136503:1,110418:137022:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 70, 1, 'simc/midnight MID1_Paladin_Retribution', '81510:133481:1,81512:115475:1,81521:114828:1,81523:102493:1,81525:102497:1,81526:102498:1,81527:102499:1,81532:102504:1,81533:102505:1,81534:102506:1,81542:102516:1,81543:102518:1,81544:102519:1,81597:102583:1,81600:102587:1,81603:102590:1,81605:102592:1,81608:102596:1,81609:102597:1,81614:102602:1,81615:102603:1,81616:102604:1,81618:128243:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92686:114824:1,92689:114830:1,92838:115022:1,92839:115024:1,92854:115043:1,92952:115165:2,93009:115034:2,93160:115439:2,93161:115440:1,93164:115443:2,93173:115453:1,93174:115454:1,93181:115467:1,93189:115481:1,93190:115483:2,93357:115673:1,95099:117696:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117819:1,95186:117822:1,95187:117823:1,99837:123357:1,103851:128241:2,103861:128257:1,103863:128259:1,103864:128260:1,103867:128263:1,103868:128264:1,109368:135564:1,109369:135565:1,109371:115438:1,109373:115435:1,109374:136809:1,109745:136003:1,109746:136004:1,109747:136005:1,109867:136127:1,109999:136487:1,110012:136503:1,110091:136592:1,110093:136594:1,110419:137025:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 253, 1, 'method.gg Beast Mastery Hunter (Pack Leader Single Target)', '94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94979:117576:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99832:123347:1,102292:126352:1,102336:126397:2,102339:126400:1,102340:126402:1,102342:126404:1,102343:126405:1,102344:128265:1,102345:126407:2,102346:126408:1,102347:126409:1,102353:126415:1,102354:126416:1,102356:126418:1,102357:126419:1,102358:126420:1,102362:126424:1,102365:126427:1,102367:126430:2,102368:126431:1,102370:126433:1,102372:126435:1,102373:126436:1,102374:126437:1,102376:126439:1,102377:126440:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102395:126459:1,102396:126460:2,102397:126461:1,102401:126465:2,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,107285:132188:1,107286:132189:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109489:135712:1,109802:136060:1,109803:136061:1,109804:136236:1,109961:136446:1,110152:136670:1,110157:136677:1,110158:136679:1,110164:136685:1,110428:137052:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 254, 1, 'method.gg Marksmanship Hunter (Sentinel Cleave)', '94958:117555:1,94965:117562:1,94970:117567:1,94971:117568:1,94973:117570:1,94976:117573:1,94978:117575:1,94980:117577:1,94981:117578:1,94989:117586:1,94990:117587:1,99831:123345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102389:126452:1,102390:126453:1,102391:126454:1,102395:126459:1,102396:126460:2,102401:126465:2,102402:126466:1,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103947:128367:1,103956:128376:1,103957:128377:1,103958:132194:1,103961:128383:1,103962:128384:1,103964:128386:1,103966:128388:1,103973:128395:2,103974:128396:1,103975:128397:1,103977:128399:1,103978:128400:1,103979:128401:1,103982:128404:1,103984:128406:1,103985:128407:1,103986:128408:1,103990:128413:1,104095:128609:1,104127:128710:1,104130:128717:1,107288:132192:1,107289:132193:1,107290:132195:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109489:135712:1,109805:136063:1,109807:136065:1,109938:136232:1,109961:136446:1,110028:136521:1,110157:136677:1,110164:136685:1,110430:137058:1,110572:137375:1,110573:137376:1,110574:137377:1,110575:137378:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 255, 1, 'method.gg Survival Hunter (Pack Leader Single Target)', '79837:100543:1,94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94976:117573:1,94979:123781:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99833:123350:1,102255:126314:1,102262:126322:1,102263:126323:1,102264:126324:1,102268:126328:1,102270:126330:1,102272:126332:1,102279:126339:1,102282:126342:1,102285:126345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102389:126452:1,102390:126453:1,102391:126454:1,102395:126459:1,102396:126460:2,102401:126465:1,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,109305:135496:1,109307:135498:1,109309:135500:1,109310:135501:1,109311:135502:1,109312:135503:2,109313:135504:2,109316:135507:1,109319:135510:1,109320:135511:2,109321:135512:1,109323:135514:1,109324:135515:1,109470:135689:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109489:135712:1,109802:136060:1,109803:136061:1,109804:136236:1,110154:136673:1,110155:136675:1,110156:136676:1,110157:136677:1,110159:136680:1,110161:136682:1,110162:136683:1,110164:136685:1,110429:137055:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 259, 1, 'simc/midnight MID1_Rogue_Assassination', '90624:112509:2,90625:112510:1,90626:112511:1,90628:112513:1,90633:112518:1,90634:134840:1,90635:112520:1,90636:112521:1,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90740:112630:1,90741:117740:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90756:112648:1,90757:112649:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,90766:112659:2,90767:112660:1,90768:112661:1,90769:112662:1,90770:112663:1,90771:112664:1,90772:112665:2,90777:112670:1,90780:112673:1,90783:112676:1,90784:112677:1,90785:112678:2,90786:112679:1,94536:117106:1,94552:117130:1,94553:117131:1,94554:117133:1,94556:117137:1,94562:117145:1,95107:117704:1,95114:117711:1,95119:117716:1,95120:117717:1,95122:117719:1,95125:117722:1,95127:117724:1,95129:117726:1,95130:117727:1,95136:117733:1,95138:117735:1,95139:117736:1,99844:123371:1,101714:125615:1,109766:136024:1,109767:136025:1,109768:136026:1,110323:136881:1,110433:137067:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 260, 1, 'simc/midnight MID1_Rogue_Outlaw_Fatebound', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90643:112529:1,90645:112531:1,90648:112534:1,90649:112535:1,90652:112538:1,90653:112539:1,90654:112540:1,90655:135732:1,90656:112542:1,90659:112545:1,90661:112547:1,90662:112548:1,90663:112549:1,90664:112551:1,90665:112552:1,90666:112553:2,90668:112555:1,90670:112557:1,90671:112558:1,90676:112563:1,90677:112565:1,90678:112566:2,90679:112567:1,90680:112568:1,90681:112569:1,90683:112571:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90740:112630:1,90741:117740:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90750:112642:1,90751:112643:2,90752:112644:1,90753:112645:1,90754:112646:1,90755:112647:1,90756:112648:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112656:1,90764:112657:1,94562:117145:1,95107:117704:1,95114:125139:1,95119:117716:1,95120:117717:1,95122:117719:1,95125:117722:1,95127:117724:1,95129:117726:1,95130:125140:1,95138:125132:1,95139:117736:1,95140:117737:1,99843:123374:1,101714:125615:1,109766:136024:1,109767:136025:1,109768:136026:1,110323:136881:1,110434:137070:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 261, 1, 'simc/midnight MID1_Rogue_Subtlety', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90690:112578:1,90692:112580:1,90695:112583:1,90697:112585:1,90700:112588:1,90701:136807:1,90703:117172:1,90704:112592:1,90706:112594:2,90709:112597:1,90710:112598:1,90713:112601:1,90716:112604:1,90720:112608:2,90721:112609:1,90722:112610:1,90723:112611:1,90724:112612:1,90726:112614:1,90727:112615:1,90730:112618:1,90732:112620:2,90733:112621:1,90734:112623:1,90737:112627:1,90738:112628:1,90739:112629:1,90740:112630:1,90741:117740:1,90742:114737:1,90743:112633:1,90745:112635:1,90746:112636:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90758:112650:1,90760:112652:1,90762:112654:1,90763:112656:1,90764:112657:1,94562:117145:1,94580:117168:1,94582:117170:1,95106:117703:1,95108:117705:1,95109:117706:1,95110:117707:1,95117:117714:1,95123:117720:1,95131:117728:1,95132:117729:1,95135:117732:1,95136:117733:1,95140:117737:1,95142:117739:1,99842:123373:1,101714:125615:1,101715:125619:1,109760:136018:1,109761:136019:1,109762:136020:1,110323:136881:1,110324:136882:1,110325:136883:1,110432:137064:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 256, 1, 'method.gg Discipline Priest (Oracle)', '82556:103834:1,82564:116182:1,82570:103695:1,82571:136829:1,82572:103697:2,82573:103698:1,82575:103700:1,82576:108226:1,82577:103702:1,82581:103706:1,82582:103708:1,82583:103709:2,82587:103713:1,82588:103714:1,82589:103717:1,82590:103718:1,82591:103719:1,82592:103721:1,82593:103722:1,82594:103723:1,82595:103724:1,82596:103725:1,82597:103726:1,82598:103727:1,82601:103731:1,82602:103732:1,82672:103818:1,82673:103819:1,82676:115884:1,82677:103823:1,82678:103825:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82711:103863:1,82712:103864:1,82713:103865:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,86730:103688:1,94673:117276:1,94674:117277:1,94675:117278:1,94679:117282:1,94683:117286:1,94687:117290:1,94689:117292:1,94690:117293:1,94691:117294:1,94698:117301:1,94700:117303:1,99801:123290:1,108731:134284:1,109006:103841:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109020:134859:1,109021:134860:1,109781:136039:1,109782:136040:1,109783:136041:1,109890:136157:1,110008:136498:1,110277:136828:1,110278:136830:1,110410:136998:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 257, 1, 'method.gg Holy Priest (Oracle)', '82554:103675:1,82556:103834:1,82606:103738:1,82608:103740:1,82610:103743:1,82611:103744:2,82612:103745:1,82613:128316:1,82614:103748:1,82615:103749:1,82616:103750:1,82617:103751:1,82618:103752:1,82620:103754:1,82621:103755:1,82622:103756:1,82623:103757:1,82627:103762:1,82630:103765:1,82631:103766:1,82632:103767:1,82633:103769:1,82636:103773:1,82637:103774:1,82638:103775:1,82641:103779:1,82642:103780:1,82672:103818:1,82673:103819:1,82676:115884:1,82677:103823:1,82678:103825:1,82682:103831:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,94673:117276:1,94674:117277:1,94675:117278:1,94679:117282:1,94683:117286:1,94687:117290:1,94689:117292:1,94690:117293:1,94691:117294:1,94698:117301:1,94700:117303:1,99802:123292:1,103901:103676:1,103916:128333:1,104097:128611:1,108724:134273:1,108730:134283:1,108731:134284:1,109006:103841:1,109010:134844:2,109012:134846:1,109015:134849:1,109019:134852:1,109020:134859:1,109021:134860:1,109781:136039:1,109782:136040:1,109783:136041:1,109890:136157:1,109917:136185:1,110409:136995:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 258, 1, 'simc/midnight MID1_Priest_Shadow_Voidweaver', '82552:103781:1,82555:103817:1,82556:103834:1,82559:103682:1,82560:103683:2,82563:103686:1,82643:103782:1,82645:103784:2,82647:103786:1,82649:103789:2,82651:103792:1,82654:103796:1,82656:103798:1,82657:103674:1,82658:103799:1,82659:103801:1,82663:103806:1,82665:103808:1,82666:136811:1,82667:103811:1,82668:103812:1,82669:103813:1,82672:103818:1,82673:103819:1,82676:135091:1,82677:103823:1,82678:103825:1,82679:103826:1,82680:103828:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82695:114588:1,82701:103851:1,82703:103853:1,82704:103854:1,82708:103860:1,82711:103863:1,82712:103864:1,82713:103865:1,82715:103867:1,93170:103810:1,93171:115448:1,94668:117271:1,94669:117272:1,94670:117273:1,94684:117287:1,94692:117295:1,94693:123845:1,94694:117297:1,94695:125982:1,94696:117299:1,94703:117306:1,99800:123287:1,100212:123841:1,108007:133378:1,108029:133400:1,108731:134284:1,109006:103841:1,109009:103677:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109017:136223:1,109018:134851:1,109020:134859:1,109021:134860:1,109778:136036:1,109779:136037:1,109780:136038:1,109890:136157:1,109917:136185:1,110408:136992:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 250, 1, 'method.gg Blood Death Knight (San''layn Single Target)', '76039:96167:1,76041:96169:1,76042:96170:1,76043:96171:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76056:96184:1,76057:96186:1,76058:96187:1,76061:96190:1,76064:96193:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76076:96205:1,76079:96208:2,76080:96209:1,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76124:96255:1,76125:96256:1,76126:96257:2,76127:96258:1,76128:96259:1,76129:96260:1,76130:96261:1,76131:96262:1,76132:96263:1,76133:96264:1,76135:96266:1,76137:96268:1,76138:96269:1,76141:96273:1,76142:96274:1,76144:96277:1,76146:96279:1,76168:96303:1,76169:96304:1,76170:96305:1,76171:96306:1,76172:96307:1,76173:96308:1,95033:117630:1,95040:117637:1,95045:117642:1,95046:117643:1,95048:136836:1,95051:117648:1,95053:117650:1,95055:117652:1,95056:117891:1,95062:117659:1,95064:117661:1,95065:117662:1,99822:123325:1,102007:126015:1,102008:126016:1,102243:126298:1,102244:126300:1,109736:135994:1,109737:135995:1,109738:135996:1,110030:136524:1,110353:136917:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 251, 1, 'method.gg Frost Death Knight (Breath of Sindragosa)', '76033:96161:2,76037:96165:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76075:96204:1,76076:96205:1,76078:96207:1,76079:96208:2,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76091:96220:1,76092:96221:1,76093:96222:1,76096:96225:1,76098:96228:1,76101:96231:1,76103:96233:1,76106:96236:1,76108:96238:1,76109:96239:1,76114:96244:1,76115:96245:1,76116:96246:1,76117:96247:1,76118:96248:1,76121:96252:1,76122:96253:2,76123:96254:1,95032:117629:1,95034:117631:1,95035:123420:1,95036:117633:1,95043:117640:1,95049:117646:1,95057:117654:1,95058:117655:1,95061:117658:1,95062:117659:1,95066:117663:1,95068:117665:1,99821:123324:1,101929:125874:1,101930:125875:1,101931:125876:1,101933:125878:1,102007:126015:1,102008:126016:1,102009:126017:1,106790:131618:1,106791:131619:1,109258:133362:1,109733:135991:1,109734:135992:1,109735:135993:1,110029:136523:1,110030:136524:1,110031:136525:1,110400:136968:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 252, 1, 'method.gg Unholy Death Knight (Riders Single Target)', '76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76058:96187:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:133518:1,76076:96205:1,76078:96207:1,76079:96208:2,76080:96209:1,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76148:96282:1,76149:96283:2,76150:96284:2,76156:96290:1,76160:96294:1,76162:96296:1,76176:133514:1,76178:96313:1,76179:96314:1,76182:96318:1,76184:96321:1,76185:96322:1,76186:133365:1,76187:96324:1,76189:96326:1,76190:96327:1,76191:96328:1,76193:96330:1,76196:96333:1,76197:96334:1,95037:123410:1,95041:117638:1,95042:117639:1,95044:117641:1,95047:117644:1,95051:117648:1,95054:117651:1,95059:117656:1,95060:123412:1,95063:117660:1,95066:117663:1,95067:117664:1,99820:123322:1,102007:126015:1,102008:126016:1,108126:133515:1,108129:133522:1,108130:125816:1,108131:133523:1,108151:133546:1,109392:133517:1,109458:135676:1,109739:135997:1,109740:135998:1,109741:135999:1,110029:136523:1,110030:136524:1,110260:136797:1,110354:136920:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 262, 1, 'simc/midnight MID1_Shaman_Elemental_Stormbringer', '80978:101844:1,80981:101850:1,80983:101853:1,80984:127924:1,80985:101855:1,80988:101859:1,80989:101860:1,80990:101861:1,80991:101862:1,80992:101864:1,80993:101865:1,80995:101867:1,80996:101869:1,80997:101870:1,80998:101871:1,80999:136714:1,81000:101873:1,81002:101876:1,81008:101885:1,81012:101889:1,81015:101892:1,81016:101893:1,94858:123631:1,94860:117457:1,94861:117458:1,94862:123632:1,94863:128226:1,94867:117464:1,94868:117465:1,94869:117466:1,94870:117467:1,94873:128225:1,94875:117472:1,94880:117477:1,94883:117480:1,94884:123630:1,94885:117482:1,94886:117483:1,94887:117484:1,94888:117485:1,94889:117486:1,94892:117489:1,94893:117490:1,94894:117491:1,99845:123376:1,103579:127851:1,103581:127854:1,103582:127855:2,103583:127856:1,103584:127857:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127864:1,103593:127868:1,103596:127871:1,103598:127873:1,103602:127877:1,103605:127880:1,103606:127881:1,103607:127882:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103624:127905:1,103625:127906:1,103626:127908:1,103627:127909:1,103628:127910:1,103631:127913:1,103633:127915:1,103634:127916:1,103635:127917:1,103638:127919:1,103639:127920:1,103640:127921:1,109387:135591:1,109727:135985:1,109728:135986:1,109729:135987:1,109730:135988:1,109731:135989:1,109732:135990:1,110066:136561:1,110085:136585:1,110402:136974:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 263, 1, 'simc/midnight MID1_Shaman_Enhancement_Totemic', '80938:101801:1,80939:101802:1,80941:101804:1,80942:101805:1,80943:101806:1,80945:101809:2,80947:101811:1,80948:101812:1,80949:101813:1,80950:101814:2,80951:101815:1,80953:101818:1,80954:101819:1,80958:101823:1,80959:101824:1,80960:101825:1,80961:101826:1,80962:101827:1,80963:101828:1,80964:101829:1,80967:101832:1,80968:101833:1,80969:101834:1,80973:101839:1,80974:101840:1,80975:101841:1,94859:117456:1,94866:125824:1,94871:117468:1,94872:117469:1,94874:117471:1,94877:117474:1,94879:117476:1,94881:125822:1,94882:117479:1,94890:117487:1,94891:117488:1,94892:117489:1,99847:123379:1,103581:127854:1,103582:127855:2,103583:127856:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127865:1,103593:127868:1,103594:127869:1,103596:127871:1,103602:127877:1,103605:127880:1,103606:127881:1,103607:127882:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103622:127902:1,103624:127905:1,103625:127906:1,103627:127909:1,103628:127910:1,103871:128270:1,109194:128236:1,109386:135590:1,109387:135591:1,109388:135592:1,109389:135593:1,109724:135982:1,109725:135983:1,109726:135984:1,110085:136585:1,110401:136971:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 264, 1, 'method.gg Restoration Shaman (Totemic Downpour)', '80976:101842:1,81018:101895:1,81019:101896:1,81021:101899:1,81022:101900:1,81024:101902:1,81027:101905:1,81031:101911:1,81032:101912:1,81033:135485:1,81037:101919:1,81040:101923:1,81041:101924:1,81044:101928:1,81047:101932:1,81048:101934:1,81049:101935:1,81050:101936:1,81051:101937:1,81052:101939:2,81055:101942:1,81073:101964:1,92675:114811:1,92677:114813:1,94859:117456:1,94866:125824:1,94871:117468:1,94872:117469:1,94874:117471:1,94877:117474:1,94879:117476:1,94881:125822:1,94882:117479:1,94888:117485:1,94890:117487:1,94891:117488:1,99846:123378:1,103428:127672:1,103430:127674:1,103434:127680:1,103436:127682:1,103581:127853:1,103582:127855:2,103584:127857:1,103586:127859:1,103587:127860:1,103588:127861:1,103590:127863:1,103591:127864:1,103593:127868:1,103594:127869:1,103596:127871:1,103598:127873:1,103601:127876:1,103602:127877:1,103606:127881:1,103607:127883:1,103611:127888:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103622:127902:1,103625:127906:1,103626:127908:1,103627:127909:1,104124:128703:1,109301:135487:1,109386:135590:1,109387:135591:1,109388:135592:1,109724:135982:1,109725:135983:1,109726:135984:1,110085:136585:1,110403:136977:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 62, 1, 'simc/midnight MID1_Mage_Arcane_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62121:80180:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,93524:115877:1,94647:117250:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99830:123344:1,101883:125818:1,102438:126508:1,102440:126510:1,102441:126511:1,102445:126515:1,102446:126516:1,102449:126519:1,102453:126523:1,102454:136465:1,102460:126530:1,102465:134020:1,102467:126537:1,102468:126538:1,102469:126539:1,102470:126540:1,102471:126541:1,102473:126543:1,102474:126544:1,102475:126545:1,102480:126550:2,104113:128689:1,108536:134024:1,108537:134026:2,108538:134027:1,108539:134028:1,108551:134047:1,108654:134183:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108664:134194:1,108665:134196:1,109002:134834:1,109667:135918:1,109668:135919:1,109669:135920:1,110080:136578:1,110081:136579:1,110420:137028:1,110442:137084:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 63, 1, 'simc/midnight MID1_Mage_Fire_Sunfury', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62119:80178:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,93524:115877:1,94643:117246:1,94644:117247:1,94645:117248:1,94646:117249:1,94647:117250:1,94648:117251:1,94649:117252:1,94650:117253:1,94651:117254:1,94652:117255:1,94653:117256:1,99829:123340:1,100989:124750:1,100995:124756:1,100998:124759:1,100999:124760:1,101007:135618:1,101009:124771:1,101019:124783:2,101024:124789:1,101027:124793:1,101029:124795:2,108654:134182:1,108656:134186:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108662:134192:2,109393:135600:1,109395:135603:1,109396:135604:1,109398:135606:1,109399:135607:1,109401:135609:1,109402:135610:1,109403:135612:1,109404:135613:2,109407:135616:1,109408:135617:1,109409:135602:1,109411:135621:1,109673:135924:1,109674:135925:1,109675:135926:1,109956:136441:1,110080:136578:1,110081:136579:1,110086:136587:1,110088:136589:1,110321:136878:1,110322:136879:1,110423:137037:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 64, 1, 'simc/midnight MID1_Mage_Frost_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62107:80165:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62117:80176:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,62129:80189:1,62150:134540:1,62153:80216:1,62157:80220:1,62164:80227:1,62170:80234:1,62173:80237:1,62176:80241:1,62177:80242:1,62178:80243:1,62179:80244:1,62180:80245:1,62181:80247:1,62182:80248:1,62184:80250:1,81468:102429:1,93524:115877:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99828:123339:1,103771:134418:1,108653:134180:1,108654:134183:1,108655:134185:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108849:134405:1,108850:134406:1,108851:134407:1,108852:134408:1,108855:134411:1,108858:134414:2,108859:134415:1,108864:134421:1,109667:135918:1,109668:135919:1,109669:135920:1,109915:136182:1,109916:136183:1,109956:136441:1,110081:136579:1,110258:136796:1,110283:136837:1,110422:137034:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 265, 1, 'simc/midnight MID1_Warlock_Affliction_Soul_Harvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91446:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,72032:91552:1,72033:91553:1,72034:91554:1,72037:91558:1,72041:91562:1,72045:124692:1,72047:91568:1,72049:91570:1,72050:91571:1,72051:91572:1,72054:91576:1,72055:91577:2,72058:91580:2,94821:117418:1,94823:117420:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94840:117437:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94857:117454:1,99850:123384:1,100941:124694:1,102031:126064:1,102247:126303:1,109837:136096:1,109838:136097:1,109839:136098:1,109842:136102:2,109843:136103:1,109844:136104:1,109845:136105:1,109847:136107:1,109849:136109:1,109852:136112:1,109855:136115:1,109857:136117:1,109859:136119:1,109860:136120:1,109861:136121:1,109862:136122:1,109863:136123:1,109865:136125:2,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110269:136812:1,110270:136813:1,110405:136983:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 266, 1, 'simc/midnight MID1_Warlock_Demonology_Soul_Harvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71955:91466:1,71956:91468:1,71957:91469:1,94821:117418:1,94823:123839:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94855:117452:1,94857:117454:1,99849:123383:1,100941:124694:1,101887:125829:2,101891:125834:1,101893:136731:1,101894:125837:1,101895:125839:1,101903:125848:2,101905:125850:1,101908:125854:1,101909:125855:1,101914:125860:2,101920:125866:1,101923:125869:1,109244:135306:1,109248:135310:1,109249:135311:2,109250:135312:1,109251:135313:1,109252:135314:1,109253:135315:1,109257:135319:1,109837:136096:1,109838:136097:1,109839:136098:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109847:136107:1,109934:136227:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110191:136719:1,110193:136721:1,110194:136722:1,110197:136726:1,110198:136727:1,110404:136980:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 267, 1, 'simc/midnight MID1_Warlock_Destruction_Hellcaller', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,71960:91473:1,71965:91478:1,71968:91481:1,71969:91482:2,71971:91484:1,71973:91486:1,71975:91489:1,71980:91496:1,71983:91500:2,71985:91502:1,72059:91581:1,72060:91582:1,72061:91583:1,72062:91584:1,72065:91588:1,72066:91589:2,72067:91590:1,72068:91591:1,72069:91592:1,94822:117419:1,94829:117426:1,94834:117431:1,94835:117432:1,94837:117434:1,94840:117437:1,94842:117439:1,94844:117441:1,94845:117442:1,94853:117450:1,94854:123310:1,94855:117452:1,99848:123382:1,100941:124694:1,101992:126002:1,101994:126004:1,108678:134219:1,108681:134221:1,109834:136093:1,109835:136094:1,109836:136095:1,109841:136101:1,109842:136102:2,109843:136103:1,109845:136105:1,109847:136107:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110280:136833:1,110281:136834:2,110282:136835:1,110406:136986:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 268, 1, 'simc/midnight MID1_Monk_Brewmaster', '101064:124838:1,101065:136148:1,101067:136146:1,101069:124843:1,101071:124845:1,101072:124846:1,101074:124848:2,101075:124849:1,101076:124850:1,101078:124852:1,101079:124854:1,101080:124855:1,101082:124857:1,101086:124863:1,101087:124864:1,101088:124865:1,101135:124924:1,101136:124926:1,101140:124930:1,101142:124932:1,101145:124935:1,101146:124936:1,101147:124937:1,101152:124943:1,101153:124944:1,101156:124948:1,101160:124954:1,101161:124955:1,101163:124957:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101177:124974:1,101178:124975:1,101179:124976:2,101181:124979:1,101182:124980:1,101183:124982:1,101184:124983:2,101187:124987:1,101188:124988:1,101190:124991:1,101193:124996:1,101195:124999:1,101197:125001:1,101198:125003:1,101201:125006:1,101202:125008:1,101219:125028:1,101220:125029:1,101221:125031:1,101222:125032:1,101223:125033:1,101224:125035:1,101225:125036:1,101226:125037:1,101227:125039:1,101228:125040:1,101229:125042:1,101230:125043:1,101248:125069:1,101711:125002:1,102004:124859:1,102433:126501:1,109694:135952:1,109695:135953:1,109696:135954:1,109826:136085:1,109827:136086:1,109882:136145:1,109910:136177:1,110435:137075:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 269, 1, 'simc/midnight MID1_Monk_Windwalker', '101035:124805:2,101036:124806:1,101037:124807:1,101039:124810:1,101044:126026:1,101045:124817:1,101048:124820:1,101051:124823:1,101052:124825:1,101053:124826:1,101054:124827:1,101055:124828:1,101056:124829:1,101057:124830:1,101059:124833:1,101060:124834:1,101136:124926:1,101137:124927:1,101140:124930:1,101142:124932:1,101146:124936:1,101147:124937:1,101149:124939:1,101150:124941:1,101153:124944:1,101159:124953:1,101160:124954:1,101162:124956:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101178:124975:1,101179:124976:2,101182:124980:1,101183:124982:1,101184:124983:2,101185:124984:1,101186:124985:1,101203:125009:1,101205:125012:1,101206:125013:1,101207:134452:1,101208:125015:1,101209:125016:1,101210:125017:1,101213:125020:1,101215:125022:1,101216:125023:1,101217:125025:1,101218:125026:1,101232:125046:1,101243:125062:1,101244:125063:1,101245:125065:1,101246:125066:1,101247:125068:1,101248:125069:1,101249:125070:1,101250:125071:1,101251:125072:1,101252:125073:1,101253:125074:1,101254:125076:1,108946:134543:1,109697:135955:1,109698:135956:1,109699:135957:1,110022:136514:1,110023:136515:1,110025:136518:1,110098:136599:1,110436:137076:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 270, 1, 'method.gg Mistweaver Monk (Conduit of the Celestials)', '101089:124866:1,101093:124871:1,101095:124873:1,101096:124875:1,101097:124876:1,101102:128221:1,101104:124885:1,101107:124888:1,101108:124889:1,101110:124891:1,101111:124892:2,101112:124893:1,101113:124894:1,101114:124896:2,101115:124897:1,101117:124899:1,101121:124905:1,101122:124906:1,101123:124907:1,101124:124908:2,101127:125932:1,101128:124913:1,101129:124915:1,101130:124916:1,101131:124918:1,101132:124920:1,101133:124921:1,101134:124922:1,101136:124926:1,101139:124929:1,101140:124930:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101153:124944:1,101157:124949:1,101161:124955:1,101164:124958:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101179:124976:2,101183:124982:1,101185:124984:1,101186:124985:1,101223:125033:1,101231:125045:1,101233:125049:1,101234:125050:1,101235:125052:1,101236:125054:1,101237:125055:1,101238:125056:1,101239:125058:1,101240:125059:1,101242:125061:1,102432:126500:1,109516:135749:1,109700:135958:1,109701:135959:1,110019:136510:1,110021:136512:1,110024:136517:1,110026:136519:1,110027:136520:1,110067:136562:1,110097:136598:1,110211:136747:1,110218:136754:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 102, 1, 'simc/midnight MID1_Druid_Balance', '82198:103276:1,82201:103279:1,82202:103280:1,82206:103284:1,82207:128589:1,82208:103286:1,82209:103287:1,82210:103288:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82228:103306:1,82229:103307:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82237:103316:1,82241:103320:1,82246:103326:1,88201:109833:1,88202:109834:1,88203:109835:1,88204:109836:1,88206:109839:1,88207:109840:2,88208:109842:1,88212:109846:1,88213:109847:1,88214:109848:2,88215:109849:1,88218:109852:1,88221:109856:1,88222:109857:1,88223:109858:1,88224:109859:1,88225:109861:1,88226:109862:1,88227:109863:2,88231:109867:1,88234:109870:1,88235:109871:1,88236:109872:1,91048:115458:1,92229:114300:1,93714:116102:1,94585:117772:1,94586:117178:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:123304:1,94598:117193:1,94600:117195:1,94607:117204:1,94608:117205:1,99808:123302:1,100174:123793:1,100175:123794:1,100176:123795:1,100177:123796:2,100223:123868:1,103846:128230:1,103847:128231:1,104078:128579:1,104080:128584:1,104083:128588:1,104085:128591:1,108032:133404:1,109718:135976:1,109719:135977:1,109720:135978:1,110421:137031:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 103, 1, 'simc/midnight MID1_Druid_Feral_Wildstalker', '82088:103147:1,82091:103150:1,82092:103152:1,82096:103157:1,82098:103159:1,82099:103160:1,82100:103161:1,82101:103162:1,82102:103163:1,82103:103164:1,82104:103165:1,82106:103167:1,82107:103168:1,82108:103170:1,82110:103173:1,82111:103174:1,82112:103175:1,82113:103176:1,82114:103177:1,82115:103179:2,82116:103180:1,82118:103182:1,82119:103183:1,82121:103185:2,82122:103186:1,82123:103187:1,82124:103188:1,82198:103276:1,82199:103277:1,82206:103284:1,82207:128589:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82222:103300:1,82223:103301:1,82224:103302:1,82225:103303:2,82228:103306:1,82229:103307:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82239:103318:1,82241:103320:1,82242:103322:1,82243:103323:2,82244:103324:1,82246:103326:1,92641:114771:1,94609:117206:1,94621:117221:1,94622:119855:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117229:1,94629:117231:1,94630:117232:1,94631:117234:1,99805:123296:1,100175:123794:1,100176:123795:1,100177:123796:2,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109715:135973:1,109716:135974:1,109717:135975:1,110426:137046:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 104, 1, 'simc/midnight MID1_Druid_Guardian', '82126:103190:1,82127:103191:1,82129:103193:1,82131:103195:1,82135:103199:1,82136:103201:1,82138:103203:2,82140:103206:1,82142:103209:1,82143:103210:2,82145:103212:1,82146:103213:2,82147:135336:1,82149:103216:1,82152:103221:1,82153:103222:1,82160:103229:1,82161:103230:1,82198:103276:1,82199:103277:1,82206:103284:1,82208:103286:1,82209:103287:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82223:103301:1,82224:103302:1,82225:103303:2,82227:103305:1,82228:103306:1,82229:103307:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82237:103316:1,82239:103318:1,82241:103320:1,82242:103322:1,82243:103323:1,82246:103326:1,91044:112967:1,91046:112969:1,92226:103208:1,92227:103218:1,92585:114698:1,92586:114699:1,92587:114700:1,94608:117205:1,94609:117206:1,94610:117207:1,94611:117208:1,94612:117210:1,94613:117211:1,94614:117214:1,94615:117215:1,94616:117216:1,94618:117218:1,94619:117219:1,94620:117220:1,99807:123301:1,100175:123794:1,100176:123795:1,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109375:135568:1,109377:135491:1,109378:135570:1,109379:135490:1,109721:135979:1,109722:135980:1,109723:136624:1,110431:137061:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 105, 1, 'method.gg Restoration Druid (Wildstalker)', '82043:117104:1,82045:103096:1,82047:103098:1,82049:103100:1,82050:103101:1,82051:103102:1,82052:103105:1,82053:103106:1,82054:103108:1,82055:103109:1,82057:103111:1,82058:103112:1,82059:103113:1,82060:103114:1,82063:103118:1,82064:103119:1,82065:103121:1,82068:103124:1,82071:103127:1,82072:103128:1,82073:103129:1,82074:114809:1,82076:103132:1,82079:103137:1,82082:103141:1,82083:103142:1,82198:103275:1,82205:103283:1,82206:103284:1,82207:128589:1,82209:103287:1,82210:103288:1,82214:103292:2,82217:103295:1,82218:103296:1,82219:103297:1,82220:103298:1,82225:103303:2,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82240:103319:1,82243:103323:2,82244:103324:1,94600:117195:1,94621:117221:1,94622:119855:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117229:1,94629:117231:1,94630:117232:1,94631:117233:1,99806:123298:1,100173:123792:1,100175:123794:1,100176:123795:1,100177:123796:2,100223:123868:1,103873:128274:1,103874:128708:1,103876:128277:1,104082:128586:1,104084:128590:1,104085:128591:1,104125:128707:1,109715:135973:1,109716:135974:1,109717:135975:1,110424:137040:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 577, 1, 'simc/midnight MID1_Demon_Hunter_Havoc_Fel-Scarred', '90914:112823:1,90919:112828:1,90921:112830:1,90922:112831:1,90923:112832:1,90925:112834:1,90928:112838:1,90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90937:112848:1,90938:112849:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90993:112911:1,90994:117768:1,90997:117755:1,91000:112918:2,91001:112919:1,91002:112921:1,91003:112923:1,91004:112924:2,91006:112926:1,91007:112927:1,91008:112928:1,91011:112932:1,91012:117764:1,91013:112934:1,91015:112936:2,91017:112938:1,91018:112939:1,91021:117744:1,91022:112944:1,91024:117765:1,91025:112948:1,91026:112949:1,91027:112950:1,91028:112951:1,91032:112955:1,91034:112957:2,91036:112959:1,93013:115244:1,93015:115246:1,93016:115248:1,94899:124010:1,94901:117498:1,94902:117499:1,94904:117501:1,94905:117502:1,94909:117506:1,94912:117509:1,94913:124011:1,94915:117512:1,94916:117513:1,94917:117514:1,94918:117515:1,95143:117741:1,95147:117754:2,95149:117758:1,95150:117759:1,95152:117762:1,99824:123329:1,109772:136030:1,109773:136031:1,109774:136032:1,110011:136501:1,110427:137049:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 581, 1, 'simc/midnight MID1_Demon_Hunter_Vengeance_Annihilator', '90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90951:112864:1,90952:112865:1,90953:112866:1,90955:112868:1,90958:112872:2,90959:112873:1,90960:112875:1,90961:112876:1,90962:112877:2,90963:112878:1,90964:112879:1,90968:112883:1,90970:112886:1,90971:112887:1,90972:112888:1,90974:112890:1,90975:112891:1,90977:112893:1,90978:112894:1,90980:112896:1,90981:112897:2,90984:112900:1,90986:112902:1,90987:112903:1,90989:112906:1,90990:112907:1,90991:112908:1,90994:112912:1,90996:112914:2,90999:112917:1,91000:112918:2,91001:112920:1,91002:112921:1,91004:112924:2,91006:112926:1,91007:112927:1,95149:117758:1,95150:117759:1,95151:117761:1,95152:117762:1,99823:134253:1,108722:134271:1,108729:134282:1,109442:135660:1,109443:135661:1,109444:135662:1,109445:135663:1,109446:135664:1,109447:135665:1,109448:135659:1,109449:135667:1,109450:136810:1,109451:135669:1,109452:135670:1,109453:135671:1,109454:135672:1,109455:135673:1,110011:136501:1,110425:137043:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1467, 1, 'simc/midnight MID1_Evoker_Devastation_SC', '93272:115578:1,93273:115579:1,93274:115580:2,93275:115581:1,93280:115587:1,93281:115588:2,93284:115592:1,93285:115593:1,93289:115597:1,93294:115602:1,93295:115603:2,93297:115606:1,93298:115607:1,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93313:115623:1,93314:115624:1,93316:115627:1,93318:115630:1,93319:115631:1,93320:115632:1,93322:115634:1,93323:115635:1,93324:115636:1,93325:115637:1,93326:115638:1,93327:115639:1,93328:115640:1,93329:115641:1,93330:115642:1,93331:115643:1,93332:115645:1,93333:115646:1,93334:115647:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93366:115683:1,93715:116103:1,94921:117518:1,94928:117525:1,94933:117530:1,94934:117531:1,94936:117533:1,94939:117536:1,94941:117538:1,94943:120123:1,94944:117541:1,94950:117547:1,94952:117549:1,94953:117550:1,98931:122279:1,99827:123333:1,103843:128216:1,103844:128217:1,109793:136051:1,109794:136052:1,109795:136053:1,110064:136559:1,110414:137010:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1468, 1, 'method.gg Preservation Evoker (Chronowarden Raid)', '93238:115540:1,93239:115541:1,93240:115542:1,93241:115543:1,93242:115544:1,93243:115546:1,93245:115549:1,93246:115550:1,93250:115554:1,93253:115557:1,93254:115558:2,93255:115559:1,93257:115561:1,93258:115562:1,93260:115565:1,93262:115567:1,93263:115568:2,93264:115570:1,93265:115571:1,93266:115572:1,93267:115573:1,93268:115574:2,93269:115575:1,93271:115577:1,93288:115596:1,93289:115597:1,93291:115599:1,93292:115600:2,93294:115602:1,93299:115608:1,93300:115609:1,93302:115611:2,93304:115613:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93336:115650:1,93337:115651:1,93338:115652:1,93339:115653:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93347:115662:2,93348:115663:1,93350:115665:1,93351:125610:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93715:116103:1,94925:117522:1,94929:117526:1,94930:126310:1,94932:117786:1,94935:117532:1,94942:117539:1,94947:117544:1,94948:117545:1,94950:117547:1,94951:117548:1,94954:117551:1,94955:117552:1,99826:123335:1,103843:128216:1,109508:135741:1,109509:135742:1,109510:135743:1,110064:136559:1,110413:137007:1', 'https://www.method.gg/guides');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1473, 1, 'method.gg Augmentation Evoker (Chronowarden ST+Cleave)', '93195:115493:1,93197:115495:1,93198:115496:1,93199:115690:1,93200:115498:1,93201:115499:1,93202:115500:1,93203:115502:1,93205:115504:1,93206:115505:1,93207:115506:1,93208:115507:1,93209:115508:1,93211:115511:1,93212:115512:1,93219:115519:1,93220:115520:1,93221:115521:1,93222:115522:1,93223:115523:1,93226:115527:1,93229:115530:1,93232:115533:1,93234:115536:1,93271:115577:1,93287:115595:1,93288:115596:1,93289:115597:1,93290:115598:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93345:115660:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93354:115669:1,93355:115670:2,93358:115675:1,93367:115685:1,93368:115688:1,93369:115686:1,93715:116103:1,94925:117522:1,94929:117526:1,94930:126310:1,94932:117529:1,94935:117532:1,94942:117539:1,94947:117544:1,94948:117545:1,94951:117548:1,94954:117551:1,94955:117552:1,98931:122279:1,99825:123334:1,102248:126304:1,102249:126305:1,103843:128216:1,109508:135741:1,109509:135742:1,109510:135743:1,110415:137013:1', 'https://www.method.gg/guides');
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (4, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
@@ -0,0 +1,53 @@
-- Migration: 0005_population_columns
-- Date: 2026-05-07
-- Purpose: Schema additions for the world-population subsystem
-- (BotPopulationManager + BotSetupPipeline). Tracks the
-- one-shot distribution levelup, idempotent setup-pipeline
-- progress, JIT queue-fill provenance, and LRU timestamps.
-- Reverts: yes (DROP COLUMN per added column).
ALTER TABLE playerbot_v2_character
ADD COLUMN distribution_level TINYINT UNSIGNED NOT NULL DEFAULT 0
AFTER owner_verbose,
ADD COLUMN distribution_at TIMESTAMP NULL DEFAULT NULL
AFTER distribution_level,
ADD COLUMN setup_pipeline_state TINYINT UNSIGNED NOT NULL DEFAULT 0
AFTER distribution_at,
ADD COLUMN jit_for_queue VARCHAR(48) NULL DEFAULT NULL
AFTER setup_pipeline_state,
ADD COLUMN last_seen_at TIMESTAMP NULL DEFAULT NULL
AFTER jit_for_queue,
ADD KEY idx_distribution_level (distribution_level),
ADD KEY idx_jit_for_queue (jit_for_queue),
ADD KEY idx_last_seen_at (last_seen_at);
-- Column docs (kept here below the ALTER so the migration body stays a
-- single statement free of comment-embedded semicolons that the migration
-- parser used to choke on):
-- distribution_level Floor level the BotPopulationManager set this
-- bot to. 0 = never distributed. The shaper
-- refuses to lower a bot's level (see
-- project_v2_world_population.md A5). Gameplay
-- leveling beyond this floor proceeds normally.
-- distribution_at When the distribution levelup happened.
-- Used by hygiene + diagnostics; NULL until set.
-- setup_pipeline_state Bitmask of completed BotSetupPipeline steps.
-- bit 0 = SetLevel, 1 = StarterKit,
-- 2 = GenerateGear, 3 = AutoEquip,
-- 4 = ApplyTalents, 5 = LearnProfessions,
-- 6 = AcquireMount, 7 = PlaceInCapital,
-- 8 (high bits in 0xFF marker) = TravelToZone +
-- Mark complete. 0xFF = pipeline complete.
-- jit_for_queue Tag set when the bot was JIT-spawned to fill
-- a player's queue (e.g. "BG_AB", "LFG_5man").
-- Used by hygiene cleanup to delete bots that
-- were created solely for queue-fill and have
-- outlived their retention window. NULL = bot
-- is part of the regular distribution pool.
-- last_seen_at UTC timestamp of last login or significant
-- AI tick. Drives LRU log-out when the
-- population exceeds target.
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (5, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
+94
View File
@@ -0,0 +1,94 @@
-- Migration: 0006_bot_guild_meta
-- Date: 2026-05-16
-- Purpose: Schema for the bot guild ecosystem (see
-- src/modules/PlayerbotV2/docs/GUILD_PLAN.md).
-- - bot_guild_meta: maps TC's `guild.guildid` to BotGuildMgr
-- metadata (faction, theme, founder, rival, member cap).
-- Distinguishes bot-founded guilds from operator/player
-- guilds so the manager never modifies guilds it didn't
-- create.
-- - bot_guild_name_reserved: in-flight name reservations
-- while a charter FSM is collecting signatures. Prevents
-- two parallel founders from picking the same name.
-- Reverts: yes (DROP TABLE both).
CREATE TABLE IF NOT EXISTS bot_guild_meta (
guild_id BIGINT UNSIGNED NOT NULL,
faction TINYINT UNSIGNED NOT NULL,
theme VARCHAR(32) NOT NULL DEFAULT 'adventurers',
founder_low BIGINT UNSIGNED NOT NULL,
rival_low BIGINT UNSIGNED DEFAULT NULL,
member_cap SMALLINT UNSIGNED NOT NULL DEFAULT 75,
created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
last_event_at TIMESTAMP NULL DEFAULT NULL,
PRIMARY KEY (guild_id),
KEY idx_bot_guild_meta_faction (faction),
KEY idx_bot_guild_meta_founder (founder_low)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
-- Column docs:
-- guild_id FK to guild.guildid (CharacterDatabase). Not a real
-- FK constraint because TC's guild table doesn't carry
-- one for player rosters and we mirror the convention.
-- faction 0 = Alliance, 1 = Horde. Matches
-- BotGuildMgr::Faction enum.
-- theme 'adventurers' for the default Phase A.2 guild kind;
-- 'crafters' / 'raiders' for Phase E themed guilds.
-- founder_low Character guid_low of the bot that founded the
-- guild. NOT necessarily the current GM (GM rotates
-- via Phase B hygiene). Used by recently-disbanded
-- cooldowns and ownership lineage.
-- rival_low Optional rival guild_id (intra-faction). Set at
-- creation (Phase A.2 picks the longest-active
-- existing bot guild of same faction; NULL if first).
-- Phase E rivalries read this.
-- member_cap Per-guild membership ceiling. Defaults to 75 from
-- BotGuildMgr::kDefaultMaxMembersPerGuild but
-- configurable per guild for special cases.
-- created_at Insertion time = guild submission time.
-- last_event_at Last scheduled-event start (Phase D). NULL until
-- first event runs.
CREATE TABLE IF NOT EXISTS bot_guild_name_reserved (
name VARCHAR(64) NOT NULL,
faction TINYINT UNSIGNED NOT NULL,
founder_low BIGINT UNSIGNED NOT NULL,
reserved_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (name),
KEY idx_bot_guild_name_reserved_founder (founder_low)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
-- Column docs:
-- name The candidate guild name reserved by the charter
-- FSM at phase 2 (buy_charter). Released on success
-- (row deleted when bot_guild_meta row is INSERTed)
-- OR on FSM abort (founder lost the charter, exceeded
-- the 30-min total time-to-found budget, etc.).
-- faction Founder's faction (sanity check + queryability).
-- founder_low Owner of the reservation. Hygiene cron sweeps
-- reservations older than 60 min as orphans.
-- reserved_at For 60-min sweep cutoff.
CREATE TABLE IF NOT EXISTS bot_guild_member_meta (
guild_id BIGINT UNSIGNED NOT NULL,
char_guid_low BIGINT UNSIGNED NOT NULL,
joined_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
last_promoted_at TIMESTAMP NULL DEFAULT NULL,
PRIMARY KEY (guild_id, char_guid_low),
KEY idx_bot_gmm_char (char_guid_low),
KEY idx_bot_gmm_joined (joined_at)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
-- Column docs:
-- guild_id FK to guild.guildid (CharacterDatabase).
-- char_guid_low Bot character guid_low (FK to characters.guid).
-- joined_at When the bot joined this guild — populated by the
-- manager whenever Guild::AddMember succeeds for a
-- bot (charter-signer turn-in, organic recruitment,
-- etc). Drives the rank ladder hygiene cron
-- (Initiate <7d, Member <30d, Veteran >30d).
-- last_promoted_at Last rank change; null until first promotion.
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (6, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
@@ -0,0 +1,111 @@
-- Migration: 0007_talent_builds_seed
-- Date: 2026-05-07
-- Purpose: Populate context=0 (Default) rows in playerbot_v2_talent_build
-- by mirroring the curated raid loadouts seeded in 0004.
-- The API loader (LookupCuratedBuildRow in PlayerbotAPI.cpp)
-- falls back from any requested context (M+/PvP/Leveling)
-- to context=0/Default when the requested row is missing.
-- Seeding Default for all 39 specs therefore guarantees that
-- every bot in every context receives a curated build instead
-- of the TraitMgr generic starter, regardless of role.
-- Coverage: 39/39 specs at context=0 (Default).
-- Per-context rows (Raid=1 already in 0004; M+=2, PvP=3,
-- Leveling=4) deferred until per-context simc/method profiles
-- are sourced.
-- Reverts: yes (DELETE rows; re-run the migration to repopulate).
-- Populated 39/195 rows
-- ===== Warrior =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(1, 71, 0, 'Default: simc/midnight MID1_Warrior_Arms', '90269:112121:1,90270:112122:1,90271:112123:1,90273:112125:1,90274:112126:1,90276:112128:1,90277:112129:1,90279:112131:1,90282:112134:1,90283:112135:2,90285:112137:1,90290:112144:1,90291:112145:1,90292:112146:1,90322:112179:2,90326:112183:1,90327:112184:1,90328:112185:1,90331:112188:1,90337:112198:1,90344:112206:1,90346:112208:1,90347:112209:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90438:112310:1,90439:112311:1,90441:112314:1,90444:112317:2,90445:112318:1,90447:112320:2,92537:114643:1,92614:114733:1,94784:117381:1,94786:117383:1,94787:117384:1,94788:117385:1,94795:117392:1,94801:117398:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94818:117415:1,94820:117417:1,95956:118850:1,99853:123390:1,108543:134032:1,108544:134033:1,108676:134216:1,108686:134226:1,108705:136627:1,109391:135597:1,109680:135934:1,109684:135940:1,109685:135941:1,109687:135944:2,109815:136074:1,109816:136075:1,109817:136076:1,110118:136625:1,110119:136626:1,110176:136703:1,110407:136989:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(1, 72, 0, 'Default: simc/midnight MID1_Warrior_Fury', '90325:112182:1,90326:112183:1,90328:112185:1,90331:112188:1,90337:112198:1,90344:112206:1,90346:112208:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90373:112240:2,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90387:112255:1,90388:119139:1,90390:112259:1,90392:112261:1,90394:112263:1,90395:112264:1,90396:112265:1,90397:112266:2,90398:112267:1,90399:112268:1,90401:112270:1,90402:112271:1,90403:112272:1,90406:112275:1,90408:112277:1,90410:112279:1,90412:112281:1,90415:112284:1,90421:112292:2,90428:112299:2,90429:112300:1,90430:112301:1,92538:114644:1,94784:117381:1,94786:117383:1,94787:117384:1,94788:117385:1,94795:117392:1,94801:117398:1,94803:117400:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94820:117417:1,95956:118850:1,99852:123389:1,108542:134031:1,108543:134032:1,108544:134033:1,108674:134213:1,108686:134226:1,108705:136627:1,109391:135597:1,109815:136074:1,109816:136075:1,109817:136076:1,109963:136448:1,109966:136451:1,109968:136453:1,109969:136454:1,110118:136625:1,110119:136626:1,110203:136735:1,110412:137004:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(1, 73, 0, 'Default: simc/midnight MID1_Warrior_Protection', '90261:112112:1,90264:132884:1,90265:112116:1,90295:112149:1,90296:112150:1,90297:112151:1,90298:112152:1,90301:112155:1,90302:112156:1,90303:112157:1,90304:112158:1,90305:112159:1,90306:112160:1,90308:112162:1,90309:112163:1,90310:112165:1,90311:112166:2,90312:132885:1,90314:112170:1,90317:112173:1,90318:112174:1,90319:112176:1,90320:112177:1,90324:112181:2,90326:112183:1,90328:112185:1,90329:112186:1,90330:112187:1,90331:112188:1,90343:112205:1,90346:112208:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90432:112304:1,90433:112305:1,90448:112321:1,90449:112323:1,90451:112325:1,94785:117382:1,94792:118834:1,94797:117394:1,94798:117395:1,94800:117397:1,94803:117400:1,94805:117402:1,94807:117404:1,94808:117405:1,94816:117413:1,94817:118835:1,95956:118850:1,95959:118853:1,99851:123388:1,107577:132882:1,107578:132883:1,108542:134031:1,108543:134032:1,108544:134033:1,108686:134226:1,108705:136627:1,109391:135597:1,109809:136068:1,109810:136069:1,109811:136070:1,110118:136625:1,110119:136626:1,110411:137001:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- ===== Paladin =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(2, 65, 0, 'Default: method.gg Holy Paladin (Herald of the Sun)', '81496:102465:1,81508:102477:1,81510:133481:1,81554:102533:1,81555:102534:1,81557:102536:1,81558:102537:1,81560:102539:1,81561:102540:1,81564:102544:1,81565:102545:1,81567:102548:1,81568:102549:1,81569:102550:1,81570:102551:1,81571:102552:1,81575:102558:1,81578:102562:1,81580:102564:1,81583:102567:2,81584:102569:1,81585:102570:1,81588:133501:1,81589:102574:1,81590:102575:1,81591:102577:1,81592:102578:1,81594:102580:1,81595:102581:1,81597:102583:1,81598:102584:1,81600:102587:1,81605:102592:1,81609:102597:1,81613:102601:1,81614:102602:1,81615:102603:1,81616:102604:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92220:114292:1,93009:115034:2,93180:115465:1,93191:128246:1,93520:115872:1,93521:115873:1,93522:115874:1,93927:116376:1,95069:117666:1,95071:117668:1,95072:117669:1,95073:117778:1,95080:117677:1,95086:117683:1,95094:117691:1,95095:117692:1,95098:117777:1,95099:117696:1,95105:117702:1,99839:123362:1,103851:128241:2,103856:128309:1,103858:128254:2,103861:128257:1,103863:128259:1,103864:128260:1,103866:128262:1,109748:136006:1,109749:136007:1,109750:136008:1,109998:136486:1,109999:136487:1,110012:136503:1,110092:136593:1,110257:136795:1,110417:137019:1', 'https://www.method.gg/guides'),
(2, 66, 0, 'Default: simc/midnight MID1_Paladin_Protection', '81469:102431:1,81470:102432:1,81471:102433:2,81472:102435:1,81477:102440:1,81479:102443:1,81481:102445:1,81482:102446:2,81483:102448:1,81485:102450:2,81486:102452:1,81487:102453:1,81489:102455:1,81490:102456:1,81493:102461:1,81494:102463:1,81495:102464:1,81498:102467:1,81499:102468:1,81501:102470:1,81502:102471:1,81503:102472:1,81505:136732:1,81506:102475:1,81507:102476:1,81510:133481:1,81597:102583:1,81600:102587:1,81603:102590:1,81604:102591:1,81605:102592:1,81607:102595:1,81609:102597:1,81612:102600:1,81614:102602:1,81616:102604:1,81617:102606:1,81621:102612:2,81629:102621:1,81630:102622:2,81631:128251:1,81632:102625:1,90062:111886:1,93010:102623:1,93187:115479:1,93192:128244:1,93357:115673:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117819:1,95186:117822:1,95187:117823:1,95234:117882:1,99838:123358:1,101927:102451:1,103851:128241:2,103855:128250:1,103857:128253:1,103858:128254:2,103859:128255:1,103860:128256:1,103867:128263:1,103868:128264:1,103877:128278:1,109745:136003:1,109746:136004:1,109747:136005:1,109999:136487:1,110006:136496:1,110012:136503:1,110418:137022:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(2, 70, 0, 'Default: simc/midnight MID1_Paladin_Retribution', '81510:133481:1,81512:115475:1,81521:114828:1,81523:102493:1,81525:102497:1,81526:102498:1,81527:102499:1,81532:102504:1,81533:102505:1,81534:102506:1,81542:102516:1,81543:102518:1,81544:102519:1,81597:102583:1,81600:102587:1,81603:102590:1,81605:102592:1,81608:102596:1,81609:102597:1,81614:102602:1,81615:102603:1,81616:102604:1,81618:128243:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92686:114824:1,92689:114830:1,92838:115022:1,92839:115024:1,92854:115043:1,92952:115165:2,93009:115034:2,93160:115439:2,93161:115440:1,93164:115443:2,93173:115453:1,93174:115454:1,93181:115467:1,93189:115481:1,93190:115483:2,93357:115673:1,95099:117696:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117819:1,95186:117822:1,95187:117823:1,99837:123357:1,103851:128241:2,103861:128257:1,103863:128259:1,103864:128260:1,103867:128263:1,103868:128264:1,109368:135564:1,109369:135565:1,109371:115438:1,109373:115435:1,109374:136809:1,109745:136003:1,109746:136004:1,109747:136005:1,109867:136127:1,109999:136487:1,110012:136503:1,110091:136592:1,110093:136594:1,110419:137025:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- ===== Hunter =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(3, 253, 0, 'Default: method.gg Beast Mastery Hunter (Pack Leader Single Target)', '94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94979:117576:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99832:123347:1,102292:126352:1,102336:126397:2,102339:126400:1,102340:126402:1,102342:126404:1,102343:126405:1,102344:128265:1,102345:126407:2,102346:126408:1,102347:126409:1,102353:126415:1,102354:126416:1,102356:126418:1,102357:126419:1,102358:126420:1,102362:126424:1,102365:126427:1,102367:126430:2,102368:126431:1,102370:126433:1,102372:126435:1,102373:126436:1,102374:126437:1,102376:126439:1,102377:126440:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102395:126459:1,102396:126460:2,102397:126461:1,102401:126465:2,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,107285:132188:1,107286:132189:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109489:135712:1,109802:136060:1,109803:136061:1,109804:136236:1,109961:136446:1,110152:136670:1,110157:136677:1,110158:136679:1,110164:136685:1,110428:137052:1', 'https://www.method.gg/guides'),
(3, 254, 0, 'Default: method.gg Marksmanship Hunter (Sentinel Cleave)', '94958:117555:1,94965:117562:1,94970:117567:1,94971:117568:1,94973:117570:1,94976:117573:1,94978:117575:1,94980:117577:1,94981:117578:1,94989:117586:1,94990:117587:1,99831:123345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102389:126452:1,102390:126453:1,102391:126454:1,102395:126459:1,102396:126460:2,102401:126465:2,102402:126466:1,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103947:128367:1,103956:128376:1,103957:128377:1,103958:132194:1,103961:128383:1,103962:128384:1,103964:128386:1,103966:128388:1,103973:128395:2,103974:128396:1,103975:128397:1,103977:128399:1,103978:128400:1,103979:128401:1,103982:128404:1,103984:128406:1,103985:128407:1,103986:128408:1,103990:128413:1,104095:128609:1,104127:128710:1,104130:128717:1,107288:132192:1,107289:132193:1,107290:132195:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109489:135712:1,109805:136063:1,109807:136065:1,109938:136232:1,109961:136446:1,110028:136521:1,110157:136677:1,110164:136685:1,110430:137058:1,110572:137375:1,110573:137376:1,110574:137377:1,110575:137378:1', 'https://www.method.gg/guides'),
(3, 255, 0, 'Default: method.gg Survival Hunter (Pack Leader Single Target)', '79837:100543:1,94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94976:117573:1,94979:123781:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99833:123350:1,102255:126314:1,102262:126322:1,102263:126323:1,102264:126324:1,102268:126328:1,102270:126330:1,102272:126332:1,102279:126339:1,102282:126342:1,102285:126345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102389:126452:1,102390:126453:1,102391:126454:1,102395:126459:1,102396:126460:2,102401:126465:1,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,109305:135496:1,109307:135498:1,109309:135500:1,109310:135501:1,109311:135502:1,109312:135503:2,109313:135504:2,109316:135507:1,109319:135510:1,109320:135511:2,109321:135512:1,109323:135514:1,109324:135515:1,109470:135689:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109489:135712:1,109802:136060:1,109803:136061:1,109804:136236:1,110154:136673:1,110155:136675:1,110156:136676:1,110157:136677:1,110159:136680:1,110161:136682:1,110162:136683:1,110164:136685:1,110429:137055:1', 'https://www.method.gg/guides');
-- ===== Rogue =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(4, 259, 0, 'Default: simc/midnight MID1_Rogue_Assassination', '90624:112509:2,90625:112510:1,90626:112511:1,90628:112513:1,90633:112518:1,90634:134840:1,90635:112520:1,90636:112521:1,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90740:112630:1,90741:117740:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90756:112648:1,90757:112649:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,90766:112659:2,90767:112660:1,90768:112661:1,90769:112662:1,90770:112663:1,90771:112664:1,90772:112665:2,90777:112670:1,90780:112673:1,90783:112676:1,90784:112677:1,90785:112678:2,90786:112679:1,94536:117106:1,94552:117130:1,94553:117131:1,94554:117133:1,94556:117137:1,94562:117145:1,95107:117704:1,95114:117711:1,95119:117716:1,95120:117717:1,95122:117719:1,95125:117722:1,95127:117724:1,95129:117726:1,95130:117727:1,95136:117733:1,95138:117735:1,95139:117736:1,99844:123371:1,101714:125615:1,109766:136024:1,109767:136025:1,109768:136026:1,110323:136881:1,110433:137067:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(4, 260, 0, 'Default: simc/midnight MID1_Rogue_Outlaw_Fatebound', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90643:112529:1,90645:112531:1,90648:112534:1,90649:112535:1,90652:112538:1,90653:112539:1,90654:112540:1,90655:135732:1,90656:112542:1,90659:112545:1,90661:112547:1,90662:112548:1,90663:112549:1,90664:112551:1,90665:112552:1,90666:112553:2,90668:112555:1,90670:112557:1,90671:112558:1,90676:112563:1,90677:112565:1,90678:112566:2,90679:112567:1,90680:112568:1,90681:112569:1,90683:112571:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90740:112630:1,90741:117740:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90750:112642:1,90751:112643:2,90752:112644:1,90753:112645:1,90754:112646:1,90755:112647:1,90756:112648:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112656:1,90764:112657:1,94562:117145:1,95107:117704:1,95114:125139:1,95119:117716:1,95120:117717:1,95122:117719:1,95125:117722:1,95127:117724:1,95129:117726:1,95130:125140:1,95138:125132:1,95139:117736:1,95140:117737:1,99843:123374:1,101714:125615:1,109766:136024:1,109767:136025:1,109768:136026:1,110323:136881:1,110434:137070:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(4, 261, 0, 'Default: simc/midnight MID1_Rogue_Subtlety', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90690:112578:1,90692:112580:1,90695:112583:1,90697:112585:1,90700:112588:1,90701:136807:1,90703:117172:1,90704:112592:1,90706:112594:2,90709:112597:1,90710:112598:1,90713:112601:1,90716:112604:1,90720:112608:2,90721:112609:1,90722:112610:1,90723:112611:1,90724:112612:1,90726:112614:1,90727:112615:1,90730:112618:1,90732:112620:2,90733:112621:1,90734:112623:1,90737:112627:1,90738:112628:1,90739:112629:1,90740:112630:1,90741:117740:1,90742:114737:1,90743:112633:1,90745:112635:1,90746:112636:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90758:112650:1,90760:112652:1,90762:112654:1,90763:112656:1,90764:112657:1,94562:117145:1,94580:117168:1,94582:117170:1,95106:117703:1,95108:117705:1,95109:117706:1,95110:117707:1,95117:117714:1,95123:117720:1,95131:117728:1,95132:117729:1,95135:117732:1,95136:117733:1,95140:117737:1,95142:117739:1,99842:123373:1,101714:125615:1,101715:125619:1,109760:136018:1,109761:136019:1,109762:136020:1,110323:136881:1,110324:136882:1,110325:136883:1,110432:137064:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- ===== Priest =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(5, 256, 0, 'Default: method.gg Discipline Priest (Oracle)', '82556:103834:1,82564:116182:1,82570:103695:1,82571:136829:1,82572:103697:2,82573:103698:1,82575:103700:1,82576:108226:1,82577:103702:1,82581:103706:1,82582:103708:1,82583:103709:2,82587:103713:1,82588:103714:1,82589:103717:1,82590:103718:1,82591:103719:1,82592:103721:1,82593:103722:1,82594:103723:1,82595:103724:1,82596:103725:1,82597:103726:1,82598:103727:1,82601:103731:1,82602:103732:1,82672:103818:1,82673:103819:1,82676:115884:1,82677:103823:1,82678:103825:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82711:103863:1,82712:103864:1,82713:103865:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,86730:103688:1,94673:117276:1,94674:117277:1,94675:117278:1,94679:117282:1,94683:117286:1,94687:117290:1,94689:117292:1,94690:117293:1,94691:117294:1,94698:117301:1,94700:117303:1,99801:123290:1,108731:134284:1,109006:103841:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109020:134859:1,109021:134860:1,109781:136039:1,109782:136040:1,109783:136041:1,109890:136157:1,110008:136498:1,110277:136828:1,110278:136830:1,110410:136998:1', 'https://www.method.gg/guides'),
(5, 257, 0, 'Default: method.gg Holy Priest (Oracle)', '82554:103675:1,82556:103834:1,82606:103738:1,82608:103740:1,82610:103743:1,82611:103744:2,82612:103745:1,82613:128316:1,82614:103748:1,82615:103749:1,82616:103750:1,82617:103751:1,82618:103752:1,82620:103754:1,82621:103755:1,82622:103756:1,82623:103757:1,82627:103762:1,82630:103765:1,82631:103766:1,82632:103767:1,82633:103769:1,82636:103773:1,82637:103774:1,82638:103775:1,82641:103779:1,82642:103780:1,82672:103818:1,82673:103819:1,82676:115884:1,82677:103823:1,82678:103825:1,82682:103831:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,94673:117276:1,94674:117277:1,94675:117278:1,94679:117282:1,94683:117286:1,94687:117290:1,94689:117292:1,94690:117293:1,94691:117294:1,94698:117301:1,94700:117303:1,99802:123292:1,103901:103676:1,103916:128333:1,104097:128611:1,108724:134273:1,108730:134283:1,108731:134284:1,109006:103841:1,109010:134844:2,109012:134846:1,109015:134849:1,109019:134852:1,109020:134859:1,109021:134860:1,109781:136039:1,109782:136040:1,109783:136041:1,109890:136157:1,109917:136185:1,110409:136995:1', 'https://www.method.gg/guides'),
(5, 258, 0, 'Default: simc/midnight MID1_Priest_Shadow_Voidweaver', '82552:103781:1,82555:103817:1,82556:103834:1,82559:103682:1,82560:103683:2,82563:103686:1,82643:103782:1,82645:103784:2,82647:103786:1,82649:103789:2,82651:103792:1,82654:103796:1,82656:103798:1,82657:103674:1,82658:103799:1,82659:103801:1,82663:103806:1,82665:103808:1,82666:136811:1,82667:103811:1,82668:103812:1,82669:103813:1,82672:103818:1,82673:103819:1,82676:135091:1,82677:103823:1,82678:103825:1,82679:103826:1,82680:103828:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82695:114588:1,82701:103851:1,82703:103853:1,82704:103854:1,82708:103860:1,82711:103863:1,82712:103864:1,82713:103865:1,82715:103867:1,93170:103810:1,93171:115448:1,94668:117271:1,94669:117272:1,94670:117273:1,94684:117287:1,94692:117295:1,94693:123845:1,94694:117297:1,94695:125982:1,94696:117299:1,94703:117306:1,99800:123287:1,100212:123841:1,108007:133378:1,108029:133400:1,108731:134284:1,109006:103841:1,109009:103677:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109017:136223:1,109018:134851:1,109020:134859:1,109021:134860:1,109778:136036:1,109779:136037:1,109780:136038:1,109890:136157:1,109917:136185:1,110408:136992:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- ===== Death Knight =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(6, 250, 0, 'Default: method.gg Blood Death Knight (San''layn Single Target)', '76039:96167:1,76041:96169:1,76042:96170:1,76043:96171:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76056:96184:1,76057:96186:1,76058:96187:1,76061:96190:1,76064:96193:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76076:96205:1,76079:96208:2,76080:96209:1,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76124:96255:1,76125:96256:1,76126:96257:2,76127:96258:1,76128:96259:1,76129:96260:1,76130:96261:1,76131:96262:1,76132:96263:1,76133:96264:1,76135:96266:1,76137:96268:1,76138:96269:1,76141:96273:1,76142:96274:1,76144:96277:1,76146:96279:1,76168:96303:1,76169:96304:1,76170:96305:1,76171:96306:1,76172:96307:1,76173:96308:1,95033:117630:1,95040:117637:1,95045:117642:1,95046:117643:1,95048:136836:1,95051:117648:1,95053:117650:1,95055:117652:1,95056:117891:1,95062:117659:1,95064:117661:1,95065:117662:1,99822:123325:1,102007:126015:1,102008:126016:1,102243:126298:1,102244:126300:1,109736:135994:1,109737:135995:1,109738:135996:1,110030:136524:1,110353:136917:1', 'https://www.method.gg/guides'),
(6, 251, 0, 'Default: method.gg Frost Death Knight (Breath of Sindragosa)', '76033:96161:2,76037:96165:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76075:96204:1,76076:96205:1,76078:96207:1,76079:96208:2,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76091:96220:1,76092:96221:1,76093:96222:1,76096:96225:1,76098:96228:1,76101:96231:1,76103:96233:1,76106:96236:1,76108:96238:1,76109:96239:1,76114:96244:1,76115:96245:1,76116:96246:1,76117:96247:1,76118:96248:1,76121:96252:1,76122:96253:2,76123:96254:1,95032:117629:1,95034:117631:1,95035:123420:1,95036:117633:1,95043:117640:1,95049:117646:1,95057:117654:1,95058:117655:1,95061:117658:1,95062:117659:1,95066:117663:1,95068:117665:1,99821:123324:1,101929:125874:1,101930:125875:1,101931:125876:1,101933:125878:1,102007:126015:1,102008:126016:1,102009:126017:1,106790:131618:1,106791:131619:1,109258:133362:1,109733:135991:1,109734:135992:1,109735:135993:1,110029:136523:1,110030:136524:1,110031:136525:1,110400:136968:1', 'https://www.method.gg/guides'),
(6, 252, 0, 'Default: method.gg Unholy Death Knight (Riders Single Target)', '76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76058:96187:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:133518:1,76076:96205:1,76078:96207:1,76079:96208:2,76080:96209:1,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76148:96282:1,76149:96283:2,76150:96284:2,76156:96290:1,76160:96294:1,76162:96296:1,76176:133514:1,76178:96313:1,76179:96314:1,76182:96318:1,76184:96321:1,76185:96322:1,76186:133365:1,76187:96324:1,76189:96326:1,76190:96327:1,76191:96328:1,76193:96330:1,76196:96333:1,76197:96334:1,95037:123410:1,95041:117638:1,95042:117639:1,95044:117641:1,95047:117644:1,95051:117648:1,95054:117651:1,95059:117656:1,95060:123412:1,95063:117660:1,95066:117663:1,95067:117664:1,99820:123322:1,102007:126015:1,102008:126016:1,108126:133515:1,108129:133522:1,108130:125816:1,108131:133523:1,108151:133546:1,109392:133517:1,109458:135676:1,109739:135997:1,109740:135998:1,109741:135999:1,110029:136523:1,110030:136524:1,110260:136797:1,110354:136920:1', 'https://www.method.gg/guides');
-- ===== Shaman =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(7, 262, 0, 'Default: simc/midnight MID1_Shaman_Elemental_Stormbringer', '80978:101844:1,80981:101850:1,80983:101853:1,80984:127924:1,80985:101855:1,80988:101859:1,80989:101860:1,80990:101861:1,80991:101862:1,80992:101864:1,80993:101865:1,80995:101867:1,80996:101869:1,80997:101870:1,80998:101871:1,80999:136714:1,81000:101873:1,81002:101876:1,81008:101885:1,81012:101889:1,81015:101892:1,81016:101893:1,94858:123631:1,94860:117457:1,94861:117458:1,94862:123632:1,94863:128226:1,94867:117464:1,94868:117465:1,94869:117466:1,94870:117467:1,94873:128225:1,94875:117472:1,94880:117477:1,94883:117480:1,94884:123630:1,94885:117482:1,94886:117483:1,94887:117484:1,94888:117485:1,94889:117486:1,94892:117489:1,94893:117490:1,94894:117491:1,99845:123376:1,103579:127851:1,103581:127854:1,103582:127855:2,103583:127856:1,103584:127857:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127864:1,103593:127868:1,103596:127871:1,103598:127873:1,103602:127877:1,103605:127880:1,103606:127881:1,103607:127882:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103624:127905:1,103625:127906:1,103626:127908:1,103627:127909:1,103628:127910:1,103631:127913:1,103633:127915:1,103634:127916:1,103635:127917:1,103638:127919:1,103639:127920:1,103640:127921:1,109387:135591:1,109727:135985:1,109728:135986:1,109729:135987:1,109730:135988:1,109731:135989:1,109732:135990:1,110066:136561:1,110085:136585:1,110402:136974:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(7, 263, 0, 'Default: simc/midnight MID1_Shaman_Enhancement_Totemic', '80938:101801:1,80939:101802:1,80941:101804:1,80942:101805:1,80943:101806:1,80945:101809:2,80947:101811:1,80948:101812:1,80949:101813:1,80950:101814:2,80951:101815:1,80953:101818:1,80954:101819:1,80958:101823:1,80959:101824:1,80960:101825:1,80961:101826:1,80962:101827:1,80963:101828:1,80964:101829:1,80967:101832:1,80968:101833:1,80969:101834:1,80973:101839:1,80974:101840:1,80975:101841:1,94859:117456:1,94866:125824:1,94871:117468:1,94872:117469:1,94874:117471:1,94877:117474:1,94879:117476:1,94881:125822:1,94882:117479:1,94890:117487:1,94891:117488:1,94892:117489:1,99847:123379:1,103581:127854:1,103582:127855:2,103583:127856:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127865:1,103593:127868:1,103594:127869:1,103596:127871:1,103602:127877:1,103605:127880:1,103606:127881:1,103607:127882:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103622:127902:1,103624:127905:1,103625:127906:1,103627:127909:1,103628:127910:1,103871:128270:1,109194:128236:1,109386:135590:1,109387:135591:1,109388:135592:1,109389:135593:1,109724:135982:1,109725:135983:1,109726:135984:1,110085:136585:1,110401:136971:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(7, 264, 0, 'Default: method.gg Restoration Shaman (Totemic Downpour)', '80976:101842:1,81018:101895:1,81019:101896:1,81021:101899:1,81022:101900:1,81024:101902:1,81027:101905:1,81031:101911:1,81032:101912:1,81033:135485:1,81037:101919:1,81040:101923:1,81041:101924:1,81044:101928:1,81047:101932:1,81048:101934:1,81049:101935:1,81050:101936:1,81051:101937:1,81052:101939:2,81055:101942:1,81073:101964:1,92675:114811:1,92677:114813:1,94859:117456:1,94866:125824:1,94871:117468:1,94872:117469:1,94874:117471:1,94877:117474:1,94879:117476:1,94881:125822:1,94882:117479:1,94888:117485:1,94890:117487:1,94891:117488:1,99846:123378:1,103428:127672:1,103430:127674:1,103434:127680:1,103436:127682:1,103581:127853:1,103582:127855:2,103584:127857:1,103586:127859:1,103587:127860:1,103588:127861:1,103590:127863:1,103591:127864:1,103593:127868:1,103594:127869:1,103596:127871:1,103598:127873:1,103601:127876:1,103602:127877:1,103606:127881:1,103607:127883:1,103611:127888:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103622:127902:1,103625:127906:1,103626:127908:1,103627:127909:1,104124:128703:1,109301:135487:1,109386:135590:1,109387:135591:1,109388:135592:1,109724:135982:1,109725:135983:1,109726:135984:1,110085:136585:1,110403:136977:1', 'https://www.method.gg/guides');
-- ===== Mage =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(8, 62, 0, 'Default: simc/midnight MID1_Mage_Arcane_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62121:80180:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,93524:115877:1,94647:117250:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99830:123344:1,101883:125818:1,102438:126508:1,102440:126510:1,102441:126511:1,102445:126515:1,102446:126516:1,102449:126519:1,102453:126523:1,102454:136465:1,102460:126530:1,102465:134020:1,102467:126537:1,102468:126538:1,102469:126539:1,102470:126540:1,102471:126541:1,102473:126543:1,102474:126544:1,102475:126545:1,102480:126550:2,104113:128689:1,108536:134024:1,108537:134026:2,108538:134027:1,108539:134028:1,108551:134047:1,108654:134183:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108664:134194:1,108665:134196:1,109002:134834:1,109667:135918:1,109668:135919:1,109669:135920:1,110080:136578:1,110081:136579:1,110420:137028:1,110442:137084:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(8, 63, 0, 'Default: simc/midnight MID1_Mage_Fire_Sunfury', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62119:80178:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,93524:115877:1,94643:117246:1,94644:117247:1,94645:117248:1,94646:117249:1,94647:117250:1,94648:117251:1,94649:117252:1,94650:117253:1,94651:117254:1,94652:117255:1,94653:117256:1,99829:123340:1,100989:124750:1,100995:124756:1,100998:124759:1,100999:124760:1,101007:135618:1,101009:124771:1,101019:124783:2,101024:124789:1,101027:124793:1,101029:124795:2,108654:134182:1,108656:134186:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108662:134192:2,109393:135600:1,109395:135603:1,109396:135604:1,109398:135606:1,109399:135607:1,109401:135609:1,109402:135610:1,109403:135612:1,109404:135613:2,109407:135616:1,109408:135617:1,109409:135602:1,109411:135621:1,109673:135924:1,109674:135925:1,109675:135926:1,109956:136441:1,110080:136578:1,110081:136579:1,110086:136587:1,110088:136589:1,110321:136878:1,110322:136879:1,110423:137037:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(8, 64, 0, 'Default: simc/midnight MID1_Mage_Frost_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62107:80165:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62117:80176:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,62129:80189:1,62150:134540:1,62153:80216:1,62157:80220:1,62164:80227:1,62170:80234:1,62173:80237:1,62176:80241:1,62177:80242:1,62178:80243:1,62179:80244:1,62180:80245:1,62181:80247:1,62182:80248:1,62184:80250:1,81468:102429:1,93524:115877:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99828:123339:1,103771:134418:1,108653:134180:1,108654:134183:1,108655:134185:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108849:134405:1,108850:134406:1,108851:134407:1,108852:134408:1,108855:134411:1,108858:134414:2,108859:134415:1,108864:134421:1,109667:135918:1,109668:135919:1,109669:135920:1,109915:136182:1,109916:136183:1,109956:136441:1,110081:136579:1,110258:136796:1,110283:136837:1,110422:137034:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- ===== Warlock =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(9, 265, 0, 'Default: simc/midnight MID1_Warlock_Affliction_Soul_Harvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91446:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,72032:91552:1,72033:91553:1,72034:91554:1,72037:91558:1,72041:91562:1,72045:124692:1,72047:91568:1,72049:91570:1,72050:91571:1,72051:91572:1,72054:91576:1,72055:91577:2,72058:91580:2,94821:117418:1,94823:117420:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94840:117437:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94857:117454:1,99850:123384:1,100941:124694:1,102031:126064:1,102247:126303:1,109837:136096:1,109838:136097:1,109839:136098:1,109842:136102:2,109843:136103:1,109844:136104:1,109845:136105:1,109847:136107:1,109849:136109:1,109852:136112:1,109855:136115:1,109857:136117:1,109859:136119:1,109860:136120:1,109861:136121:1,109862:136122:1,109863:136123:1,109865:136125:2,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110269:136812:1,110270:136813:1,110405:136983:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(9, 266, 0, 'Default: simc/midnight MID1_Warlock_Demonology_Soul_Harvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71955:91466:1,71956:91468:1,71957:91469:1,94821:117418:1,94823:123839:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94855:117452:1,94857:117454:1,99849:123383:1,100941:124694:1,101887:125829:2,101891:125834:1,101893:136731:1,101894:125837:1,101895:125839:1,101903:125848:2,101905:125850:1,101908:125854:1,101909:125855:1,101914:125860:2,101920:125866:1,101923:125869:1,109244:135306:1,109248:135310:1,109249:135311:2,109250:135312:1,109251:135313:1,109252:135314:1,109253:135315:1,109257:135319:1,109837:136096:1,109838:136097:1,109839:136098:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109847:136107:1,109934:136227:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110191:136719:1,110193:136721:1,110194:136722:1,110197:136726:1,110198:136727:1,110404:136980:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(9, 267, 0, 'Default: simc/midnight MID1_Warlock_Destruction_Hellcaller', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,71960:91473:1,71965:91478:1,71968:91481:1,71969:91482:2,71971:91484:1,71973:91486:1,71975:91489:1,71980:91496:1,71983:91500:2,71985:91502:1,72059:91581:1,72060:91582:1,72061:91583:1,72062:91584:1,72065:91588:1,72066:91589:2,72067:91590:1,72068:91591:1,72069:91592:1,94822:117419:1,94829:117426:1,94834:117431:1,94835:117432:1,94837:117434:1,94840:117437:1,94842:117439:1,94844:117441:1,94845:117442:1,94853:117450:1,94854:123310:1,94855:117452:1,99848:123382:1,100941:124694:1,101992:126002:1,101994:126004:1,108678:134219:1,108681:134221:1,109834:136093:1,109835:136094:1,109836:136095:1,109841:136101:1,109842:136102:2,109843:136103:1,109845:136105:1,109847:136107:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110280:136833:1,110281:136834:2,110282:136835:1,110406:136986:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- ===== Monk =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(10, 268, 0, 'Default: simc/midnight MID1_Monk_Brewmaster', '101064:124838:1,101065:136148:1,101067:136146:1,101069:124843:1,101071:124845:1,101072:124846:1,101074:124848:2,101075:124849:1,101076:124850:1,101078:124852:1,101079:124854:1,101080:124855:1,101082:124857:1,101086:124863:1,101087:124864:1,101088:124865:1,101135:124924:1,101136:124926:1,101140:124930:1,101142:124932:1,101145:124935:1,101146:124936:1,101147:124937:1,101152:124943:1,101153:124944:1,101156:124948:1,101160:124954:1,101161:124955:1,101163:124957:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101177:124974:1,101178:124975:1,101179:124976:2,101181:124979:1,101182:124980:1,101183:124982:1,101184:124983:2,101187:124987:1,101188:124988:1,101190:124991:1,101193:124996:1,101195:124999:1,101197:125001:1,101198:125003:1,101201:125006:1,101202:125008:1,101219:125028:1,101220:125029:1,101221:125031:1,101222:125032:1,101223:125033:1,101224:125035:1,101225:125036:1,101226:125037:1,101227:125039:1,101228:125040:1,101229:125042:1,101230:125043:1,101248:125069:1,101711:125002:1,102004:124859:1,102433:126501:1,109694:135952:1,109695:135953:1,109696:135954:1,109826:136085:1,109827:136086:1,109882:136145:1,109910:136177:1,110435:137075:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(10, 269, 0, 'Default: simc/midnight MID1_Monk_Windwalker', '101035:124805:2,101036:124806:1,101037:124807:1,101039:124810:1,101044:126026:1,101045:124817:1,101048:124820:1,101051:124823:1,101052:124825:1,101053:124826:1,101054:124827:1,101055:124828:1,101056:124829:1,101057:124830:1,101059:124833:1,101060:124834:1,101136:124926:1,101137:124927:1,101140:124930:1,101142:124932:1,101146:124936:1,101147:124937:1,101149:124939:1,101150:124941:1,101153:124944:1,101159:124953:1,101160:124954:1,101162:124956:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101178:124975:1,101179:124976:2,101182:124980:1,101183:124982:1,101184:124983:2,101185:124984:1,101186:124985:1,101203:125009:1,101205:125012:1,101206:125013:1,101207:134452:1,101208:125015:1,101209:125016:1,101210:125017:1,101213:125020:1,101215:125022:1,101216:125023:1,101217:125025:1,101218:125026:1,101232:125046:1,101243:125062:1,101244:125063:1,101245:125065:1,101246:125066:1,101247:125068:1,101248:125069:1,101249:125070:1,101250:125071:1,101251:125072:1,101252:125073:1,101253:125074:1,101254:125076:1,108946:134543:1,109697:135955:1,109698:135956:1,109699:135957:1,110022:136514:1,110023:136515:1,110025:136518:1,110098:136599:1,110436:137076:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(10, 270, 0, 'Default: method.gg Mistweaver Monk (Conduit of the Celestials)', '101089:124866:1,101093:124871:1,101095:124873:1,101096:124875:1,101097:124876:1,101102:128221:1,101104:124885:1,101107:124888:1,101108:124889:1,101110:124891:1,101111:124892:2,101112:124893:1,101113:124894:1,101114:124896:2,101115:124897:1,101117:124899:1,101121:124905:1,101122:124906:1,101123:124907:1,101124:124908:2,101127:125932:1,101128:124913:1,101129:124915:1,101130:124916:1,101131:124918:1,101132:124920:1,101133:124921:1,101134:124922:1,101136:124926:1,101139:124929:1,101140:124930:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101153:124944:1,101157:124949:1,101161:124955:1,101164:124958:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101179:124976:2,101183:124982:1,101185:124984:1,101186:124985:1,101223:125033:1,101231:125045:1,101233:125049:1,101234:125050:1,101235:125052:1,101236:125054:1,101237:125055:1,101238:125056:1,101239:125058:1,101240:125059:1,101242:125061:1,102432:126500:1,109516:135749:1,109700:135958:1,109701:135959:1,110019:136510:1,110021:136512:1,110024:136517:1,110026:136519:1,110027:136520:1,110067:136562:1,110097:136598:1,110211:136747:1,110218:136754:1', 'https://www.method.gg/guides');
-- ===== Druid =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(11, 102, 0, 'Default: simc/midnight MID1_Druid_Balance', '82198:103276:1,82201:103279:1,82202:103280:1,82206:103284:1,82207:128589:1,82208:103286:1,82209:103287:1,82210:103288:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82228:103306:1,82229:103307:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82237:103316:1,82241:103320:1,82246:103326:1,88201:109833:1,88202:109834:1,88203:109835:1,88204:109836:1,88206:109839:1,88207:109840:2,88208:109842:1,88212:109846:1,88213:109847:1,88214:109848:2,88215:109849:1,88218:109852:1,88221:109856:1,88222:109857:1,88223:109858:1,88224:109859:1,88225:109861:1,88226:109862:1,88227:109863:2,88231:109867:1,88234:109870:1,88235:109871:1,88236:109872:1,91048:115458:1,92229:114300:1,93714:116102:1,94585:117772:1,94586:117178:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:123304:1,94598:117193:1,94600:117195:1,94607:117204:1,94608:117205:1,99808:123302:1,100174:123793:1,100175:123794:1,100176:123795:1,100177:123796:2,100223:123868:1,103846:128230:1,103847:128231:1,104078:128579:1,104080:128584:1,104083:128588:1,104085:128591:1,108032:133404:1,109718:135976:1,109719:135977:1,109720:135978:1,110421:137031:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(11, 103, 0, 'Default: simc/midnight MID1_Druid_Feral_Wildstalker', '82088:103147:1,82091:103150:1,82092:103152:1,82096:103157:1,82098:103159:1,82099:103160:1,82100:103161:1,82101:103162:1,82102:103163:1,82103:103164:1,82104:103165:1,82106:103167:1,82107:103168:1,82108:103170:1,82110:103173:1,82111:103174:1,82112:103175:1,82113:103176:1,82114:103177:1,82115:103179:2,82116:103180:1,82118:103182:1,82119:103183:1,82121:103185:2,82122:103186:1,82123:103187:1,82124:103188:1,82198:103276:1,82199:103277:1,82206:103284:1,82207:128589:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82222:103300:1,82223:103301:1,82224:103302:1,82225:103303:2,82228:103306:1,82229:103307:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82239:103318:1,82241:103320:1,82242:103322:1,82243:103323:2,82244:103324:1,82246:103326:1,92641:114771:1,94609:117206:1,94621:117221:1,94622:119855:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117229:1,94629:117231:1,94630:117232:1,94631:117234:1,99805:123296:1,100175:123794:1,100176:123795:1,100177:123796:2,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109715:135973:1,109716:135974:1,109717:135975:1,110426:137046:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(11, 104, 0, 'Default: simc/midnight MID1_Druid_Guardian', '82126:103190:1,82127:103191:1,82129:103193:1,82131:103195:1,82135:103199:1,82136:103201:1,82138:103203:2,82140:103206:1,82142:103209:1,82143:103210:2,82145:103212:1,82146:103213:2,82147:135336:1,82149:103216:1,82152:103221:1,82153:103222:1,82160:103229:1,82161:103230:1,82198:103276:1,82199:103277:1,82206:103284:1,82208:103286:1,82209:103287:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82223:103301:1,82224:103302:1,82225:103303:2,82227:103305:1,82228:103306:1,82229:103307:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82237:103316:1,82239:103318:1,82241:103320:1,82242:103322:1,82243:103323:1,82246:103326:1,91044:112967:1,91046:112969:1,92226:103208:1,92227:103218:1,92585:114698:1,92586:114699:1,92587:114700:1,94608:117205:1,94609:117206:1,94610:117207:1,94611:117208:1,94612:117210:1,94613:117211:1,94614:117214:1,94615:117215:1,94616:117216:1,94618:117218:1,94619:117219:1,94620:117220:1,99807:123301:1,100175:123794:1,100176:123795:1,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109375:135568:1,109377:135491:1,109378:135570:1,109379:135490:1,109721:135979:1,109722:135980:1,109723:136624:1,110431:137061:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(11, 105, 0, 'Default: method.gg Restoration Druid (Wildstalker)', '82043:117104:1,82045:103096:1,82047:103098:1,82049:103100:1,82050:103101:1,82051:103102:1,82052:103105:1,82053:103106:1,82054:103108:1,82055:103109:1,82057:103111:1,82058:103112:1,82059:103113:1,82060:103114:1,82063:103118:1,82064:103119:1,82065:103121:1,82068:103124:1,82071:103127:1,82072:103128:1,82073:103129:1,82074:114809:1,82076:103132:1,82079:103137:1,82082:103141:1,82083:103142:1,82198:103275:1,82205:103283:1,82206:103284:1,82207:128589:1,82209:103287:1,82210:103288:1,82214:103292:2,82217:103295:1,82218:103296:1,82219:103297:1,82220:103298:1,82225:103303:2,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82240:103319:1,82243:103323:2,82244:103324:1,94600:117195:1,94621:117221:1,94622:119855:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117229:1,94629:117231:1,94630:117232:1,94631:117233:1,99806:123298:1,100173:123792:1,100175:123794:1,100176:123795:1,100177:123796:2,100223:123868:1,103873:128274:1,103874:128708:1,103876:128277:1,104082:128586:1,104084:128590:1,104085:128591:1,104125:128707:1,109715:135973:1,109716:135974:1,109717:135975:1,110424:137040:1', 'https://www.method.gg/guides');
-- ===== Demon Hunter =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(12, 577, 0, 'Default: simc/midnight MID1_Demon_Hunter_Havoc_Fel-Scarred', '90914:112823:1,90919:112828:1,90921:112830:1,90922:112831:1,90923:112832:1,90925:112834:1,90928:112838:1,90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90937:112848:1,90938:112849:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90993:112911:1,90994:117768:1,90997:117755:1,91000:112918:2,91001:112919:1,91002:112921:1,91003:112923:1,91004:112924:2,91006:112926:1,91007:112927:1,91008:112928:1,91011:112932:1,91012:117764:1,91013:112934:1,91015:112936:2,91017:112938:1,91018:112939:1,91021:117744:1,91022:112944:1,91024:117765:1,91025:112948:1,91026:112949:1,91027:112950:1,91028:112951:1,91032:112955:1,91034:112957:2,91036:112959:1,93013:115244:1,93015:115246:1,93016:115248:1,94899:124010:1,94901:117498:1,94902:117499:1,94904:117501:1,94905:117502:1,94909:117506:1,94912:117509:1,94913:124011:1,94915:117512:1,94916:117513:1,94917:117514:1,94918:117515:1,95143:117741:1,95147:117754:2,95149:117758:1,95150:117759:1,95152:117762:1,99824:123329:1,109772:136030:1,109773:136031:1,109774:136032:1,110011:136501:1,110427:137049:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(12, 581, 0, 'Default: simc/midnight MID1_Demon_Hunter_Vengeance_Annihilator', '90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90951:112864:1,90952:112865:1,90953:112866:1,90955:112868:1,90958:112872:2,90959:112873:1,90960:112875:1,90961:112876:1,90962:112877:2,90963:112878:1,90964:112879:1,90968:112883:1,90970:112886:1,90971:112887:1,90972:112888:1,90974:112890:1,90975:112891:1,90977:112893:1,90978:112894:1,90980:112896:1,90981:112897:2,90984:112900:1,90986:112902:1,90987:112903:1,90989:112906:1,90990:112907:1,90991:112908:1,90994:112912:1,90996:112914:2,90999:112917:1,91000:112918:2,91001:112920:1,91002:112921:1,91004:112924:2,91006:112926:1,91007:112927:1,95149:117758:1,95150:117759:1,95151:117761:1,95152:117762:1,99823:134253:1,108722:134271:1,108729:134282:1,109442:135660:1,109443:135661:1,109444:135662:1,109445:135663:1,109446:135664:1,109447:135665:1,109448:135659:1,109449:135667:1,109450:136810:1,109451:135669:1,109452:135670:1,109453:135671:1,109454:135672:1,109455:135673:1,110011:136501:1,110425:137043:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- ===== Evoker =====
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(13, 1467, 0, 'Default: simc/midnight MID1_Evoker_Devastation_SC', '93272:115578:1,93273:115579:1,93274:115580:2,93275:115581:1,93280:115587:1,93281:115588:2,93284:115592:1,93285:115593:1,93289:115597:1,93294:115602:1,93295:115603:2,93297:115606:1,93298:115607:1,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93313:115623:1,93314:115624:1,93316:115627:1,93318:115630:1,93319:115631:1,93320:115632:1,93322:115634:1,93323:115635:1,93324:115636:1,93325:115637:1,93326:115638:1,93327:115639:1,93328:115640:1,93329:115641:1,93330:115642:1,93331:115643:1,93332:115645:1,93333:115646:1,93334:115647:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93366:115683:1,93715:116103:1,94921:117518:1,94928:117525:1,94933:117530:1,94934:117531:1,94936:117533:1,94939:117536:1,94941:117538:1,94943:120123:1,94944:117541:1,94950:117547:1,94952:117549:1,94953:117550:1,98931:122279:1,99827:123333:1,103843:128216:1,103844:128217:1,109793:136051:1,109794:136052:1,109795:136053:1,110064:136559:1,110414:137010:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1'),
(13, 1468, 0, 'Default: method.gg Preservation Evoker (Chronowarden Raid)', '93238:115540:1,93239:115541:1,93240:115542:1,93241:115543:1,93242:115544:1,93243:115546:1,93245:115549:1,93246:115550:1,93250:115554:1,93253:115557:1,93254:115558:2,93255:115559:1,93257:115561:1,93258:115562:1,93260:115565:1,93262:115567:1,93263:115568:2,93264:115570:1,93265:115571:1,93266:115572:1,93267:115573:1,93268:115574:2,93269:115575:1,93271:115577:1,93288:115596:1,93289:115597:1,93291:115599:1,93292:115600:2,93294:115602:1,93299:115608:1,93300:115609:1,93302:115611:2,93304:115613:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93336:115650:1,93337:115651:1,93338:115652:1,93339:115653:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93347:115662:2,93348:115663:1,93350:115665:1,93351:125610:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93715:116103:1,94925:117522:1,94929:117526:1,94930:126310:1,94932:117786:1,94935:117532:1,94942:117539:1,94947:117544:1,94948:117545:1,94950:117547:1,94951:117548:1,94954:117551:1,94955:117552:1,99826:123335:1,103843:128216:1,109508:135741:1,109509:135742:1,109510:135743:1,110064:136559:1,110413:137007:1', 'https://www.method.gg/guides'),
(13, 1473, 0, 'Default: method.gg Augmentation Evoker (Chronowarden ST+Cleave)', '93195:115493:1,93197:115495:1,93198:115496:1,93199:115690:1,93200:115498:1,93201:115499:1,93202:115500:1,93203:115502:1,93205:115504:1,93206:115505:1,93207:115506:1,93208:115507:1,93209:115508:1,93211:115511:1,93212:115512:1,93219:115519:1,93220:115520:1,93221:115521:1,93222:115522:1,93223:115523:1,93226:115527:1,93229:115530:1,93232:115533:1,93234:115536:1,93271:115577:1,93287:115595:1,93288:115596:1,93289:115597:1,93290:115598:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93345:115660:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93354:115669:1,93355:115670:2,93358:115675:1,93367:115685:1,93368:115688:1,93369:115686:1,93715:116103:1,94925:117522:1,94929:117526:1,94930:126310:1,94932:117529:1,94935:117532:1,94942:117539:1,94947:117544:1,94948:117545:1,94951:117548:1,94954:117551:1,94955:117552:1,98931:122279:1,99825:123334:1,102248:126304:1,102249:126305:1,103843:128216:1,109508:135741:1,109509:135742:1,109510:135743:1,110415:137013:1', 'https://www.method.gg/guides');
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (7, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
@@ -0,0 +1,117 @@
-- Migration: 0008_talent_builds_per_context
-- Date: 2026-05-07
-- Purpose: Populate per-context (M+/PvP/Leveling) talent loadouts in
-- playerbot_v2_talent_build for the subset of (class, spec, context)
-- tuples where a curated build is honestly sourceable today.
--
-- Research summary
-- ----------------
-- 1. simc/midnight branch (the source for 0004_simc_seed.sql) publishes ONLY
-- raid profiles for Midnight (profiles/MID1/MID1_*.simc). There are no
-- M+/PvP/Leveling .simc files on that branch — the directory listing
-- confirms 50 raid-only profiles. Historic dragonflight branches had the
-- same convention. Conclusion: simc cannot seed contexts 2/3/4.
--
-- 2. method.gg / wowhead publish per-context builds as base64 talent strings
-- on guide pages. Decoding them requires (a) the simc trait_data.inc DB
-- for the live wow build (currently 12.0.5.67314 — used by 0004) and
-- (b) re-running decode_simc.py against fresh profile headers. The
-- trait_data.inc isn't checked in (decode_simc.py expects it at
-- src/modules/PlayerbotV2/Bot/Talent/data/trait_data.inc; not present
-- in this tree), and bulk-decoding 30-100 fresh strings is out of scope
-- for a one-shot migration. Deferred for a future pass.
--
-- 3. TraitMgr starter builds (DB2-driven SkillLine_TraitTree starters) cover
-- the Leveling case natively — at sub-cap level the TraitMgr starter is
-- objectively correct (player doesn't have all talent points yet), and
-- the API loader in PlayerbotAPI.cpp already falls back to TraitMgr when
-- no curated row matches. Seeding curated max-level loadouts for
-- context=4/Leveling would actively harm low-level bots, so we
-- intentionally do NOT populate Leveling.
--
-- 4. PvP talents come from a separate system (PvP_Talent.db2 — not the
-- Trait_*.db2 family that this table represents). A "context=3 PvP"
-- talent row would only carry the PvE talents you'd take for arenas/BGs;
-- it cannot encode honor talents. Without a sourced/curated PvP-PvE-talent
-- string per spec we'd just be mirroring the raid build with a misleading
-- label. Deferred for a future pass.
--
-- What this migration ships
-- -------------------------
-- Tank M+ rows (context=2). For tank specs, the high-key M+ build and the
-- raid build genuinely overlap — both prioritize survivability + threat +
-- single-target/cleave throughput, and method.gg/Wowhead routinely publish
-- a single "Mythic+ / Raid" combined build per tank spec. Mirroring 0004's
-- raid loadout into context=2 with an honest "mirrors raid build" label
-- gives the M+ branch of the API a genuine curated build instead of
-- bouncing off context=2 → context=0 fallback for every tank dispatch.
--
-- Coverage: 6/117 rows (6 tank specs × M+ context).
-- Remaining 111 rows deferred — see notes 1-4 above.
-- Reverts: yes (DELETE rows; re-run the migration to repopulate).
-- Populated 6/117 rows
-- ===== Tank M+ (context=2): mirror of curated raid build =====
-- Each entries_json below is byte-for-byte identical to the corresponding
-- row in 0004_simc_seed.sql (context=1) / 0007_talent_builds_seed.sql
-- (context=0). Honest "mirrors raid" label so future maintainers know to
-- re-source these when method.gg ships a divergent M+ build.
-- Protection Warrior (class 1, spec 73) — simc/midnight raid loadout.
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(1, 73, 2, 'M+: mirrors raid (simc/midnight MID1_Warrior_Protection)',
'90261:112112:1,90264:132884:1,90265:112116:1,90295:112149:1,90296:112150:1,90297:112151:1,90298:112152:1,90301:112155:1,90302:112156:1,90303:112157:1,90304:112158:1,90305:112159:1,90306:112160:1,90308:112162:1,90309:112163:1,90310:112165:1,90311:112166:2,90312:132885:1,90314:112170:1,90317:112173:1,90318:112174:1,90319:112176:1,90320:112177:1,90324:112181:2,90326:112183:1,90328:112185:1,90329:112186:1,90330:112187:1,90331:112188:1,90343:112205:1,90346:112208:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90432:112304:1,90433:112305:1,90448:112321:1,90449:112323:1,90451:112325:1,94785:117382:1,94792:118834:1,94797:117394:1,94798:117395:1,94800:117397:1,94803:117400:1,94805:117402:1,94807:117404:1,94808:117405:1,94816:117413:1,94817:118835:1,95956:118850:1,95959:118853:1,99851:123388:1,107577:132882:1,107578:132883:1,108542:134031:1,108543:134032:1,108544:134033:1,108686:134226:1,108705:136627:1,109391:135597:1,109809:136068:1,109810:136069:1,109811:136070:1,110118:136625:1,110119:136626:1,110411:137001:1',
'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- Protection Paladin (class 2, spec 66) — simc/midnight raid loadout.
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(2, 66, 2, 'M+: mirrors raid (simc/midnight MID1_Paladin_Protection)',
'81469:102431:1,81470:102432:1,81471:102433:2,81472:102435:1,81477:102440:1,81479:102443:1,81481:102445:1,81482:102446:2,81483:102448:1,81485:102450:2,81486:102452:1,81487:102453:1,81489:102455:1,81490:102456:1,81493:102461:1,81494:102463:1,81495:102464:1,81498:102467:1,81499:102468:1,81501:102470:1,81502:102471:1,81503:102472:1,81505:136732:1,81506:102475:1,81507:102476:1,81510:133481:1,81597:102583:1,81600:102587:1,81603:102590:1,81604:102591:1,81605:102592:1,81607:102595:1,81609:102597:1,81612:102600:1,81614:102602:1,81616:102604:1,81617:102606:1,81621:102612:2,81629:102621:1,81630:102622:2,81631:128251:1,81632:102625:1,90062:111886:1,93010:102623:1,93187:115479:1,93192:128244:1,93357:115673:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117819:1,95186:117822:1,95187:117823:1,95234:117882:1,99838:123358:1,101927:102451:1,103851:128241:2,103855:128250:1,103857:128253:1,103858:128254:2,103859:128255:1,103860:128256:1,103867:128263:1,103868:128264:1,103877:128278:1,109745:136003:1,109746:136004:1,109747:136005:1,109999:136487:1,110006:136496:1,110012:136503:1,110418:137022:1',
'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- Blood Death Knight (class 6, spec 250) — method.gg raid loadout.
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(6, 250, 2, 'M+: mirrors raid (method.gg Blood DK San''layn)',
'76039:96167:1,76041:96169:1,76042:96170:1,76043:96171:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76056:96184:1,76057:96186:1,76058:96187:1,76061:96190:1,76064:96193:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76076:96205:1,76079:96208:2,76080:96209:1,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76124:96255:1,76125:96256:1,76126:96257:2,76127:96258:1,76128:96259:1,76129:96260:1,76130:96261:1,76131:96262:1,76132:96263:1,76133:96264:1,76135:96266:1,76137:96268:1,76138:96269:1,76141:96273:1,76142:96274:1,76144:96277:1,76146:96279:1,76168:96303:1,76169:96304:1,76170:96305:1,76171:96306:1,76172:96307:1,76173:96308:1,95033:117630:1,95040:117637:1,95045:117642:1,95046:117643:1,95048:136836:1,95051:117648:1,95053:117650:1,95055:117652:1,95056:117891:1,95062:117659:1,95064:117661:1,95065:117662:1,99822:123325:1,102007:126015:1,102008:126016:1,102243:126298:1,102244:126300:1,109736:135994:1,109737:135995:1,109738:135996:1,110030:136524:1,110353:136917:1',
'https://www.method.gg/guides');
-- Brewmaster Monk (class 10, spec 268) — simc/midnight raid loadout.
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(10, 268, 2, 'M+: mirrors raid (simc/midnight MID1_Monk_Brewmaster)',
'101064:124838:1,101065:136148:1,101067:136146:1,101069:124843:1,101071:124845:1,101072:124846:1,101074:124848:2,101075:124849:1,101076:124850:1,101078:124852:1,101079:124854:1,101080:124855:1,101082:124857:1,101086:124863:1,101087:124864:1,101088:124865:1,101135:124924:1,101136:124926:1,101140:124930:1,101142:124932:1,101145:124935:1,101146:124936:1,101147:124937:1,101152:124943:1,101153:124944:1,101156:124948:1,101160:124954:1,101161:124955:1,101163:124957:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101177:124974:1,101178:124975:1,101179:124976:2,101181:124979:1,101182:124980:1,101183:124982:1,101184:124983:2,101187:124987:1,101188:124988:1,101190:124991:1,101193:124996:1,101195:124999:1,101197:125001:1,101198:125003:1,101201:125006:1,101202:125008:1,101219:125028:1,101220:125029:1,101221:125031:1,101222:125032:1,101223:125033:1,101224:125035:1,101225:125036:1,101226:125037:1,101227:125039:1,101228:125040:1,101229:125042:1,101230:125043:1,101248:125069:1,101711:125002:1,102004:124859:1,102433:126501:1,109694:135952:1,109695:135953:1,109696:135954:1,109826:136085:1,109827:136086:1,109882:136145:1,109910:136177:1,110435:137075:1',
'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- Guardian Druid (class 11, spec 104) — simc/midnight raid loadout.
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(11, 104, 2, 'M+: mirrors raid (simc/midnight MID1_Druid_Guardian)',
'82126:103190:1,82127:103191:1,82129:103193:1,82131:103195:1,82135:103199:1,82136:103201:1,82138:103203:2,82140:103206:1,82142:103209:1,82143:103210:2,82145:103212:1,82146:103213:2,82147:135336:1,82149:103216:1,82152:103221:1,82153:103222:1,82160:103229:1,82161:103230:1,82198:103276:1,82199:103277:1,82206:103284:1,82208:103286:1,82209:103287:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82223:103301:1,82224:103302:1,82225:103303:2,82227:103305:1,82228:103306:1,82229:103307:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82237:103316:1,82239:103318:1,82241:103320:1,82242:103322:1,82243:103323:1,82246:103326:1,91044:112967:1,91046:112969:1,92226:103208:1,92227:103218:1,92585:114698:1,92586:114699:1,92587:114700:1,94608:117205:1,94609:117206:1,94610:117207:1,94611:117208:1,94612:117210:1,94613:117211:1,94614:117214:1,94615:117215:1,94616:117216:1,94618:117218:1,94619:117219:1,94620:117220:1,99807:123301:1,100175:123794:1,100176:123795:1,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109375:135568:1,109377:135491:1,109378:135570:1,109379:135490:1,109721:135979:1,109722:135980:1,109723:136624:1,110431:137061:1',
'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- Vengeance Demon Hunter (class 12, spec 581) — simc/midnight raid loadout.
INSERT IGNORE INTO playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url) VALUES
(12, 581, 2, 'M+: mirrors raid (simc/midnight MID1_DH_Vengeance_Annihilator)',
'90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90951:112864:1,90952:112865:1,90953:112866:1,90955:112868:1,90958:112872:2,90959:112873:1,90960:112875:1,90961:112876:1,90962:112877:2,90963:112878:1,90964:112879:1,90968:112883:1,90970:112886:1,90971:112887:1,90972:112888:1,90974:112890:1,90975:112891:1,90977:112893:1,90978:112894:1,90980:112896:1,90981:112897:2,90984:112900:1,90986:112902:1,90987:112903:1,90989:112906:1,90990:112907:1,90991:112908:1,90994:112912:1,90996:112914:2,90999:112917:1,91000:112918:2,91001:112920:1,91002:112921:1,91004:112924:2,91006:112926:1,91007:112927:1,95149:117758:1,95150:117759:1,95151:117761:1,95152:117762:1,99823:134253:1,108722:134271:1,108729:134282:1,109442:135660:1,109443:135661:1,109444:135662:1,109445:135663:1,109446:135664:1,109447:135665:1,109448:135659:1,109449:135667:1,109450:136810:1,109451:135669:1,109452:135670:1,109453:135671:1,109454:135672:1,109455:135673:1,110011:136501:1,110425:137043:1',
'https://github.com/simulationcraft/simc/tree/midnight/profiles/MID1');
-- Future work
-- -----------
-- M+ for DPS specs (16 specs × M+) — needs fresh decode of method.gg /
-- wowhead M+ talent strings. Most diverge from raid in cleave/AoE rows.
-- M+ for healers (6 specs × M+) — needs fresh decode; healer M+ vs raid
-- diverges on dispel/utility nodes.
-- PvP (39 specs × PvP) — separate db2 system; this table can encode the
-- PvE talents you'd take for arenas/BGs but cannot encode honor talents.
-- Defer until a curated source publishes per-spec PvE-only PvP loadouts.
-- Leveling (39 specs × Leveling) — DO NOT seed; TraitMgr starter is
-- objectively correct for sub-cap chars and the API loader already
-- falls back to it when no curated row exists.
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (8, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
+78
View File
@@ -0,0 +1,78 @@
-- Migration: 0009_world_metadata
-- Date: 2026-05-22
-- Purpose: Persist GM-curated world-knowledge points (road centerlines,
-- city/village footprints, crossroads, danger zones, hubs)
-- so bots have authoritative situational data independent of
-- texture-classifier heuristics. Two consumers:
-- 1. mmaps_generator reads `kind='road'` rows at regen time
-- and tags polygons within `radius` as NAV_AREA_ROAD.
-- Solves the Teldrassil road-tagging gap (kalidar
-- tileset's road textures don't pass the classifier's
-- effectId confidence gate, leaving zero road MCNKs in
-- .road files despite road textures being referenced).
-- 2. BotSnapshotBuilder loads same rows once at startup
-- and bots query `nearest_metadata(kind)` for awareness
-- — "am I in a city?", "is the nearest crossroad N
-- yards away?", etc.
-- Reverts: yes (DROP TABLE).
--
-- Population mechanism: in-game GM types `.playerbot meta add road [r]`
-- standing on the spot to capture; the command writes a row keyed by
-- the GM's current position and zone. List/edit/delete subcommands
-- provided. No client-side editor — the in-game capture flow IS the
-- editor.
--
-- Schema versioning: kinds enumerated as a small uint8 set rather than
-- VARCHAR so the on-disk column is fixed-width and the C++ side can
-- compare against an enum without string match. Names below match
-- WorldMetadataKind in code:
-- 0=unknown (defensive default)
-- 1=road (road centerline waypoint; mmaps_generator consumes)
-- 2=crossroad (intersection — used by route planner hints)
-- 3=city (capital / major settlement footprint)
-- 4=village (minor settlement footprint)
-- 5=hub (quest hub / outpost)
-- 6=danger (avoid-this-area, e.g. elite spawn zone)
-- 7=vendor (general vendor anchor — bot navigation hint)
-- 8=mailbox (mailbox anchor)
-- 9=innkeeper (innkeeper anchor, e.g. hearth-rebind target)
-- 10=other (operator-defined; check label/notes for context)
--
-- `radius` (yards) is mandatory for area-kinds (city/village/hub/
-- danger). For point-kinds (road waypoint, crossroad, vendor, mailbox,
-- innkeeper) radius is the "effective range" — e.g. road waypoint with
-- radius=15 means polygons within 15y of the point get NAV_AREA_ROAD
-- tagged. Default radii are picked by the GM command, not the schema.
--
-- `zone_id` (Area.db2 ID) is denormalized for fast filter; we DO NOT
-- enforce FK because the area table lives in client data we don't
-- mirror.
--
-- Indexes: (map_id, kind) for the most common query (load all roads
-- for map X), plus (map_id, x, y) for nearest-point lookups via the
-- bot snapshot.
CREATE TABLE IF NOT EXISTS playerbot_v2_world_metadata (
id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
map_id INT UNSIGNED NOT NULL,
zone_id INT UNSIGNED NOT NULL DEFAULT 0,
kind TINYINT UNSIGNED NOT NULL,
pos_x FLOAT NOT NULL,
pos_y FLOAT NOT NULL,
pos_z FLOAT NOT NULL,
radius FLOAT NOT NULL DEFAULT 10.0,
label VARCHAR(96) NOT NULL DEFAULT '',
notes VARCHAR(255) NOT NULL DEFAULT '',
created_by VARCHAR(64) NOT NULL DEFAULT '',
created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP
ON UPDATE CURRENT_TIMESTAMP,
KEY idx_map_kind (map_id, kind),
KEY idx_map_xy (map_id, pos_x, pos_y),
KEY idx_zone (zone_id),
KEY idx_kind (kind)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(9, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+44
View File
@@ -0,0 +1,44 @@
-- Migration: 0010_leveling_zone
-- Date: 2026-06-03
-- Purpose: Persistent per-bot leveling-zone target for R7 cross-map hub
-- relocation. When a bot exhausts its current zone's quests, it
-- picks the best level-appropriate hub from QuestHubDatabase::
-- GetQuestHubsForBot (ContentTuning DB2 bracket matrix) and STORES
-- the choice here so it is STICKY: on server restart the bot reads
-- this target and resumes traveling toward it instead of re-picking
-- (which, being distance-ranked, would flip-flop / relocate every
-- restart). The choice is re-evaluated only with HYSTERESIS — when
-- the bot's level moves OUTSIDE [bracket_lo, bracket_hi], the stored
-- hub no longer fits and a fresh pick + store happens. 0 hub = unset
-- (bot has never needed relocation, or is mid-pick).
-- Reverts: yes (DROP COLUMN per added column).
ALTER TABLE playerbot_v2_character
ADD COLUMN leveling_target_hub INT UNSIGNED NOT NULL DEFAULT 0,
ADD COLUMN leveling_target_map SMALLINT UNSIGNED NOT NULL DEFAULT 0,
ADD COLUMN leveling_bracket_lo TINYINT UNSIGNED NOT NULL DEFAULT 0,
ADD COLUMN leveling_bracket_hi TINYINT UNSIGNED NOT NULL DEFAULT 0,
ADD COLUMN leveling_chosen_at TIMESTAMP NULL DEFAULT NULL,
ADD KEY idx_leveling_target_hub (leveling_target_hub);
-- Column docs (kept below the ALTER so the migration body stays a single
-- statement, per the 0005 convention — the migration parser chokes on
-- comment-embedded semicolons inside the statement):
-- leveling_target_hub QuestHub.hubId the bot is relocating toward (the
-- sticky leveling-zone choice). 0 = unset.
-- leveling_target_map Map id of that hub. Drives the UnifiedTravelGraph
-- cross-map route (walk/fly/ship — never teleport).
-- NOTE map 0 (Eastern Kingdoms) is a REAL map, so
-- this field is only meaningful when target_hub != 0.
-- leveling_bracket_lo Inclusive min level of the chosen hub's
-- leveling_bracket_hi ContentTuning bracket. Hysteresis gate: re-pick a
-- new hub only when bot.level < lo OR > hi, so a bot
-- that out-levels its zone moves on, but small level
-- gains inside the bracket do NOT churn the choice.
-- leveling_chosen_at When the current target was chosen. Diagnostics +
-- a safety re-pick if a target somehow goes stale
-- (e.g. the hub became unreachable).
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (10, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
+56
View File
@@ -0,0 +1,56 @@
-- Migration: 0011_fleet_vitals
-- Date: 2026-06-14
-- Purpose: Persist the fleet-vitals rolling window (#1C of
-- docs/LIVING_SERVER_PLAN_20260614.md) so telemetry survives a
-- worldserver restart and the operator gets a REAL trend / incident
-- replay instead of an in-memory window that resets to zero on every
-- bounce. A 60s job in PlayerbotV2.cpp computes one sample bucket
-- (the same VitalsBucket pushed into PerfCounters' in-memory ring)
-- and writes one row here.
--
-- Columns mirror PerfCounters::VitalsBucket plus the per-category
-- wedge breakdown (cheap to store, makes the persisted history
-- self-describing for a later trend dashboard). Counts are the
-- instantaneous fleet census at sample time; the *_per_* columns are
-- rates derived over the 60s window from cumulative-counter deltas.
--
-- Reverts: yes (DROP TABLE).
--
-- Retention: the writer does NOT prune — a row/min is ~525K rows/yr, trivial
-- for InnoDB, and operators want the long-tail history for incident
-- forensics. If retention is ever needed it's a single scheduled
-- DELETE on sample_at; intentionally left to operator policy.
--
-- Indexing: PRIMARY KEY on the auto-increment id; a secondary KEY on
-- sample_at for the common "last 1h / last 24h" range scan the trend
-- reader issues.
CREATE TABLE IF NOT EXISTS playerbot_v2_fleet_vitals_sample (
id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
sample_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
in_world INT UNSIGNED NOT NULL DEFAULT 0,
alive INT UNSIGNED NOT NULL DEFAULT 0,
in_combat INT UNSIGNED NOT NULL DEFAULT 0,
wedged INT UNSIGNED NOT NULL DEFAULT 0,
-- Per-category active wedge counts (WedgeCategory enum order; None at
-- index 0 is normally 0). Stored as discrete columns so a SQL trend query
-- can GROUP/aggregate a single category without parsing a blob.
wedged_navmesh INT UNSIGNED NOT NULL DEFAULT 0,
wedged_offmesh INT UNSIGNED NOT NULL DEFAULT 0,
wedged_travel INT UNSIGNED NOT NULL DEFAULT 0,
wedged_combatloop INT UNSIGNED NOT NULL DEFAULT 0,
wedged_pickernone INT UNSIGNED NOT NULL DEFAULT 0,
wedged_goalunreach INT UNSIGNED NOT NULL DEFAULT 0,
tick_p50_us INT UNSIGNED NOT NULL DEFAULT 0,
tick_p99_us INT UNSIGNED NOT NULL DEFAULT 0,
intents_per_sec INT UNSIGNED NOT NULL DEFAULT 0,
intents_dropped INT UNSIGNED NOT NULL DEFAULT 0,
path_fail_per_min INT UNSIGNED NOT NULL DEFAULT 0,
avg_level FLOAT NOT NULL DEFAULT 0,
KEY idx_sample_at (sample_at)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(11, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+40
View File
@@ -0,0 +1,40 @@
-- Migration: 0012_archetype
-- Date: 2026-06-14
-- Purpose: Per-bot ARCHETYPE foundation (#4A of
-- docs/LIVING_SERVER_PLAN_20260614.md). Personality (HOW a bot
-- plays) already exists; this adds Archetype (WHAT it does + WHEN it
-- is online) so the fleet is heterogeneous — casual-solo, hardcore-
-- raider, social-guildie, gatherer/AH-flipper, PvPer, altoholic-
-- explorer — the basis of a believable living server and of economy /
-- role variety.
--
-- Columns:
-- archetype_id The curated archetype id (index into
-- BotArchetype.cpp's kArchetypeTable ==
-- ArchetypeId enum). 0 = CasualSolo (the
-- default + the value an un-rolled bot
-- reads as). Assigned on first spawn via
-- RollArchetype(SeedForBot(id)) and
-- written back; deterministic per bot so
-- it is stable across restarts.
-- session_start_at When the bot's CURRENT play session
-- began. NULL when logged out. Reserved
-- for the session-rhythm logout layer
-- (documented followup) — stored now so
-- the data is available when that lands.
-- cumulative_session_minutes Lifetime online minutes accrued by
-- this bot across sessions. Also for the
-- future session-rhythm layer. Not
-- decremented; monotonic.
-- Reverts: yes (DROP COLUMN per added column).
ALTER TABLE playerbot_v2_character
ADD COLUMN archetype_id TINYINT UNSIGNED NOT NULL DEFAULT 0,
ADD COLUMN session_start_at DATETIME NULL DEFAULT NULL,
ADD COLUMN cumulative_session_minutes BIGINT UNSIGNED NOT NULL DEFAULT 0,
ADD KEY idx_archetype_id (archetype_id);
-- Record this migration as applied (mirrors the 0011 record-version pattern).
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(12, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+74
View File
@@ -0,0 +1,74 @@
-- Migration: 0013_craft_orders
-- Date: 2026-06-15
-- Purpose: Bot-to-bot CRAFT-ORDER BOARD + escrow plumbing (#4B-2(a) part 1 of
-- docs/LIVING_SERVER_PLAN_20260614.md). Lets a requester bot post an
-- order for an item it can't make itself (escrowing the payment up
-- front by debiting its gold), a crafter bot that KNOWS the recipe
-- claim + fulfil it, and the escrow release/refund to settle the
-- transaction exactly once. This closes the profession economy loop:
-- gatherers feed reagents into the AH, crafters turn reagents into
-- finished goods on demand, and gold circulates between bots.
--
-- SECURITY (#4B-2 human-firewall): this is a CLOSED bot-to-bot system.
-- requester_low AND crafter_low are re-verified as CURRENT fleet bots
-- (Services::Registry()) at every state transition by CraftOrderBoard.
-- There is NO GM command / whisper / human entry point — a real player
-- can neither post, claim, fulfil, nor extract value from an order.
--
-- Columns:
-- id auto PK; the order id carried by snapshot + intent.
-- requester_low Player guid-low of the bot that posted the order
-- and whose gold was escrowed.
-- crafter_low Player guid-low of the bot that claimed it; NULL
-- while the order is still Open.
-- spell_id The craft recipe spell the order wants fulfilled.
-- item_entry The product item the recipe creates (item_template
-- entry), carried so the board / snapshot can describe
-- the order without re-resolving the spell.
-- quantity How many of the product the requester wants.
-- payment_copper The escrowed payment (copper). Debited from the
-- requester at PostOrder; paid to the crafter at
-- MarkDelivered OR refunded to the requester at
-- Fail/Cancel — EXACTLY ONCE, never both, never
-- neither. The `status` column is the single source
-- of truth that guards which of those two settlements
-- (if any) has already happened.
-- status 0=Open 1=Claimed 2=Delivered 3=Failed 4=Cancelled.
-- created_at When the order was posted (escrow taken).
-- claimed_at When a crafter claimed it; NULL while Open.
--
-- ESCROW INVARIANT (documented here + in CraftOrderBoard.h):
-- payment_copper is removed from the requester's gold EXACTLY ONCE,
-- at the Open transition (PostOrder). It then has exactly one of two
-- terminal fates:
-- * Delivered -> paid to the crafter (MarkDelivered), or
-- * Failed/Cancelled -> refunded to the requester (FailOrder).
-- A row may be settled only while transitioning OUT of a non-terminal
-- status (Open/Claimed) INTO a terminal one. Terminal rows
-- (Delivered/Failed/Cancelled) are never re-settled, so the gold can
-- never be double-released or double-refunded.
--
-- Reverts: yes (DROP TABLE).
--
-- Retention: finished rows (Delivered/Failed/Cancelled) are pruned by
-- CraftOrderBoard::Tick after a grace window; Open/Claimed rows are
-- reconciled into memory on load.
CREATE TABLE IF NOT EXISTS bot_craft_orders (
id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
requester_low BIGINT UNSIGNED NOT NULL,
crafter_low BIGINT UNSIGNED NULL DEFAULT NULL,
spell_id INT UNSIGNED NOT NULL DEFAULT 0,
item_entry INT UNSIGNED NOT NULL DEFAULT 0,
quantity INT UNSIGNED NOT NULL DEFAULT 1,
payment_copper BIGINT UNSIGNED NOT NULL DEFAULT 0,
status TINYINT UNSIGNED NOT NULL DEFAULT 0,
created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
claimed_at DATETIME NULL DEFAULT NULL,
KEY idx_status (status)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
-- Record this migration as applied (mirrors the 0011/0012 record-version pattern).
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(13, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+68
View File
@@ -0,0 +1,68 @@
-- Migration: 0014_stuck_objective
-- Date: 2026-06-16
-- Purpose: Persistent, fleet-aggregated STUCK-OBJECTIVE LEDGER (#7 follow-up).
-- The WedgeWatchdog self-remediation layer abandons a bot's current
-- objective when it has been wedged (GoalUnreachable / CombatLoop) past
-- RemediationMs. That abandon is a 5-minute in-memory blacklist (the
-- bot RETRIES automatically once it expires) and, until now, the only
-- record of WHICH content stranded bots was the ephemeral
-- [wedge_remediate] log line (Playerbot.log is truncated every boot).
--
-- This table turns the fleet into a self-documenting content-QA system:
-- every remediation upserts a row keyed by (quest_id, obj_id), so an
-- operator can later run e.g.
-- SELECT quest_id, obj_id, category, hit_count, sample_map,
-- sample_zone, sample_x, sample_y, sample_bot, last_seen
-- FROM playerbot_v2_stuck_objective ORDER BY hit_count DESC LIMIT 50;
-- to find the quests/objectives that strand the most bots and root-cause
-- them (navmesh gap, off-mesh bridge, bad POI data, friendly-only kill
-- target, permanent blacklist, ...). It is the durable, queryable
-- successor to the manual log-forensics + character_queststatus queries
-- used in the 2026-06-15 cross-region investigation (4494 / 876 / 55660).
--
-- Columns:
-- quest_id / obj_id The stranded objective (obj_id 0 = quest-level /
-- no specific sub-objective). Composite PK so each
-- distinct objective is one accumulating row.
-- category Last WedgeCategory that remediated it
-- (GoalUnreachable / CombatLoop).
-- hit_count Cumulative remediation events across the whole
-- fleet AND across restarts (the writer flushes a
-- per-interval delta via hit_count = hit_count +
-- VALUES(hit_count)). A high count = chronically
-- stuck content worth investigating.
-- first_seen When this objective first stranded a bot (set on
-- insert, never overwritten).
-- last_seen Most recent remediation (updated every flush). A
-- stale last_seen ~ the issue resolved itself.
-- sample_* A representative stuck location + bot for the
-- objective, so an investigator can fly there /
-- reproduce without grepping logs.
--
-- Reverts: yes (DROP TABLE).
--
-- Retention: the writer does NOT prune — rows are small, bounded by the number
-- of DISTINCT stuck objectives (hundreds–low thousands), and the long
-- history is the point. Operators may DELETE on last_seen if desired.
CREATE TABLE IF NOT EXISTS playerbot_v2_stuck_objective (
quest_id INT UNSIGNED NOT NULL,
obj_id INT UNSIGNED NOT NULL DEFAULT 0,
category VARCHAR(24) NOT NULL DEFAULT '',
hit_count BIGINT UNSIGNED NOT NULL DEFAULT 0,
first_seen DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
last_seen DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
sample_map INT UNSIGNED NOT NULL DEFAULT 0,
sample_zone INT UNSIGNED NOT NULL DEFAULT 0,
sample_x FLOAT NOT NULL DEFAULT 0,
sample_y FLOAT NOT NULL DEFAULT 0,
sample_bot VARCHAR(48) NOT NULL DEFAULT '',
PRIMARY KEY (quest_id, obj_id),
KEY idx_hit_count (hit_count),
KEY idx_last_seen (last_seen)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
-- Record this migration as applied (mirrors the 0011/0012/0013 pattern).
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(14, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,130 @@
-- Migration: 0016_talent_builds_12_1
-- Purpose: Curated talent builds for WoW 12.1.0.69587 (Midnight 12.1), decoded from
-- simc/midnight MID2 raid profiles (+ hand-curated healer/Augmentation
-- import strings) via Bot/Talent/data/gen_talent_seed.py.
-- Rows are REPLACE INTO for context 0 (Default) and 1 (Raid) so re-running
-- overwrites the previous build's rows for (class, spec, context).
-- Trait build: 12.1.0.69587. entries_json = nodeID:entryID:ranks triples referencing this
-- client build's TraitNode/TraitNodeEntry ids.
-- Reverts: yes (DELETE rows; re-run to repopulate).
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 71, 0, 'Default: simc/midnight MID2_Warrior_Arms', '90269:112121:1,90270:112122:1,90271:112123:1,90273:112125:1,90274:112126:1,90276:112128:1,90277:112129:1,90279:112131:1,90282:112134:1,90283:112135:2,90290:112144:1,90291:112145:1,90292:112146:1,90293:112147:1,90322:112179:2,90326:112183:1,90327:112184:1,90328:112185:1,90331:112188:1,90337:112198:1,90344:112206:1,90346:112208:1,90347:112209:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90438:112310:1,90439:112311:1,90441:112314:1,90444:112317:2,90445:112318:1,90447:112320:2,92537:114643:1,94784:117381:1,94786:117383:1,94787:117384:1,94788:117385:1,94795:117392:1,94801:117398:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94818:117415:1,94820:117417:1,95956:118850:1,99853:123390:1,108542:134031:1,108543:134032:1,108544:134033:1,108676:134216:1,108685:134225:1,108705:136627:1,109391:135597:1,109683:135939:1,109684:135940:1,109685:135941:1,109686:135943:1,109687:135944:2,109815:136074:1,109816:136075:1,109817:136076:1,110119:136626:1,110176:136703:1,110407:136989:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 71, 1, 'simc/midnight MID2_Warrior_Arms', '90269:112121:1,90270:112122:1,90271:112123:1,90273:112125:1,90274:112126:1,90276:112128:1,90277:112129:1,90279:112131:1,90282:112134:1,90283:112135:2,90290:112144:1,90291:112145:1,90292:112146:1,90293:112147:1,90322:112179:2,90326:112183:1,90327:112184:1,90328:112185:1,90331:112188:1,90337:112198:1,90344:112206:1,90346:112208:1,90347:112209:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90438:112310:1,90439:112311:1,90441:112314:1,90444:112317:2,90445:112318:1,90447:112320:2,92537:114643:1,94784:117381:1,94786:117383:1,94787:117384:1,94788:117385:1,94795:117392:1,94801:117398:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94818:117415:1,94820:117417:1,95956:118850:1,99853:123390:1,108542:134031:1,108543:134032:1,108544:134033:1,108676:134216:1,108685:134225:1,108705:136627:1,109391:135597:1,109683:135939:1,109684:135940:1,109685:135941:1,109686:135943:1,109687:135944:2,109815:136074:1,109816:136075:1,109817:136076:1,110119:136626:1,110176:136703:1,110407:136989:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 72, 0, 'Default: simc/midnight MID2_Warrior_Fury', '90325:112182:1,90326:112183:1,90328:112185:1,90331:112188:1,90332:112190:1,90337:112198:1,90344:112206:1,90346:112208:1,90347:112209:1,90348:112210:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90373:112240:2,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90387:112255:1,90388:119139:1,90390:112259:1,90392:112261:1,90394:112263:1,90395:112264:1,90396:112265:1,90397:112266:2,90398:112267:1,90399:112268:1,90401:112270:1,90402:112271:1,90403:112272:1,90406:112275:1,90407:112276:1,90408:112277:1,90410:112279:1,90412:112281:1,90415:112284:1,90425:112296:2,90428:112299:2,90429:112300:1,90430:112301:1,92538:114644:1,94784:117381:1,94786:117383:1,94787:123770:1,94788:117385:1,94795:117392:1,94801:117398:1,94803:117400:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94820:117417:1,95956:118850:1,99852:123389:1,108542:134031:1,108543:134032:1,108544:134033:1,108685:134225:1,108705:136627:1,109815:136074:1,109816:136075:1,109817:136076:1,109964:136449:1,109966:136451:1,109968:136453:1,110119:136626:1,110203:136735:1,110412:137004:1,110654:137472:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 72, 1, 'simc/midnight MID2_Warrior_Fury', '90325:112182:1,90326:112183:1,90328:112185:1,90331:112188:1,90332:112190:1,90337:112198:1,90344:112206:1,90346:112208:1,90347:112209:1,90348:112210:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90373:112240:2,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90387:112255:1,90388:119139:1,90390:112259:1,90392:112261:1,90394:112263:1,90395:112264:1,90396:112265:1,90397:112266:2,90398:112267:1,90399:112268:1,90401:112270:1,90402:112271:1,90403:112272:1,90406:112275:1,90407:112276:1,90408:112277:1,90410:112279:1,90412:112281:1,90415:112284:1,90425:112296:2,90428:112299:2,90429:112300:1,90430:112301:1,92538:114644:1,94784:117381:1,94786:117383:1,94787:123770:1,94788:117385:1,94795:117392:1,94801:117398:1,94803:117400:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94820:117417:1,95956:118850:1,99852:123389:1,108542:134031:1,108543:134032:1,108544:134033:1,108685:134225:1,108705:136627:1,109815:136074:1,109816:136075:1,109817:136076:1,109964:136449:1,109966:136451:1,109968:136453:1,110119:136626:1,110203:136735:1,110412:137004:1,110654:137472:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 73, 0, 'Default: simc/midnight MID2_Warrior_Protection', '90261:112112:1,90264:132884:1,90265:112116:1,90295:112149:1,90296:112150:1,90297:112151:1,90298:112152:1,90301:112155:1,90302:112156:1,90303:112157:1,90304:112158:1,90305:112159:1,90306:112160:1,90308:112162:1,90309:112163:1,90310:112165:1,90311:112166:2,90312:132885:1,90314:112170:1,90317:112173:1,90318:112174:1,90319:112176:1,90320:112177:1,90324:112181:2,90326:112183:1,90328:112185:1,90329:112186:1,90330:112187:1,90331:112188:1,90343:112205:1,90346:112208:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90432:112304:1,90433:112305:1,90448:112321:1,90449:112323:1,90451:112325:1,94789:117386:1,94793:117390:1,94794:117391:1,94796:117393:1,94799:119856:1,94806:117403:1,94811:117408:1,94812:117409:1,94815:117412:1,94818:117415:1,94819:117416:1,95956:118850:1,95959:118853:1,99851:123391:1,107577:132882:1,107578:132883:1,108542:134031:1,108543:134032:1,108544:134033:1,108686:134226:1,108705:136627:1,109812:136071:1,109813:136072:1,109814:136073:1,110118:136625:1,110119:136626:1,110411:137001:1,110653:137471:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 73, 1, 'simc/midnight MID2_Warrior_Protection', '90261:112112:1,90264:132884:1,90265:112116:1,90295:112149:1,90296:112150:1,90297:112151:1,90298:112152:1,90301:112155:1,90302:112156:1,90303:112157:1,90304:112158:1,90305:112159:1,90306:112160:1,90308:112162:1,90309:112163:1,90310:112165:1,90311:112166:2,90312:132885:1,90314:112170:1,90317:112173:1,90318:112174:1,90319:112176:1,90320:112177:1,90324:112181:2,90326:112183:1,90328:112185:1,90329:112186:1,90330:112187:1,90331:112188:1,90343:112205:1,90346:112208:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90432:112304:1,90433:112305:1,90448:112321:1,90449:112323:1,90451:112325:1,94789:117386:1,94793:117390:1,94794:117391:1,94796:117393:1,94799:119856:1,94806:117403:1,94811:117408:1,94812:117409:1,94815:117412:1,94818:117415:1,94819:117416:1,95956:118850:1,95959:118853:1,99851:123391:1,107577:132882:1,107578:132883:1,108542:134031:1,108543:134032:1,108544:134033:1,108686:134226:1,108705:136627:1,109812:136071:1,109813:136072:1,109814:136073:1,110118:136625:1,110119:136626:1,110411:137001:1,110653:137471:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 65, 0, 'Default: method.gg Raid Build - Beacon of Virtue (Recommended)', '81496:102465:1,81508:102477:1,81510:133481:1,81554:102532:1,81555:102534:1,81556:102535:1,81557:102536:1,81558:102537:1,81560:102539:1,81561:102540:1,81564:102544:1,81565:102545:1,81567:102548:1,81568:102549:1,81569:102550:1,81571:102553:1,81574:102557:1,81576:102559:1,81578:102562:1,81579:102563:1,81580:102564:1,81584:102569:1,81585:102570:1,81590:102575:1,81591:102577:1,81592:102578:1,81594:102580:1,81595:102581:1,81597:102583:1,81598:102584:1,81600:102587:1,81605:102592:1,81609:102597:1,81613:102601:1,81614:102602:1,81615:102603:1,81616:102604:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92220:114292:1,93009:115034:2,93180:115465:1,93191:128246:1,93520:115872:1,93521:115873:1,93522:115874:1,93927:116376:1,95069:117666:1,95071:117668:1,95072:117669:1,95073:117778:1,95080:117677:1,95086:117683:1,95094:117691:1,95095:117692:1,95098:117777:1,95099:117696:1,95105:117702:1,99839:123362:1,103851:128241:2,103856:128309:1,103858:128254:2,103861:128257:1,103863:128259:1,103864:128260:1,103866:128262:1,108034:133407:1,108099:133479:1,109748:136006:1,109749:136007:1,109750:136008:1,109998:136486:1,109999:136487:1,110012:136503:1,110092:136593:1,110257:136795:1,110417:137019:1', 'https://www.method.gg/guides/holy-paladin/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 65, 1, 'method.gg Raid Build - Beacon of Virtue (Recommended)', '81496:102465:1,81508:102477:1,81510:133481:1,81554:102532:1,81555:102534:1,81556:102535:1,81557:102536:1,81558:102537:1,81560:102539:1,81561:102540:1,81564:102544:1,81565:102545:1,81567:102548:1,81568:102549:1,81569:102550:1,81571:102553:1,81574:102557:1,81576:102559:1,81578:102562:1,81579:102563:1,81580:102564:1,81584:102569:1,81585:102570:1,81590:102575:1,81591:102577:1,81592:102578:1,81594:102580:1,81595:102581:1,81597:102583:1,81598:102584:1,81600:102587:1,81605:102592:1,81609:102597:1,81613:102601:1,81614:102602:1,81615:102603:1,81616:102604:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92220:114292:1,93009:115034:2,93180:115465:1,93191:128246:1,93520:115872:1,93521:115873:1,93522:115874:1,93927:116376:1,95069:117666:1,95071:117668:1,95072:117669:1,95073:117778:1,95080:117677:1,95086:117683:1,95094:117691:1,95095:117692:1,95098:117777:1,95099:117696:1,95105:117702:1,99839:123362:1,103851:128241:2,103856:128309:1,103858:128254:2,103861:128257:1,103863:128259:1,103864:128260:1,103866:128262:1,108034:133407:1,108099:133479:1,109748:136006:1,109749:136007:1,109750:136008:1,109998:136486:1,109999:136487:1,110012:136503:1,110092:136593:1,110257:136795:1,110417:137019:1', 'https://www.method.gg/guides/holy-paladin/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 66, 0, 'Default: simc/midnight MID2_Paladin_Protection', '81469:102430:1,81470:102432:1,81471:102433:2,81474:102437:2,81477:102440:1,81479:102443:1,81481:102445:1,81482:102446:2,81483:102448:1,81485:102450:2,81486:102452:1,81487:102453:1,81489:102455:1,81490:102456:1,81491:102457:1,81493:102461:1,81494:102463:1,81495:102464:1,81501:102470:1,81502:102471:1,81503:102472:1,81506:102475:1,81510:133481:1,81543:102518:1,81597:102583:1,81600:102587:1,81603:102590:1,81604:102591:1,81605:102592:1,81609:102597:1,81612:102600:1,81614:102602:1,81615:102603:1,81616:102604:1,81617:102606:1,81621:102612:2,81628:102620:1,81630:102622:2,81631:128251:1,81632:102625:1,90062:137855:1,93009:115034:2,93165:115444:1,93168:115447:1,93187:115479:1,93188:115480:1,93192:128244:1,93357:115673:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117820:1,95186:117822:1,95187:117823:1,95234:117882:1,99838:123358:1,101927:102451:1,101928:137856:1,103851:128241:2,103860:128256:1,103863:128259:1,103864:128260:1,103867:128263:1,103877:128278:1,109745:136184:1,109746:136004:1,109747:136005:1,109999:136487:1,110006:136496:1,110418:137022:1,110862:137857:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 66, 1, 'simc/midnight MID2_Paladin_Protection', '81469:102430:1,81470:102432:1,81471:102433:2,81474:102437:2,81477:102440:1,81479:102443:1,81481:102445:1,81482:102446:2,81483:102448:1,81485:102450:2,81486:102452:1,81487:102453:1,81489:102455:1,81490:102456:1,81491:102457:1,81493:102461:1,81494:102463:1,81495:102464:1,81501:102470:1,81502:102471:1,81503:102472:1,81506:102475:1,81510:133481:1,81543:102518:1,81597:102583:1,81600:102587:1,81603:102590:1,81604:102591:1,81605:102592:1,81609:102597:1,81612:102600:1,81614:102602:1,81615:102603:1,81616:102604:1,81617:102606:1,81621:102612:2,81628:102620:1,81630:102622:2,81631:128251:1,81632:102625:1,90062:137855:1,93009:115034:2,93165:115444:1,93168:115447:1,93187:115479:1,93188:115480:1,93192:128244:1,93357:115673:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117820:1,95186:117822:1,95187:117823:1,95234:117882:1,99838:123358:1,101927:102451:1,101928:137856:1,103851:128241:2,103860:128256:1,103863:128259:1,103864:128260:1,103867:128263:1,103877:128278:1,109745:136184:1,109746:136004:1,109747:136005:1,109999:136487:1,110006:136496:1,110418:137022:1,110862:137857:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 70, 0, 'Default: simc/midnight MID2_Paladin_Retribution_Herald', '81510:133481:1,81512:115475:1,81521:114828:1,81523:102493:1,81525:102497:1,81526:102498:1,81527:102499:1,81532:102504:1,81533:102505:1,81534:102506:1,81542:102516:1,81543:102518:1,81544:102519:1,81597:102583:1,81600:102587:1,81603:102590:1,81605:102592:1,81608:102596:1,81609:102597:1,81614:102602:1,81615:102603:1,81616:102604:1,81618:128243:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92686:114824:1,92689:114830:1,92838:115022:1,92839:115024:1,92854:115043:1,92952:115165:2,93009:115034:2,93160:115439:2,93164:115443:2,93173:115453:1,93174:115454:1,93181:115468:1,93189:115481:1,93190:115483:2,93357:115673:1,95069:117666:1,95071:117668:1,95072:117669:1,95073:117778:1,95080:117677:1,95086:117683:1,95094:117691:1,95095:117692:1,95098:117777:1,95099:117696:1,95105:117702:1,95180:117813:1,99837:123360:1,103851:128241:2,103861:128257:1,103863:128259:1,103864:128260:1,103867:128263:1,103868:128264:1,109368:135564:1,109369:135565:1,109371:115438:1,109372:115452:1,109373:115435:1,109374:136809:1,109748:136006:1,109749:136007:1,109750:136008:1,109867:136127:1,109999:136487:1,110012:136503:1,110091:136592:1,110093:136594:1,110419:137025:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 70, 1, 'simc/midnight MID2_Paladin_Retribution_Herald', '81510:133481:1,81512:115475:1,81521:114828:1,81523:102493:1,81525:102497:1,81526:102498:1,81527:102499:1,81532:102504:1,81533:102505:1,81534:102506:1,81542:102516:1,81543:102518:1,81544:102519:1,81597:102583:1,81600:102587:1,81603:102590:1,81605:102592:1,81608:102596:1,81609:102597:1,81614:102602:1,81615:102603:1,81616:102604:1,81618:128243:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92686:114824:1,92689:114830:1,92838:115022:1,92839:115024:1,92854:115043:1,92952:115165:2,93009:115034:2,93160:115439:2,93164:115443:2,93173:115453:1,93174:115454:1,93181:115468:1,93189:115481:1,93190:115483:2,93357:115673:1,95069:117666:1,95071:117668:1,95072:117669:1,95073:117778:1,95080:117677:1,95086:117683:1,95094:117691:1,95095:117692:1,95098:117777:1,95099:117696:1,95105:117702:1,95180:117813:1,99837:123360:1,103851:128241:2,103861:128257:1,103863:128259:1,103864:128260:1,103867:128263:1,103868:128264:1,109368:135564:1,109369:135565:1,109371:115438:1,109372:115452:1,109373:115435:1,109374:136809:1,109748:136006:1,109749:136007:1,109750:136008:1,109867:136127:1,109999:136487:1,110012:136503:1,110091:136592:1,110093:136594:1,110419:137025:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 253, 0, 'Default: simc/midnight MID2_Hunter_Beast_Mastery', '94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94979:117576:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99832:123347:1,102292:126352:1,102336:126397:2,102340:126402:1,102342:126404:1,102343:126405:1,102344:126406:1,102345:126407:2,102346:126408:1,102347:126409:1,102353:126415:1,102354:126416:1,102356:126418:1,102357:126419:1,102358:126420:1,102360:126422:1,102362:126424:1,102365:126427:1,102367:126430:2,102368:126431:1,102370:126433:1,102372:126435:1,102373:126436:1,102374:126437:1,102377:126440:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102393:126457:1,102395:126459:1,102396:126460:2,102397:126461:1,102401:126465:2,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,107285:132188:1,107286:132189:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109802:136060:1,109803:136061:1,109804:136236:1,109961:136446:1,110152:136670:1,110157:136677:1,110158:136679:1,110164:136685:1,110428:137052:1,110692:126400:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 253, 1, 'simc/midnight MID2_Hunter_Beast_Mastery', '94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94979:117576:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99832:123347:1,102292:126352:1,102336:126397:2,102340:126402:1,102342:126404:1,102343:126405:1,102344:126406:1,102345:126407:2,102346:126408:1,102347:126409:1,102353:126415:1,102354:126416:1,102356:126418:1,102357:126419:1,102358:126420:1,102360:126422:1,102362:126424:1,102365:126427:1,102367:126430:2,102368:126431:1,102370:126433:1,102372:126435:1,102373:126436:1,102374:126437:1,102377:126440:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102393:126457:1,102395:126459:1,102396:126460:2,102397:126461:1,102401:126465:2,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,107285:132188:1,107286:132189:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109802:136060:1,109803:136061:1,109804:136236:1,109961:136446:1,110152:136670:1,110157:136677:1,110158:136679:1,110164:136685:1,110428:137052:1,110692:126400:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 254, 0, 'Default: simc/midnight MID2_Hunter_Marksmanship', '94958:117555:1,94965:117562:1,94970:117567:1,94971:117568:1,94973:117570:1,94976:117573:1,94978:117575:1,94980:117577:1,94981:117578:1,94987:117584:1,94989:117586:1,94990:117587:1,99831:123345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102393:126457:1,102395:126459:1,102396:126460:2,102401:126465:2,102402:126466:1,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103947:128367:1,103956:128376:1,103958:132194:1,103959:128380:1,103960:128381:1,103961:128383:1,103962:128384:1,103964:128386:1,103966:128388:1,103974:128396:1,103975:128397:1,103977:128399:1,103978:128400:2,103979:128401:1,103982:128404:1,103984:128406:1,103985:128407:1,103986:128408:1,103990:128413:1,104095:128609:1,104127:128710:1,104130:128717:1,107289:132193:1,107290:132195:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109490:135713:1,109805:136063:1,109807:136065:1,110028:136521:1,110152:136670:1,110157:136677:1,110164:136685:1,110430:137058:1,110572:137375:1,110573:137635:1,110574:137377:1,110575:137378:1,110691:137506:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 254, 1, 'simc/midnight MID2_Hunter_Marksmanship', '94958:117555:1,94965:117562:1,94970:117567:1,94971:117568:1,94973:117570:1,94976:117573:1,94978:117575:1,94980:117577:1,94981:117578:1,94987:117584:1,94989:117586:1,94990:117587:1,99831:123345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102393:126457:1,102395:126459:1,102396:126460:2,102401:126465:2,102402:126466:1,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103947:128367:1,103956:128376:1,103958:132194:1,103959:128380:1,103960:128381:1,103961:128383:1,103962:128384:1,103964:128386:1,103966:128388:1,103974:128396:1,103975:128397:1,103977:128399:1,103978:128400:2,103979:128401:1,103982:128404:1,103984:128406:1,103985:128407:1,103986:128408:1,103990:128413:1,104095:128609:1,104127:128710:1,104130:128717:1,107289:132193:1,107290:132195:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109490:135713:1,109805:136063:1,109807:136065:1,110028:136521:1,110152:136670:1,110157:136677:1,110164:136685:1,110430:137058:1,110572:137375:1,110573:137635:1,110574:137377:1,110575:137378:1,110691:137506:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 255, 0, 'Default: simc/midnight MID2_Hunter_Survival', '79837:100543:1,94958:117555:1,94965:117562:1,94970:117567:1,94971:117568:1,94973:117570:1,94976:117573:1,94978:117575:1,94980:117577:1,94981:117578:1,94989:117586:1,94990:117587:1,94991:117588:1,99833:123349:1,102252:126311:1,102255:126314:1,102262:126322:1,102263:126323:1,102264:126324:1,102268:126328:1,102272:126332:1,102281:126341:2,102282:126342:1,102285:126345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102393:126457:1,102395:126459:1,102396:126460:2,102401:126465:2,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103989:128412:1,109304:135495:2,109305:135496:1,109307:135498:1,109309:135500:1,109310:135501:1,109311:135502:1,109312:135503:2,109313:135504:2,109316:135507:1,109319:135510:1,109321:135512:1,109323:135514:1,109324:135515:1,109470:135689:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109805:136063:1,109807:136065:1,110028:136522:1,110152:136670:1,110157:136677:1,110159:136680:1,110162:136683:1,110164:136685:1,110429:137055:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 255, 1, 'simc/midnight MID2_Hunter_Survival', '79837:100543:1,94958:117555:1,94965:117562:1,94970:117567:1,94971:117568:1,94973:117570:1,94976:117573:1,94978:117575:1,94980:117577:1,94981:117578:1,94989:117586:1,94990:117587:1,94991:117588:1,99833:123349:1,102252:126311:1,102255:126314:1,102262:126322:1,102263:126323:1,102264:126324:1,102268:126328:1,102272:126332:1,102281:126341:2,102282:126342:1,102285:126345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102390:126453:1,102391:126454:1,102393:126457:1,102395:126459:1,102396:126460:2,102401:126465:2,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103989:128412:1,109304:135495:2,109305:135496:1,109307:135498:1,109309:135500:1,109310:135501:1,109311:135502:1,109312:135503:2,109313:135504:2,109316:135507:1,109319:135510:1,109321:135512:1,109323:135514:1,109324:135515:1,109470:135689:1,109483:135705:1,109485:135708:1,109486:135709:1,109487:135710:2,109488:135711:1,109805:136063:1,109807:136065:1,110028:136522:1,110152:136670:1,110157:136677:1,110159:136680:1,110162:136683:1,110164:136685:1,110429:137055:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 259, 0, 'Default: simc/midnight MID2_Rogue_Assassination_Deathstalker', '90624:112509:2,90625:112510:1,90626:112511:1,90628:112513:1,90633:112518:1,90634:134840:1,90635:112520:1,90636:112521:1,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90740:112630:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90756:112648:1,90757:112649:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,90766:112659:2,90767:112660:1,90768:112661:1,90769:112662:1,90770:112663:1,90771:112664:1,90772:112665:2,90774:112667:1,90776:112669:1,90777:112670:1,90780:112673:1,90783:112676:1,90785:112678:2,94536:117106:1,94552:117130:1,94553:117131:1,94554:117133:1,94556:117137:1,94562:117145:1,95106:126029:1,95108:117705:1,95109:117706:1,95110:117707:1,95117:117714:1,95123:117720:1,95125:117722:1,95131:117728:1,95132:117729:1,95135:117732:1,95136:117733:1,95142:117739:1,99844:123375:1,101714:125615:1,109760:136018:1,109761:136019:1,109762:136020:1,110323:136881:1,110325:136883:1,110433:137067:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 259, 1, 'simc/midnight MID2_Rogue_Assassination_Deathstalker', '90624:112509:2,90625:112510:1,90626:112511:1,90628:112513:1,90633:112518:1,90634:134840:1,90635:112520:1,90636:112521:1,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90740:112630:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90756:112648:1,90757:112649:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,90766:112659:2,90767:112660:1,90768:112661:1,90769:112662:1,90770:112663:1,90771:112664:1,90772:112665:2,90774:112667:1,90776:112669:1,90777:112670:1,90780:112673:1,90783:112676:1,90785:112678:2,94536:117106:1,94552:117130:1,94553:117131:1,94554:117133:1,94556:117137:1,94562:117145:1,95106:126029:1,95108:117705:1,95109:117706:1,95110:117707:1,95117:117714:1,95123:117720:1,95125:117722:1,95131:117728:1,95132:117729:1,95135:117732:1,95136:117733:1,95142:117739:1,99844:123375:1,101714:125615:1,109760:136018:1,109761:136019:1,109762:136020:1,110323:136881:1,110325:136883:1,110433:137067:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 260, 0, 'Default: simc/midnight MID2_Rogue_Outlaw', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90644:112530:1,90645:112531:1,90647:112533:1,90648:112534:1,90651:112537:1,90652:112538:1,90653:112539:1,90654:112540:1,90655:135732:1,90656:112542:1,90659:112545:1,90661:112547:1,90662:112548:1,90663:112549:1,90664:112551:1,90665:112552:1,90666:112553:2,90668:112555:2,90670:112557:1,90671:112558:1,90678:112566:1,90679:112567:1,90680:112568:1,90681:135734:1,90683:112571:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90741:112631:1,90742:112632:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90750:112642:1,90751:112643:2,90752:112644:1,90753:112645:1,90754:112646:1,90755:112647:1,90756:112648:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,94562:117145:1,94563:117146:1,94565:117148:1,95111:117708:1,95115:117712:1,95116:117713:1,95118:117715:1,95121:117718:1,95125:117722:1,95128:117725:1,95133:117730:1,95134:117731:1,95137:117734:1,95140:117737:1,95141:117738:1,99843:123372:1,101714:125615:1,109763:136021:1,109764:136022:1,109765:136023:1,110323:136881:1,110434:137070:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 260, 1, 'simc/midnight MID2_Rogue_Outlaw', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90644:112530:1,90645:112531:1,90647:112533:1,90648:112534:1,90651:112537:1,90652:112538:1,90653:112539:1,90654:112540:1,90655:135732:1,90656:112542:1,90659:112545:1,90661:112547:1,90662:112548:1,90663:112549:1,90664:112551:1,90665:112552:1,90666:112553:2,90668:112555:2,90670:112557:1,90671:112558:1,90678:112566:1,90679:112567:1,90680:112568:1,90681:135734:1,90683:112571:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90741:112631:1,90742:112632:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90750:112642:1,90751:112643:2,90752:112644:1,90753:112645:1,90754:112646:1,90755:112647:1,90756:112648:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,94562:117145:1,94563:117146:1,94565:117148:1,95111:117708:1,95115:117712:1,95116:117713:1,95118:117715:1,95121:117718:1,95125:117722:1,95128:117725:1,95133:117730:1,95134:117731:1,95137:117734:1,95140:117737:1,95141:117738:1,99843:123372:1,101714:125615:1,109763:136021:1,109764:136022:1,109765:136023:1,110323:136881:1,110434:137070:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 261, 0, 'Default: simc/midnight MID2_Rogue_Subtlety', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90690:112578:1,90692:112580:1,90695:112583:1,90697:112585:1,90700:112588:1,90701:136807:1,90703:117172:1,90704:112592:1,90706:112594:2,90709:112597:1,90710:112598:1,90713:112601:1,90716:112604:1,90719:112607:1,90720:112608:2,90721:112609:1,90722:112610:1,90723:112611:1,90724:112612:1,90726:112614:1,90727:112615:1,90731:112619:1,90732:112620:1,90733:112621:1,90734:112623:1,90735:112625:1,90738:112628:1,90739:112629:1,90741:117740:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90758:112650:1,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,94562:117145:1,94580:117168:1,94582:117170:1,95106:117703:1,95108:117705:1,95109:117706:1,95110:117707:1,95117:117714:1,95123:117720:1,95131:117728:1,95132:117729:1,95135:117732:1,95136:117733:1,95140:117737:1,95142:117739:1,99842:123373:1,101714:125615:1,101715:125619:1,109760:136018:1,109761:136019:1,109762:136020:1,110323:136881:1,110324:136882:1,110432:137064:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 261, 1, 'simc/midnight MID2_Rogue_Subtlety', '90636:112521:1,90638:112523:1,90639:112525:2,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90690:112578:1,90692:112580:1,90695:112583:1,90697:112585:1,90700:112588:1,90701:136807:1,90703:117172:1,90704:112592:1,90706:112594:2,90709:112597:1,90710:112598:1,90713:112601:1,90716:112604:1,90719:112607:1,90720:112608:2,90721:112609:1,90722:112610:1,90723:112611:1,90724:112612:1,90726:112614:1,90727:112615:1,90731:112619:1,90732:112620:1,90733:112621:1,90734:112623:1,90735:112625:1,90738:112628:1,90739:112629:1,90741:117740:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90758:112650:1,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,94562:117145:1,94580:117168:1,94582:117170:1,95106:117703:1,95108:117705:1,95109:117706:1,95110:117707:1,95117:117714:1,95123:117720:1,95131:117728:1,95132:117729:1,95135:117732:1,95136:117733:1,95140:117737:1,95142:117739:1,99842:123373:1,101714:125615:1,101715:125619:1,109760:136018:1,109761:136019:1,109762:136020:1,110323:136881:1,110324:136882:1,110432:137064:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 256, 0, 'Default: method.gg Raid Voidweaver (Recommended)', '82556:103834:1,82564:116182:1,82566:103690:1,82568:103693:2,82569:103694:1,82571:103696:1,82572:103697:2,82576:108226:1,82577:103702:1,82581:103706:1,82582:103708:1,82583:103709:2,82587:103713:1,82588:103714:1,82590:103718:1,82591:103719:1,82592:103721:1,82593:103722:1,82594:103723:1,82595:103724:1,82596:103725:1,82597:103726:1,82598:103727:1,82599:103728:1,82600:103729:2,82601:103731:1,82672:103818:1,82673:103819:1,82676:115884:1,82677:103823:1,82678:103825:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82712:103864:1,82713:103865:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,86730:103688:1,94668:117271:1,94669:117272:1,94670:117273:1,94683:117286:1,94692:117295:1,94693:123845:1,94694:117297:1,94695:125982:1,94696:123844:1,94703:117306:1,99801:123288:1,100212:123841:1,108731:134284:1,109006:103841:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109020:134859:1,109021:134860:1,109778:136036:1,109779:136037:1,109780:136038:1,109890:136157:1,109917:136185:1,110008:136498:1,110410:136998:1', 'https://www.method.gg/guides/discipline-priest/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 256, 1, 'method.gg Raid Voidweaver (Recommended)', '82556:103834:1,82564:116182:1,82566:103690:1,82568:103693:2,82569:103694:1,82571:103696:1,82572:103697:2,82576:108226:1,82577:103702:1,82581:103706:1,82582:103708:1,82583:103709:2,82587:103713:1,82588:103714:1,82590:103718:1,82591:103719:1,82592:103721:1,82593:103722:1,82594:103723:1,82595:103724:1,82596:103725:1,82597:103726:1,82598:103727:1,82599:103728:1,82600:103729:2,82601:103731:1,82672:103818:1,82673:103819:1,82676:115884:1,82677:103823:1,82678:103825:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82712:103864:1,82713:103865:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,86730:103688:1,94668:117271:1,94669:117272:1,94670:117273:1,94683:117286:1,94692:117295:1,94693:123845:1,94694:117297:1,94695:125982:1,94696:123844:1,94703:117306:1,99801:123288:1,100212:123841:1,108731:134284:1,109006:103841:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109020:134859:1,109021:134860:1,109778:136036:1,109779:136037:1,109780:136038:1,109890:136157:1,109917:136185:1,110008:136498:1,110410:136998:1', 'https://www.method.gg/guides/discipline-priest/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 257, 0, 'Default: method.gg Raid Archon (Recommended)', '82554:103675:1,82556:103834:1,82610:103743:1,82611:103744:2,82612:103745:1,82613:103747:1,82614:103748:1,82616:103750:1,82617:103751:1,82618:103752:1,82620:103754:1,82621:103755:1,82622:103756:1,82623:103757:1,82627:103762:1,82630:103765:1,82631:103766:1,82632:103767:1,82633:103769:1,82636:103773:1,82637:103774:1,82638:103775:1,82641:103779:1,82642:103780:1,82672:103818:1,82673:103819:1,82675:103821:1,82676:115884:1,82677:103823:1,82678:103825:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,94676:117279:1,94677:117280:1,94678:117281:1,94680:117283:1,94681:117284:1,94683:117286:1,94685:117288:1,94686:117289:1,94688:117291:1,94699:117302:1,94702:117305:1,99802:123291:1,103900:103733:1,103901:103676:1,103914:128331:2,103916:128333:1,104097:128612:1,108724:134273:1,108730:134283:1,108731:134284:1,109006:103841:1,109010:134844:2,109012:134846:1,109015:134849:1,109019:134852:1,109020:134859:1,109021:134860:1,109775:136688:1,109776:136034:1,109777:136035:1,109890:136157:1,109917:136185:1,110409:136995:1', 'https://www.method.gg/guides/holy-priest/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 257, 1, 'method.gg Raid Archon (Recommended)', '82554:103675:1,82556:103834:1,82610:103743:1,82611:103744:2,82612:103745:1,82613:103747:1,82614:103748:1,82616:103750:1,82617:103751:1,82618:103752:1,82620:103754:1,82621:103755:1,82622:103756:1,82623:103757:1,82627:103762:1,82630:103765:1,82631:103766:1,82632:103767:1,82633:103769:1,82636:103773:1,82637:103774:1,82638:103775:1,82641:103779:1,82642:103780:1,82672:103818:1,82673:103819:1,82675:103821:1,82676:115884:1,82677:103823:1,82678:103825:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82702:103852:1,82703:103853:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,82719:103871:1,94676:117279:1,94677:117280:1,94678:117281:1,94680:117283:1,94681:117284:1,94683:117286:1,94685:117288:1,94686:117289:1,94688:117291:1,94699:117302:1,94702:117305:1,99802:123291:1,103900:103733:1,103901:103676:1,103914:128331:2,103916:128333:1,104097:128612:1,108724:134273:1,108730:134283:1,108731:134284:1,109006:103841:1,109010:134844:2,109012:134846:1,109015:134849:1,109019:134852:1,109020:134859:1,109021:134860:1,109775:136688:1,109776:136034:1,109777:136035:1,109890:136157:1,109917:136185:1,110409:136995:1', 'https://www.method.gg/guides/holy-priest/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 258, 0, 'Default: simc/midnight MID2_Priest_Shadow_Voidweaver', '82552:103781:1,82555:103817:1,82556:103834:1,82559:103682:1,82560:103683:2,82563:103686:1,82646:103785:1,82647:103786:1,82649:103789:2,82651:103792:1,82654:103796:1,82655:103797:1,82656:134052:1,82657:103674:1,82658:103799:1,82659:103801:1,82663:103806:1,82665:103808:1,82666:136811:1,82667:103811:1,82668:103812:1,82669:103813:1,82670:103814:1,82672:103818:1,82673:103819:1,82676:135091:1,82677:103823:1,82678:103825:1,82679:103826:1,82680:103828:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82695:114588:1,82701:103851:1,82703:103853:1,82704:103854:1,82708:103860:1,82711:103863:1,82712:103864:1,82713:103865:1,82715:103867:1,93170:103810:1,93171:115448:1,94668:117271:1,94669:117272:1,94670:117273:1,94684:117287:1,94692:117295:1,94693:123845:1,94694:117297:1,94695:125982:1,94696:117299:1,94697:117300:1,94703:117306:1,99800:123287:1,100212:123841:1,108152:133549:2,108731:134284:1,109006:103841:1,109009:103677:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109017:136223:1,109018:134851:1,109020:134859:1,109021:134860:1,109778:136036:1,109779:136037:1,109780:136038:1,109890:136157:1,109917:136185:1,110408:136992:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 258, 1, 'simc/midnight MID2_Priest_Shadow_Voidweaver', '82552:103781:1,82555:103817:1,82556:103834:1,82559:103682:1,82560:103683:2,82563:103686:1,82646:103785:1,82647:103786:1,82649:103789:2,82651:103792:1,82654:103796:1,82655:103797:1,82656:134052:1,82657:103674:1,82658:103799:1,82659:103801:1,82663:103806:1,82665:103808:1,82666:136811:1,82667:103811:1,82668:103812:1,82669:103813:1,82670:103814:1,82672:103818:1,82673:103819:1,82676:135091:1,82677:103823:1,82678:103825:1,82679:103826:1,82680:103828:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82695:114588:1,82701:103851:1,82703:103853:1,82704:103854:1,82708:103860:1,82711:103863:1,82712:103864:1,82713:103865:1,82715:103867:1,93170:103810:1,93171:115448:1,94668:117271:1,94669:117272:1,94670:117273:1,94684:117287:1,94692:117295:1,94693:123845:1,94694:117297:1,94695:125982:1,94696:117299:1,94697:117300:1,94703:117306:1,99800:123287:1,100212:123841:1,108152:133549:2,108731:134284:1,109006:103841:1,109009:103677:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109017:136223:1,109018:134851:1,109020:134859:1,109021:134860:1,109778:136036:1,109779:136037:1,109780:136038:1,109890:136157:1,109917:136185:1,110408:136992:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 250, 0, 'Default: simc/midnight MID2_Death_Knight_Blood_San''layn', '76039:96167:1,76041:96169:1,76042:96170:1,76043:96171:1,76044:96172:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76056:96184:1,76057:96186:1,76058:96187:1,76061:96190:1,76064:96193:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76076:96205:1,76078:96207:1,76079:96208:2,76081:96210:1,76084:96213:1,76085:96214:1,76125:96256:1,76126:96257:2,76127:96258:1,76128:96259:1,76129:96260:1,76130:96261:1,76131:96262:1,76135:96266:1,76137:96268:1,76138:96269:1,76139:96271:1,76141:96273:1,76142:96274:1,76143:96276:1,76144:96277:1,76146:96279:1,76147:96280:1,76168:96303:1,76169:96304:1,76170:96305:1,76171:96306:1,76172:96307:1,76173:96308:1,95033:117630:1,95040:117637:1,95045:117642:1,95046:117643:1,95048:117645:1,95051:117648:1,95053:117650:1,95055:117652:1,95056:117891:1,95062:117659:1,95064:117661:1,95065:117662:1,99822:123325:1,102007:126015:1,102008:126016:1,102242:126296:1,102243:126298:1,109736:135994:1,109737:135995:1,109738:135996:1,110029:136523:1,110353:136917:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 250, 1, 'simc/midnight MID2_Death_Knight_Blood_San''layn', '76039:96167:1,76041:96169:1,76042:96170:1,76043:96171:1,76044:96172:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76056:96184:1,76057:96186:1,76058:96187:1,76061:96190:1,76064:96193:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76076:96205:1,76078:96207:1,76079:96208:2,76081:96210:1,76084:96213:1,76085:96214:1,76125:96256:1,76126:96257:2,76127:96258:1,76128:96259:1,76129:96260:1,76130:96261:1,76131:96262:1,76135:96266:1,76137:96268:1,76138:96269:1,76139:96271:1,76141:96273:1,76142:96274:1,76143:96276:1,76144:96277:1,76146:96279:1,76147:96280:1,76168:96303:1,76169:96304:1,76170:96305:1,76171:96306:1,76172:96307:1,76173:96308:1,95033:117630:1,95040:117637:1,95045:117642:1,95046:117643:1,95048:117645:1,95051:117648:1,95053:117650:1,95055:117652:1,95056:117891:1,95062:117659:1,95064:117661:1,95065:117662:1,99822:123325:1,102007:126015:1,102008:126016:1,102242:126296:1,102243:126298:1,109736:135994:1,109737:135995:1,109738:135996:1,110029:136523:1,110353:136917:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 251, 0, 'Default: simc/midnight MID2_Death_Knight_Frost', '76033:96161:2,76045:96173:1,76061:96190:1,76069:96198:2,76073:96202:1,76076:96205:1,76079:96208:2,76081:96210:1,76085:96214:1,76091:96220:1,76093:96222:1,76096:96225:1,76098:96228:1,76099:96229:1,76101:96231:1,76106:96236:1,76108:96238:1,76109:96239:1,76110:96240:1,76112:96242:1,76113:96243:1,76114:96244:1,76115:96245:1,76116:96246:1,76117:96247:1,76118:96248:1,76121:96252:1,76122:96253:2,76123:96254:1,95032:117629:1,95034:117631:1,95036:117633:1,95043:117640:1,95057:117654:1,95058:117655:1,95061:117658:1,95062:117659:1,95066:117663:1,95068:117665:1,99821:123324:1,101929:125874:1,101930:125875:1,101931:125876:1,101933:125878:1,102009:126017:1,106790:131618:1,109258:133362:1,109733:135991:1,109734:135992:1,110400:136968:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 251, 1, 'simc/midnight MID2_Death_Knight_Frost', '76033:96161:2,76045:96173:1,76061:96190:1,76069:96198:2,76073:96202:1,76076:96205:1,76079:96208:2,76081:96210:1,76085:96214:1,76091:96220:1,76093:96222:1,76096:96225:1,76098:96228:1,76099:96229:1,76101:96231:1,76106:96236:1,76108:96238:1,76109:96239:1,76110:96240:1,76112:96242:1,76113:96243:1,76114:96244:1,76115:96245:1,76116:96246:1,76117:96247:1,76118:96248:1,76121:96252:1,76122:96253:2,76123:96254:1,95032:117629:1,95034:117631:1,95036:117633:1,95043:117640:1,95057:117654:1,95058:117655:1,95061:117658:1,95062:117659:1,95066:117663:1,95068:117665:1,99821:123324:1,101929:125874:1,101930:125875:1,101931:125876:1,101933:125878:1,102009:126017:1,106790:131618:1,109258:133362:1,109733:135991:1,109734:135992:1,110400:136968:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 252, 0, 'Default: simc/midnight MID2_Death_Knight_Unholy_Rider', '76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76058:96187:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:133518:1,76076:96205:1,76078:96207:1,76079:96208:2,76080:96209:1,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76148:96282:1,76149:96283:2,76150:96284:2,76156:96290:1,76160:96294:1,76162:96296:1,76176:96311:1,76178:96313:1,76179:96314:1,76182:96318:1,76184:96321:1,76185:96322:1,76186:133365:1,76187:96324:1,76189:96326:1,76190:96327:1,76191:96328:1,76193:96330:1,76196:96333:1,76197:96334:1,95037:123410:1,95041:117638:1,95042:117639:1,95044:117641:1,95047:117644:1,95051:117648:1,95054:117651:1,95059:117656:1,95060:123412:1,95063:117660:1,95066:117663:1,95067:117664:1,99820:123322:1,102007:126015:1,102008:126016:1,108126:133515:1,108129:133522:1,108130:125816:1,108131:133523:1,108151:133546:1,109392:133517:1,109458:135676:1,109739:135997:1,109740:135998:1,109741:135999:1,110029:136523:1,110030:136524:1,110260:136797:1,110354:136920:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 252, 1, 'simc/midnight MID2_Death_Knight_Unholy_Rider', '76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76058:96187:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:133518:1,76076:96205:1,76078:96207:1,76079:96208:2,76080:96209:1,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76148:96282:1,76149:96283:2,76150:96284:2,76156:96290:1,76160:96294:1,76162:96296:1,76176:96311:1,76178:96313:1,76179:96314:1,76182:96318:1,76184:96321:1,76185:96322:1,76186:133365:1,76187:96324:1,76189:96326:1,76190:96327:1,76191:96328:1,76193:96330:1,76196:96333:1,76197:96334:1,95037:123410:1,95041:117638:1,95042:117639:1,95044:117641:1,95047:117644:1,95051:117648:1,95054:117651:1,95059:117656:1,95060:123412:1,95063:117660:1,95066:117663:1,95067:117664:1,99820:123322:1,102007:126015:1,102008:126016:1,108126:133515:1,108129:133522:1,108130:125816:1,108131:133523:1,108151:133546:1,109392:133517:1,109458:135676:1,109739:135997:1,109740:135998:1,109741:135999:1,110029:136523:1,110030:136524:1,110260:136797:1,110354:136920:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 262, 0, 'Default: simc/midnight MID2_Shaman_Elemental_Farseer', '80978:101844:1,80981:101850:1,80983:101853:1,80984:127924:1,80985:127925:1,80988:101859:1,80989:101860:1,80990:101861:1,80992:101864:1,80993:101865:1,80995:101867:1,80996:101869:1,80997:101870:1,80998:101871:1,80999:136714:1,81000:101874:1,81002:101876:1,81004:101879:1,81008:101885:1,81010:101887:1,81015:101892:1,94858:117455:1,94860:117457:1,94861:117458:1,94862:123632:1,94869:117466:1,94875:117472:1,94883:117480:1,94884:123630:1,94887:117484:1,94888:117485:1,94892:117489:1,94894:117491:1,99845:123377:1,103579:127851:1,103581:127853:1,103582:127855:2,103583:127856:1,103584:127857:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127864:1,103593:127868:1,103596:127871:1,103598:127873:1,103602:127877:1,103605:127880:1,103606:127881:1,103608:127884:1,103611:127888:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103622:127902:1,103623:127903:1,103624:127905:1,103626:127908:1,103627:127909:1,103628:127910:1,103631:127913:1,103633:127915:1,103634:127916:1,103635:127917:1,103638:127919:1,103639:127920:1,103640:127921:1,103641:127922:1,109387:135591:1,109492:135718:1,109730:135988:1,109731:135989:1,109732:135990:1,110066:136561:1,110085:136585:1,110402:136974:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 262, 1, 'simc/midnight MID2_Shaman_Elemental_Farseer', '80978:101844:1,80981:101850:1,80983:101853:1,80984:127924:1,80985:127925:1,80988:101859:1,80989:101860:1,80990:101861:1,80992:101864:1,80993:101865:1,80995:101867:1,80996:101869:1,80997:101870:1,80998:101871:1,80999:136714:1,81000:101874:1,81002:101876:1,81004:101879:1,81008:101885:1,81010:101887:1,81015:101892:1,94858:117455:1,94860:117457:1,94861:117458:1,94862:123632:1,94869:117466:1,94875:117472:1,94883:117480:1,94884:123630:1,94887:117484:1,94888:117485:1,94892:117489:1,94894:117491:1,99845:123377:1,103579:127851:1,103581:127853:1,103582:127855:2,103583:127856:1,103584:127857:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127864:1,103593:127868:1,103596:127871:1,103598:127873:1,103602:127877:1,103605:127880:1,103606:127881:1,103608:127884:1,103611:127888:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103622:127902:1,103623:127903:1,103624:127905:1,103626:127908:1,103627:127909:1,103628:127910:1,103631:127913:1,103633:127915:1,103634:127916:1,103635:127917:1,103638:127919:1,103639:127920:1,103640:127921:1,103641:127922:1,109387:135591:1,109492:135718:1,109730:135988:1,109731:135989:1,109732:135990:1,110066:136561:1,110085:136585:1,110402:136974:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 263, 0, 'Default: simc/midnight MID2_Shaman_Enhancement_Stormbringer', '80938:101801:1,80939:101802:1,80941:101804:1,80942:101805:1,80943:101806:1,80944:101808:1,80949:101813:1,80950:101814:2,80951:101815:1,80953:101818:1,80954:101819:1,80958:101823:1,80959:101824:1,80960:101825:1,80961:101826:1,80962:101827:1,80967:101832:1,80968:101833:1,80969:101834:1,80973:101839:1,80974:101840:1,92219:114291:1,94863:128226:1,94867:117464:1,94868:117465:1,94870:117467:1,94873:117470:1,94877:117474:1,94880:117477:1,94885:117482:1,94886:117483:1,94889:117486:1,94892:117489:1,94893:117490:1,99847:123381:1,103579:127851:1,103581:127854:1,103582:127855:2,103583:127856:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127865:1,103593:127868:1,103594:127869:1,103596:127871:1,103602:127877:1,103605:127880:1,103606:127881:1,103607:127882:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103618:127896:2,103622:127902:1,103625:127906:1,103627:127909:1,103628:127910:1,103642:101799:1,103871:128270:1,109190:135252:1,109192:135254:1,109193:135255:1,109194:128236:1,109387:135591:1,109389:135593:1,109727:135985:1,109728:135986:1,109729:135987:1,109909:136176:1,110085:136585:1,110401:136971:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 263, 1, 'simc/midnight MID2_Shaman_Enhancement_Stormbringer', '80938:101801:1,80939:101802:1,80941:101804:1,80942:101805:1,80943:101806:1,80944:101808:1,80949:101813:1,80950:101814:2,80951:101815:1,80953:101818:1,80954:101819:1,80958:101823:1,80959:101824:1,80960:101825:1,80961:101826:1,80962:101827:1,80967:101832:1,80968:101833:1,80969:101834:1,80973:101839:1,80974:101840:1,92219:114291:1,94863:128226:1,94867:117464:1,94868:117465:1,94870:117467:1,94873:117470:1,94877:117474:1,94880:117477:1,94885:117482:1,94886:117483:1,94889:117486:1,94892:117489:1,94893:117490:1,99847:123381:1,103579:127851:1,103581:127854:1,103582:127855:2,103583:127856:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127865:1,103593:127868:1,103594:127869:1,103596:127871:1,103602:127877:1,103605:127880:1,103606:127881:1,103607:127882:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103618:127896:2,103622:127902:1,103625:127906:1,103627:127909:1,103628:127910:1,103642:101799:1,103871:128270:1,109190:135252:1,109192:135254:1,109193:135255:1,109194:128236:1,109387:135591:1,109389:135593:1,109727:135985:1,109728:135986:1,109729:135987:1,109909:136176:1,110085:136585:1,110401:136971:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 264, 0, 'Default: method.gg Raid Totemic (Recommended)', '80976:101842:1,81018:101895:1,81021:101899:1,81022:101900:1,81024:101902:1,81027:101905:1,81031:101911:1,81032:101912:1,81033:135485:1,81037:101919:1,81038:101920:1,81040:101923:1,81041:101924:1,81042:101925:1,81044:101928:1,81047:101932:1,81048:101934:1,81049:101935:1,81051:101937:1,81052:101939:2,81055:101942:1,92675:114811:1,92677:114813:1,94859:117456:1,94866:125824:1,94871:117468:1,94872:117469:1,94874:117471:1,94877:117474:1,94879:117476:1,94881:125822:1,94882:117479:1,94888:117485:1,94890:117487:1,94891:117488:1,99846:123378:1,103427:127671:2,103428:127672:1,103433:127679:1,103581:127854:1,103582:127855:2,103583:127856:1,103584:127857:1,103585:127858:1,103586:127859:1,103588:127861:1,103590:127863:1,103591:127864:1,103593:127868:1,103594:127869:1,103596:127871:1,103598:127873:1,103599:136567:1,103601:127876:1,103602:127877:1,103606:127881:1,103607:127883:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:1,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103625:127906:1,103626:127908:1,103627:127909:1,109301:135487:1,109386:135590:1,109387:135591:1,109388:135592:1,109724:135982:1,109725:135983:1,109726:135984:1,110085:136585:1,110403:136977:1,113376:140663:1', 'https://www.method.gg/guides/restoration-shaman/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 264, 1, 'method.gg Raid Totemic (Recommended)', '80976:101842:1,81018:101895:1,81021:101899:1,81022:101900:1,81024:101902:1,81027:101905:1,81031:101911:1,81032:101912:1,81033:135485:1,81037:101919:1,81038:101920:1,81040:101923:1,81041:101924:1,81042:101925:1,81044:101928:1,81047:101932:1,81048:101934:1,81049:101935:1,81051:101937:1,81052:101939:2,81055:101942:1,92675:114811:1,92677:114813:1,94859:117456:1,94866:125824:1,94871:117468:1,94872:117469:1,94874:117471:1,94877:117474:1,94879:117476:1,94881:125822:1,94882:117479:1,94888:117485:1,94890:117487:1,94891:117488:1,99846:123378:1,103427:127671:2,103428:127672:1,103433:127679:1,103581:127854:1,103582:127855:2,103583:127856:1,103584:127857:1,103585:127858:1,103586:127859:1,103588:127861:1,103590:127863:1,103591:127864:1,103593:127868:1,103594:127869:1,103596:127871:1,103598:127873:1,103599:136567:1,103601:127876:1,103602:127877:1,103606:127881:1,103607:127883:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:1,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103625:127906:1,103626:127908:1,103627:127909:1,109301:135487:1,109386:135590:1,109387:135591:1,109388:135592:1,109724:135982:1,109725:135983:1,109726:135984:1,110085:136585:1,110403:136977:1,113376:140663:1', 'https://www.method.gg/guides/restoration-shaman/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 62, 0, 'Default: simc/midnight MID2_Mage_Arcane_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62121:80180:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,93524:115877:1,94647:117250:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99830:123344:1,102441:126511:1,102445:126515:1,102446:126516:1,102449:126519:1,102451:126521:1,102453:126523:1,102460:134025:1,102465:134020:1,102467:126537:1,102468:126538:1,102469:126539:1,102470:126540:1,102471:126541:1,102472:126542:1,102474:126544:1,102475:126545:1,102480:126550:2,104113:128689:1,108536:134024:1,108537:134026:2,108538:134027:1,108539:134028:1,108654:134183:1,108657:134187:1,108658:134188:1,108660:134190:1,108661:134191:1,108662:134192:2,108664:134194:1,108665:134196:1,109002:134834:1,109478:135698:1,109667:135918:1,109668:135919:1,109669:135920:1,110080:136578:1,110081:136579:1,110420:137028:1,110442:137084:1,110597:137410:1,110849:137841:1,110850:137842:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 62, 1, 'simc/midnight MID2_Mage_Arcane_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62121:80180:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,93524:115877:1,94647:117250:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99830:123344:1,102441:126511:1,102445:126515:1,102446:126516:1,102449:126519:1,102451:126521:1,102453:126523:1,102460:134025:1,102465:134020:1,102467:126537:1,102468:126538:1,102469:126539:1,102470:126540:1,102471:126541:1,102472:126542:1,102474:126544:1,102475:126545:1,102480:126550:2,104113:128689:1,108536:134024:1,108537:134026:2,108538:134027:1,108539:134028:1,108654:134183:1,108657:134187:1,108658:134188:1,108660:134190:1,108661:134191:1,108662:134192:2,108664:134194:1,108665:134196:1,109002:134834:1,109478:135698:1,109667:135918:1,109668:135919:1,109669:135920:1,110080:136578:1,110081:136579:1,110420:137028:1,110442:137084:1,110597:137410:1,110849:137841:1,110850:137842:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 63, 0, 'Default: simc/midnight MID2_Mage_Fire_Sunfury', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62119:80178:1,62122:80181:1,62123:80182:2,62124:80183:1,62127:80187:1,93524:115877:1,94643:117246:1,94644:117247:1,94645:117248:1,94646:117249:1,94647:117250:1,94648:117251:1,94649:117252:1,94650:123867:1,94651:117254:1,94652:117255:1,94653:117256:1,99829:123340:1,100989:124750:1,100995:124756:1,100998:124759:1,100999:124760:1,101007:135618:1,101009:124771:1,101015:124778:1,101016:124779:1,101019:124783:2,101021:124786:1,101024:124789:1,101027:124793:1,101883:125819:1,108654:134183:1,108656:134186:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,109393:135600:1,109394:135601:1,109396:135604:1,109398:135606:1,109399:135607:1,109400:135608:1,109401:135609:1,109402:135610:1,109403:135612:1,109406:135615:1,109407:135616:1,109408:135617:1,109409:135619:1,109411:135621:1,109673:135924:1,109674:135925:1,109675:135926:1,109956:136441:1,110079:136577:1,110081:136579:1,110086:136587:1,110321:136878:1,110322:136879:1,110423:137037:1,110597:137410:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 63, 1, 'simc/midnight MID2_Mage_Fire_Sunfury', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62119:80178:1,62122:80181:1,62123:80182:2,62124:80183:1,62127:80187:1,93524:115877:1,94643:117246:1,94644:117247:1,94645:117248:1,94646:117249:1,94647:117250:1,94648:117251:1,94649:117252:1,94650:123867:1,94651:117254:1,94652:117255:1,94653:117256:1,99829:123340:1,100989:124750:1,100995:124756:1,100998:124759:1,100999:124760:1,101007:135618:1,101009:124771:1,101015:124778:1,101016:124779:1,101019:124783:2,101021:124786:1,101024:124789:1,101027:124793:1,101883:125819:1,108654:134183:1,108656:134186:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,109393:135600:1,109394:135601:1,109396:135604:1,109398:135606:1,109399:135607:1,109400:135608:1,109401:135609:1,109402:135610:1,109403:135612:1,109406:135615:1,109407:135616:1,109408:135617:1,109409:135619:1,109411:135621:1,109673:135924:1,109674:135925:1,109675:135926:1,109956:136441:1,110079:136577:1,110081:136579:1,110086:136587:1,110321:136878:1,110322:136879:1,110423:137037:1,110597:137410:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 64, 0, 'Default: simc/midnight MID2_Mage_Frost_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62107:80165:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62117:80176:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,62150:134540:1,62153:80216:1,62157:80220:1,62164:80227:1,62170:80234:1,62173:80237:1,62176:80241:1,62177:80242:1,62178:80243:1,62179:80244:1,62180:80245:1,62181:80247:1,62182:80248:1,62184:80250:1,81468:102429:1,93524:115877:1,94636:117239:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99828:123339:1,103771:134418:1,108653:134180:1,108654:134183:1,108655:134185:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108850:136839:1,108851:134407:1,108852:134408:2,108855:134411:1,108857:134413:1,108858:134414:2,108859:134415:1,108864:134421:1,109667:135918:1,109668:135919:1,109669:135946:1,109915:136182:1,109916:136183:1,110081:136579:1,110258:136796:1,110422:137034:1,110597:137410:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 64, 1, 'simc/midnight MID2_Mage_Frost_Spellslinger', '62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62107:80165:1,62112:80170:2,62114:80173:2,62115:80174:1,62116:80175:1,62117:80176:1,62122:80181:1,62123:80182:2,62124:80183:1,62125:134184:1,62127:80187:1,62150:134540:1,62153:80216:1,62157:80220:1,62164:80227:1,62170:80234:1,62173:80237:1,62176:80241:1,62177:80242:1,62178:80243:1,62179:80244:1,62180:80245:1,62181:80247:1,62182:80248:1,62184:80250:1,81468:102429:1,93524:115877:1,94636:117239:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99828:123339:1,103771:134418:1,108653:134180:1,108654:134183:1,108655:134185:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108850:136839:1,108851:134407:1,108852:134408:2,108855:134411:1,108857:134413:1,108858:134414:2,108859:134415:1,108864:134421:1,109667:135918:1,109668:135919:1,109669:135946:1,109915:136182:1,109916:136183:1,110081:136579:1,110258:136796:1,110422:137034:1,110597:137410:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 265, 0, 'Default: simc/midnight MID2_Warlock_Affliction_Soul_Harvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91446:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,72032:91552:1,72033:91553:1,72034:91554:1,72037:91558:1,72041:91562:1,72045:124692:1,72046:91567:1,72047:91568:1,72049:91570:1,72050:91571:1,72051:91572:1,72055:91577:2,72058:91580:2,94821:117418:1,94823:117420:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94840:117437:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94857:117454:1,99850:123384:1,100941:124694:1,102031:126064:1,102247:126303:1,109837:136096:1,109838:136097:1,109839:136098:1,109842:136102:2,109843:136103:1,109844:136104:1,109845:136105:1,109847:136107:1,109851:136111:1,109852:136112:1,109855:136115:1,109857:136117:1,109858:136118:1,109859:136119:1,109860:136120:1,109861:136121:1,109862:136122:1,109863:136123:1,109865:136125:2,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110269:136812:1,110405:136983:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 265, 1, 'simc/midnight MID2_Warlock_Affliction_Soul_Harvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91446:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,72032:91552:1,72033:91553:1,72034:91554:1,72037:91558:1,72041:91562:1,72045:124692:1,72046:91567:1,72047:91568:1,72049:91570:1,72050:91571:1,72051:91572:1,72055:91577:2,72058:91580:2,94821:117418:1,94823:117420:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94840:117437:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94857:117454:1,99850:123384:1,100941:124694:1,102031:126064:1,102247:126303:1,109837:136096:1,109838:136097:1,109839:136098:1,109842:136102:2,109843:136103:1,109844:136104:1,109845:136105:1,109847:136107:1,109851:136111:1,109852:136112:1,109855:136115:1,109857:136117:1,109858:136118:1,109859:136119:1,109860:136120:1,109861:136121:1,109862:136122:1,109863:136123:1,109865:136125:2,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110269:136812:1,110405:136983:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 266, 0, 'Default: simc/midnight MID2_Warlock_Demonology_Soulharvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71955:91466:1,71956:91468:1,71957:91469:1,94821:117418:1,94823:123839:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94855:117452:1,94857:117454:1,99849:123383:1,100941:124694:1,101886:125828:1,101891:125834:1,101892:125835:1,101893:136731:1,101894:125837:1,101895:125839:1,101903:125848:2,101905:125850:1,101908:125854:1,101909:125855:1,101914:125860:2,101920:125866:1,101923:125869:1,109244:135306:1,109249:135311:2,109250:135312:1,109251:135313:1,109252:135314:1,109253:135315:1,109257:135319:1,109837:136096:1,109838:136097:1,109839:136098:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109847:136107:1,109934:136227:1,109936:136229:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110191:136719:1,110193:136721:1,110194:136722:1,110197:136726:1,110198:136727:1,110404:136980:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 266, 1, 'simc/midnight MID2_Warlock_Demonology_Soulharvester', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71955:91466:1,71956:91468:1,71957:91469:1,94821:117418:1,94823:123839:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94855:117452:1,94857:117454:1,99849:123383:1,100941:124694:1,101886:125828:1,101891:125834:1,101892:125835:1,101893:136731:1,101894:125837:1,101895:125839:1,101903:125848:2,101905:125850:1,101908:125854:1,101909:125855:1,101914:125860:2,101920:125866:1,101923:125869:1,109244:135306:1,109249:135311:2,109250:135312:1,109251:135313:1,109252:135314:1,109253:135315:1,109257:135319:1,109837:136096:1,109838:136097:1,109839:136098:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109847:136107:1,109934:136227:1,109936:136229:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110191:136719:1,110193:136721:1,110194:136722:1,110197:136726:1,110198:136727:1,110404:136980:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 267, 0, 'Default: simc/midnight MID2_Warlock_Destruction_Hellcaller', '71918:91425:1,71922:91430:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91446:1,71942:91452:1,71944:91454:1,71947:91457:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,71960:91473:1,71964:91477:1,71965:91478:1,71966:91479:1,71968:91481:1,71969:91482:2,71971:91484:1,71973:91486:1,71975:91489:1,71980:91496:1,71983:91500:2,71985:91502:1,72059:91581:1,72060:91582:1,72061:91583:1,72062:91584:1,72065:91588:1,72066:91589:2,72067:91590:1,72068:91591:1,72069:91592:1,94822:123309:1,94829:117426:1,94834:117431:1,94835:117432:1,94837:117434:1,94840:117437:1,94842:117439:1,94844:117441:1,94845:117442:1,94853:117450:1,94854:123310:1,94855:117452:1,99848:123382:1,100941:124694:1,101992:126002:1,101994:126004:1,108678:134219:1,108681:134221:1,109834:136093:1,109835:136094:1,109836:136095:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109848:136738:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110280:136833:1,110282:136835:1,110406:136986:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 267, 1, 'simc/midnight MID2_Warlock_Destruction_Hellcaller', '71918:91425:1,71922:91430:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91446:1,71942:91452:1,71944:91454:1,71947:91457:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,71960:91473:1,71964:91477:1,71965:91478:1,71966:91479:1,71968:91481:1,71969:91482:2,71971:91484:1,71973:91486:1,71975:91489:1,71980:91496:1,71983:91500:2,71985:91502:1,72059:91581:1,72060:91582:1,72061:91583:1,72062:91584:1,72065:91588:1,72066:91589:2,72067:91590:1,72068:91591:1,72069:91592:1,94822:123309:1,94829:117426:1,94834:117431:1,94835:117432:1,94837:117434:1,94840:117437:1,94842:117439:1,94844:117441:1,94845:117442:1,94853:117450:1,94854:123310:1,94855:117452:1,99848:123382:1,100941:124694:1,101992:126002:1,101994:126004:1,108678:134219:1,108681:134221:1,109834:136093:1,109835:136094:1,109836:136095:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109848:136738:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110280:136833:1,110282:136835:1,110406:136986:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 268, 0, 'Default: simc/midnight MID2_Monk_Brewmaster', '101064:124838:1,101065:136148:1,101067:136146:1,101069:124843:1,101071:124845:1,101072:124846:1,101074:124848:2,101075:124849:1,101076:124850:1,101078:124853:1,101079:124854:1,101080:124855:1,101082:124857:1,101086:124863:1,101087:124864:1,101088:124865:1,101090:124867:1,101135:124924:1,101136:124926:1,101140:124930:1,101141:124931:1,101142:124932:1,101146:124936:1,101147:124937:1,101152:124943:1,101153:124944:1,101156:124948:1,101158:124950:1,101160:124954:1,101161:124955:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124969:1,101175:124971:1,101177:124974:1,101178:124975:1,101179:124976:2,101181:124979:1,101182:124980:1,101183:124982:1,101187:124987:1,101188:124988:1,101190:124991:1,101193:124996:1,101195:124999:1,101197:125001:1,101198:125003:1,101201:125006:1,101202:125008:1,101219:125028:1,101220:125029:1,101221:125031:1,101222:125032:1,101223:125033:1,101224:125035:1,101225:125036:1,101226:125037:1,101227:125039:1,101228:125040:1,101229:125042:1,101230:125043:1,101248:125069:1,101711:125002:1,102004:124859:1,102433:126501:1,109694:135952:1,109695:135953:1,109696:135954:1,109826:136085:1,109827:136086:1,109882:136145:1,109910:136177:1,110024:136517:1,110435:137075:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 268, 1, 'simc/midnight MID2_Monk_Brewmaster', '101064:124838:1,101065:136148:1,101067:136146:1,101069:124843:1,101071:124845:1,101072:124846:1,101074:124848:2,101075:124849:1,101076:124850:1,101078:124853:1,101079:124854:1,101080:124855:1,101082:124857:1,101086:124863:1,101087:124864:1,101088:124865:1,101090:124867:1,101135:124924:1,101136:124926:1,101140:124930:1,101141:124931:1,101142:124932:1,101146:124936:1,101147:124937:1,101152:124943:1,101153:124944:1,101156:124948:1,101158:124950:1,101160:124954:1,101161:124955:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124969:1,101175:124971:1,101177:124974:1,101178:124975:1,101179:124976:2,101181:124979:1,101182:124980:1,101183:124982:1,101187:124987:1,101188:124988:1,101190:124991:1,101193:124996:1,101195:124999:1,101197:125001:1,101198:125003:1,101201:125006:1,101202:125008:1,101219:125028:1,101220:125029:1,101221:125031:1,101222:125032:1,101223:125033:1,101224:125035:1,101225:125036:1,101226:125037:1,101227:125039:1,101228:125040:1,101229:125042:1,101230:125043:1,101248:125069:1,101711:125002:1,102004:124859:1,102433:126501:1,109694:135952:1,109695:135953:1,109696:135954:1,109826:136085:1,109827:136086:1,109882:136145:1,109910:136177:1,110024:136517:1,110435:137075:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 269, 0, 'Default: simc/midnight MID2_Monk_Windwalker', '101035:124805:2,101036:124806:1,101037:124807:1,101039:124810:1,101044:126026:1,101045:124817:1,101046:124818:1,101048:124820:1,101049:124821:1,101052:124825:1,101053:124826:1,101054:124827:1,101055:124828:1,101057:134453:1,101059:124833:1,101060:124834:1,101136:124926:1,101137:124927:1,101140:124930:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101153:124944:1,101159:124953:1,101160:124954:1,101162:124956:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124969:1,101175:124971:1,101178:124975:1,101179:124976:2,101182:124980:1,101183:124982:1,101184:124983:2,101185:124984:1,101186:124985:1,101203:125010:1,101205:125012:1,101206:125013:1,101207:134452:1,101208:125015:1,101209:125016:1,101210:125017:1,101213:125020:1,101214:125021:1,101215:125022:1,101216:125023:1,101217:125025:1,101218:125026:1,101232:125046:1,101243:125062:1,101244:125063:1,101245:125065:1,101246:125066:1,101247:125068:1,101248:125069:1,101249:125070:1,101250:125071:1,101251:125072:1,101252:125073:1,101253:125074:1,101254:125076:1,108946:134543:1,109697:135955:1,109698:135956:1,109699:135957:1,110020:136511:1,110022:136514:1,110023:136515:1,110098:136599:1,110436:137076:3', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 269, 1, 'simc/midnight MID2_Monk_Windwalker', '101035:124805:2,101036:124806:1,101037:124807:1,101039:124810:1,101044:126026:1,101045:124817:1,101046:124818:1,101048:124820:1,101049:124821:1,101052:124825:1,101053:124826:1,101054:124827:1,101055:124828:1,101057:134453:1,101059:124833:1,101060:124834:1,101136:124926:1,101137:124927:1,101140:124930:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101153:124944:1,101159:124953:1,101160:124954:1,101162:124956:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124969:1,101175:124971:1,101178:124975:1,101179:124976:2,101182:124980:1,101183:124982:1,101184:124983:2,101185:124984:1,101186:124985:1,101203:125010:1,101205:125012:1,101206:125013:1,101207:134452:1,101208:125015:1,101209:125016:1,101210:125017:1,101213:125020:1,101214:125021:1,101215:125022:1,101216:125023:1,101217:125025:1,101218:125026:1,101232:125046:1,101243:125062:1,101244:125063:1,101245:125065:1,101246:125066:1,101247:125068:1,101248:125069:1,101249:125070:1,101250:125071:1,101251:125072:1,101252:125073:1,101253:125074:1,101254:125076:1,108946:134543:1,109697:135955:1,109698:135956:1,109699:135957:1,110020:136511:1,110022:136514:1,110023:136515:1,110098:136599:1,110436:137076:3', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 270, 0, 'Default: method.gg Raid (Conduit of the Celestials) - Preferred', '101089:124866:1,101093:124871:1,101095:124873:1,101096:124875:1,101097:124876:1,101102:128221:1,101104:124885:1,101107:124888:1,101108:124889:1,101110:124891:1,101111:124892:2,101112:124893:1,101113:124894:1,101114:124896:2,101115:124897:1,101117:124899:1,101121:124905:1,101122:124906:1,101123:124907:1,101124:124908:2,101127:125932:1,101128:124913:1,101129:124915:1,101130:124916:1,101131:124918:1,101132:124920:1,101133:124921:1,101134:124922:1,101136:124926:1,101139:124929:1,101140:124930:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101153:124944:1,101157:124949:1,101161:124955:1,101164:124958:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101179:124976:2,101183:124982:1,101185:124984:1,101186:124985:1,101223:125033:1,101231:125045:1,101233:125049:1,101234:125050:1,101235:125052:1,101236:125054:1,101237:125055:1,101238:125056:1,101239:125058:1,101240:125059:1,101242:125061:1,102432:126500:1,109516:135749:1,109700:135958:1,109701:135959:1,110019:136510:1,110021:136512:1,110024:136517:1,110026:136519:1,110027:136520:1,110067:136562:1,110097:136598:1,110211:136747:1,110218:136754:1', 'https://www.method.gg/guides/mistweaver-monk/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 270, 1, 'method.gg Raid (Conduit of the Celestials) - Preferred', '101089:124866:1,101093:124871:1,101095:124873:1,101096:124875:1,101097:124876:1,101102:128221:1,101104:124885:1,101107:124888:1,101108:124889:1,101110:124891:1,101111:124892:2,101112:124893:1,101113:124894:1,101114:124896:2,101115:124897:1,101117:124899:1,101121:124905:1,101122:124906:1,101123:124907:1,101124:124908:2,101127:125932:1,101128:124913:1,101129:124915:1,101130:124916:1,101131:124918:1,101132:124920:1,101133:124921:1,101134:124922:1,101136:124926:1,101139:124929:1,101140:124930:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101153:124944:1,101157:124949:1,101161:124955:1,101164:124958:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124970:1,101175:124971:1,101179:124976:2,101183:124982:1,101185:124984:1,101186:124985:1,101223:125033:1,101231:125045:1,101233:125049:1,101234:125050:1,101235:125052:1,101236:125054:1,101237:125055:1,101238:125056:1,101239:125058:1,101240:125059:1,101242:125061:1,102432:126500:1,109516:135749:1,109700:135958:1,109701:135959:1,110019:136510:1,110021:136512:1,110024:136517:1,110026:136519:1,110027:136520:1,110067:136562:1,110097:136598:1,110211:136747:1,110218:136754:1', 'https://www.method.gg/guides/mistweaver-monk/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 102, 0, 'Default: method.gg Elune’s Chosen - Single Target', '82198:103276:1,82201:103279:1,82202:103280:1,82206:103284:1,82207:128589:1,82208:103286:1,82209:103287:1,82210:103288:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82241:103320:1,82244:103324:1,82246:103326:1,88201:109833:1,88203:109835:1,88204:109836:1,88206:109839:1,88207:109840:2,88208:109842:1,88212:109846:1,88214:109848:2,88215:109849:1,88218:109852:1,88221:109856:1,88222:109857:1,88223:109858:1,88224:109859:1,88225:109861:1,88226:109862:1,88227:109863:2,88231:109867:1,88234:109870:1,88235:109871:1,88236:109872:1,91048:115458:1,93714:116102:1,94585:117772:1,94586:117178:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:123304:1,94598:117193:1,94600:117195:1,94607:117204:1,94608:117205:1,99808:123302:1,100174:123793:1,100175:123794:1,100176:123795:1,100177:123796:2,100223:123868:1,103846:128230:1,103847:128231:1,104078:128579:1,104080:128584:1,104083:128588:1,104085:128591:1,108032:133404:1,108033:133405:1,109718:135976:1,109719:135977:1,109720:135978:1,110279:136832:1,110421:137031:1', 'https://www.method.gg/guides/balance-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 102, 1, 'method.gg Elune’s Chosen - Single Target', '82198:103276:1,82201:103279:1,82202:103280:1,82206:103284:1,82207:128589:1,82208:103286:1,82209:103287:1,82210:103288:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82241:103320:1,82244:103324:1,82246:103326:1,88201:109833:1,88203:109835:1,88204:109836:1,88206:109839:1,88207:109840:2,88208:109842:1,88212:109846:1,88214:109848:2,88215:109849:1,88218:109852:1,88221:109856:1,88222:109857:1,88223:109858:1,88224:109859:1,88225:109861:1,88226:109862:1,88227:109863:2,88231:109867:1,88234:109870:1,88235:109871:1,88236:109872:1,91048:115458:1,93714:116102:1,94585:117772:1,94586:117178:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:123304:1,94598:117193:1,94600:117195:1,94607:117204:1,94608:117205:1,99808:123302:1,100174:123793:1,100175:123794:1,100176:123795:1,100177:123796:2,100223:123868:1,103846:128230:1,103847:128231:1,104078:128579:1,104080:128584:1,104083:128588:1,104085:128591:1,108032:133404:1,108033:133405:1,109718:135976:1,109719:135977:1,109720:135978:1,110279:136832:1,110421:137031:1', 'https://www.method.gg/guides/balance-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 103, 0, 'Default: method.gg Wildstalker', '82085:103144:1,82088:103147:1,82091:103150:1,82092:103152:1,82096:103157:1,82099:103160:1,82100:103161:1,82101:103162:1,82102:103163:1,82104:103165:1,82106:103167:1,82107:103168:1,82108:103170:1,82109:103172:1,82110:103173:1,82111:103174:1,82112:103175:1,82114:103177:1,82115:103179:2,82116:103180:1,82117:103181:1,82118:103182:1,82119:103183:1,82121:103185:2,82122:103186:1,82123:103187:1,82124:103188:1,82198:103276:1,82199:103277:1,82206:103284:1,82207:128589:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82222:103300:1,82223:103301:1,82224:103302:1,82225:103303:2,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82239:103318:1,82241:103320:1,82242:103322:1,82244:103324:1,82246:103326:1,92641:114771:1,94609:117206:1,94610:117207:1,94611:117208:1,94612:117210:1,94613:117211:1,94614:117214:1,94615:117215:1,94616:117216:1,94618:117218:1,94619:117219:1,94620:117220:1,94621:117221:1,94622:117222:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117230:1,94629:117231:1,94630:117232:1,94631:117234:1,99805:123296:1,100175:123794:1,100176:123795:1,100177:123796:2,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109715:135973:1,109716:135974:1,109717:135975:1,109721:135979:1,109722:135980:1,109723:136624:1,110426:137046:1', 'https://www.method.gg/guides/feral-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 103, 1, 'method.gg Wildstalker', '82085:103144:1,82088:103147:1,82091:103150:1,82092:103152:1,82096:103157:1,82099:103160:1,82100:103161:1,82101:103162:1,82102:103163:1,82104:103165:1,82106:103167:1,82107:103168:1,82108:103170:1,82109:103172:1,82110:103173:1,82111:103174:1,82112:103175:1,82114:103177:1,82115:103179:2,82116:103180:1,82117:103181:1,82118:103182:1,82119:103183:1,82121:103185:2,82122:103186:1,82123:103187:1,82124:103188:1,82198:103276:1,82199:103277:1,82206:103284:1,82207:128589:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82222:103300:1,82223:103301:1,82224:103302:1,82225:103303:2,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82239:103318:1,82241:103320:1,82242:103322:1,82244:103324:1,82246:103326:1,92641:114771:1,94609:117206:1,94610:117207:1,94611:117208:1,94612:117210:1,94613:117211:1,94614:117214:1,94615:117215:1,94616:117216:1,94618:117218:1,94619:117219:1,94620:117220:1,94621:117221:1,94622:117222:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117230:1,94629:117231:1,94630:117232:1,94631:117234:1,99805:123296:1,100175:123794:1,100176:123795:1,100177:123796:2,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109715:135973:1,109716:135974:1,109717:135975:1,109721:135979:1,109722:135980:1,109723:136624:1,110426:137046:1', 'https://www.method.gg/guides/feral-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 104, 0, 'Default: method.gg Elune’s Chosen (Raid)', '82126:103190:1,82127:103191:1,82129:103193:1,82131:103195:1,82136:103201:1,82138:103203:2,82140:103206:1,82143:103210:2,82145:103212:1,82146:103213:2,82147:135336:1,82149:103216:1,82152:103221:1,82153:103222:1,82154:103223:2,82160:103229:1,82161:103231:1,82198:103276:1,82199:103277:1,82206:103284:1,82207:128589:1,82210:103288:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82223:103301:1,82224:103302:1,82225:103303:2,82227:103305:1,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82239:103318:1,82241:103320:1,82242:103322:1,82244:103324:1,82246:103326:1,92226:103208:1,92227:103218:1,92585:114698:1,92586:114699:1,92587:114700:1,94585:117176:1,94586:117177:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:123304:1,94598:117193:1,94607:117204:1,94608:117205:1,94609:117206:1,99807:123295:1,100175:123794:1,100176:123795:1,100223:123868:1,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109375:135568:1,109377:135491:1,109378:135570:1,109379:135490:1,109718:135976:1,109719:135977:1,109720:135978:1,110431:137061:1', 'https://www.method.gg/guides/guardian-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 104, 1, 'method.gg Elune’s Chosen (Raid)', '82126:103190:1,82127:103191:1,82129:103193:1,82131:103195:1,82136:103201:1,82138:103203:2,82140:103206:1,82143:103210:2,82145:103212:1,82146:103213:2,82147:135336:1,82149:103216:1,82152:103221:1,82153:103222:1,82154:103223:2,82160:103229:1,82161:103231:1,82198:103276:1,82199:103277:1,82206:103284:1,82207:128589:1,82210:103288:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82223:103301:1,82224:103302:1,82225:103303:2,82227:103305:1,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82239:103318:1,82241:103320:1,82242:103322:1,82244:103324:1,82246:103326:1,92226:103208:1,92227:103218:1,92585:114698:1,92586:114699:1,92587:114700:1,94585:117176:1,94586:117177:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:123304:1,94598:117193:1,94607:117204:1,94608:117205:1,94609:117206:1,99807:123295:1,100175:123794:1,100176:123795:1,100223:123868:1,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109375:135568:1,109377:135491:1,109378:135570:1,109379:135490:1,109718:135976:1,109719:135977:1,109720:135978:1,110431:137061:1', 'https://www.method.gg/guides/guardian-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 105, 0, 'Default: method.gg Raid: Wildstalker (Best)', '82043:117104:1,82045:103096:1,82047:103098:1,82049:103100:1,82050:103101:1,82051:103102:1,82052:103105:1,82053:103106:1,82054:103108:1,82055:103109:1,82057:103111:1,82058:103112:1,82059:103113:1,82060:103114:1,82063:103118:1,82064:103119:1,82065:103121:1,82068:103124:2,82070:103126:1,82072:103128:1,82073:103129:1,82076:103132:1,82079:137507:1,82082:103141:1,82083:103142:1,82198:103276:1,82199:103277:1,82205:103283:1,82206:103284:1,82207:128589:1,82209:103287:1,82210:103288:1,82214:103292:2,82217:103295:1,82218:103296:1,82219:103297:1,82220:103298:1,82222:103300:1,82225:103303:2,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82240:103319:1,82243:103323:2,82244:103324:1,94600:117195:1,94621:117221:1,94622:119855:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117229:1,94629:117231:1,94630:117232:1,94631:117233:1,99806:123298:1,100173:123792:1,100175:123794:1,100176:123795:1,100177:123796:2,103873:128274:1,103874:128708:1,103876:128277:1,104084:128590:1,104085:128591:1,104125:128707:1,109715:135973:1,109716:135974:1,109717:135975:1,110424:137040:1', 'https://www.method.gg/guides/restoration-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 105, 1, 'method.gg Raid: Wildstalker (Best)', '82043:117104:1,82045:103096:1,82047:103098:1,82049:103100:1,82050:103101:1,82051:103102:1,82052:103105:1,82053:103106:1,82054:103108:1,82055:103109:1,82057:103111:1,82058:103112:1,82059:103113:1,82060:103114:1,82063:103118:1,82064:103119:1,82065:103121:1,82068:103124:2,82070:103126:1,82072:103128:1,82073:103129:1,82076:103132:1,82079:137507:1,82082:103141:1,82083:103142:1,82198:103276:1,82199:103277:1,82205:103283:1,82206:103284:1,82207:128589:1,82209:103287:1,82210:103288:1,82214:103292:2,82217:103295:1,82218:103296:1,82219:103297:1,82220:103298:1,82222:103300:1,82225:103303:2,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82240:103319:1,82243:103323:2,82244:103324:1,94600:117195:1,94621:117221:1,94622:119855:1,94623:117223:1,94624:117224:1,94625:117225:1,94626:117226:1,94627:117227:1,94628:117229:1,94629:117231:1,94630:117232:1,94631:117233:1,99806:123298:1,100173:123792:1,100175:123794:1,100176:123795:1,100177:123796:2,103873:128274:1,103874:128708:1,103876:128277:1,104084:128590:1,104085:128591:1,104125:128707:1,109715:135973:1,109716:135974:1,109717:135975:1,110424:137040:1', 'https://www.method.gg/guides/restoration-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 577, 0, 'Default: simc/midnight MID2_Demon_Hunter_Havoc_Fel-Scarred', '90914:112823:1,90921:112830:1,90922:112831:1,90923:112832:1,90925:112834:1,90927:136502:1,90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90939:112850:1,90940:112851:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90993:112911:1,90994:112912:1,90996:112914:1,90997:117755:1,91000:112918:2,91001:112919:1,91002:112921:1,91003:112923:1,91006:112926:1,91007:112927:1,91008:112928:1,91012:112933:1,91013:112934:1,91015:112936:2,91017:112938:1,91018:112939:1,91021:112943:1,91022:112944:1,91024:112947:1,91025:112948:1,91026:112949:1,91027:112950:1,91028:112951:1,91030:112953:1,91031:112954:1,91032:112955:1,91033:112956:1,91034:112957:2,91035:112958:1,91036:112959:1,93014:115245:1,93016:115248:1,94899:117496:1,94901:117498:1,94902:117499:1,94904:117501:1,94905:117502:1,94909:117506:1,94912:117509:1,94913:124011:1,94915:117512:1,94916:117513:1,94917:117514:1,94918:117515:1,95147:117754:2,95149:117758:1,95150:117759:1,95152:117762:1,99824:123329:1,109772:136030:1,109773:136031:1,109774:136032:1,110011:136501:1,110427:137049:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 577, 1, 'simc/midnight MID2_Demon_Hunter_Havoc_Fel-Scarred', '90914:112823:1,90921:112830:1,90922:112831:1,90923:112832:1,90925:112834:1,90927:136502:1,90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90939:112850:1,90940:112851:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90993:112911:1,90994:112912:1,90996:112914:1,90997:117755:1,91000:112918:2,91001:112919:1,91002:112921:1,91003:112923:1,91006:112926:1,91007:112927:1,91008:112928:1,91012:112933:1,91013:112934:1,91015:112936:2,91017:112938:1,91018:112939:1,91021:112943:1,91022:112944:1,91024:112947:1,91025:112948:1,91026:112949:1,91027:112950:1,91028:112951:1,91030:112953:1,91031:112954:1,91032:112955:1,91033:112956:1,91034:112957:2,91035:112958:1,91036:112959:1,93014:115245:1,93016:115248:1,94899:117496:1,94901:117498:1,94902:117499:1,94904:117501:1,94905:117502:1,94909:117506:1,94912:117509:1,94913:124011:1,94915:117512:1,94916:117513:1,94917:117514:1,94918:117515:1,95147:117754:2,95149:117758:1,95150:117759:1,95152:117762:1,99824:123329:1,109772:136030:1,109773:136031:1,109774:136032:1,110011:136501:1,110427:137049:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 581, 0, 'Default: simc/midnight MID2_Demon_Hunter_Vengeance_Annihilator', '90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90939:112850:1,90940:112851:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90951:112864:1,90952:112865:1,90955:112868:1,90956:112869:1,90958:112872:2,90959:112873:1,90960:112875:1,90961:112876:1,90962:112877:2,90964:112879:1,90968:112883:1,90970:112886:1,90971:112887:1,90972:112888:1,90974:112890:1,90975:112891:1,90977:112893:1,90978:112894:1,90979:112895:1,90980:112896:1,90981:112897:2,90983:112899:1,90986:112902:1,90987:112903:1,90989:112906:1,90990:112907:1,90991:112908:1,90994:117768:1,90996:112914:2,90999:112917:1,91000:112918:2,91001:112919:1,91002:112921:1,91004:112924:2,94915:117512:1,95149:117758:1,95150:117759:1,95151:117761:1,95152:117762:1,99823:134253:1,108722:134271:1,108728:134281:1,109442:135660:1,109443:135661:1,109444:135662:1,109445:135663:1,109446:135664:1,109447:135665:1,109448:135666:1,109449:135667:1,109450:136810:1,109451:135669:1,109452:135670:1,109453:135671:1,109454:135672:1,109455:135673:1,110010:136500:1,110425:137043:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 581, 1, 'simc/midnight MID2_Demon_Hunter_Vengeance_Annihilator', '90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90939:112850:1,90940:112851:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90951:112864:1,90952:112865:1,90955:112868:1,90956:112869:1,90958:112872:2,90959:112873:1,90960:112875:1,90961:112876:1,90962:112877:2,90964:112879:1,90968:112883:1,90970:112886:1,90971:112887:1,90972:112888:1,90974:112890:1,90975:112891:1,90977:112893:1,90978:112894:1,90979:112895:1,90980:112896:1,90981:112897:2,90983:112899:1,90986:112902:1,90987:112903:1,90989:112906:1,90990:112907:1,90991:112908:1,90994:117768:1,90996:112914:2,90999:112917:1,91000:112918:2,91001:112919:1,91002:112921:1,91004:112924:2,94915:117512:1,95149:117758:1,95150:117759:1,95151:117761:1,95152:117762:1,99823:134253:1,108722:134271:1,108728:134281:1,109442:135660:1,109443:135661:1,109444:135662:1,109445:135663:1,109446:135664:1,109447:135665:1,109448:135666:1,109449:135667:1,109450:136810:1,109451:135669:1,109452:135670:1,109453:135671:1,109454:135672:1,109455:135673:1,110010:136500:1,110425:137043:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 1480, 0, 'Default: simc/midnight MID2_Demon_Hunter_Devourer_Void-Scarred', '90927:112837:1,90929:112839:1,90930:112840:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90937:112848:1,90938:112849:1,90939:112850:1,90940:112851:1,90941:112852:1,90942:112853:1,90949:112862:2,90950:112863:1,90994:112912:1,90996:112914:2,90997:117755:1,91000:112918:2,91002:112921:1,91006:112926:1,91007:112927:1,95149:117758:1,95150:117759:1,95152:117762:1,95154:117767:1,107336:132278:1,107339:132281:1,107340:132282:1,107341:132283:1,107342:132284:1,107343:132285:1,107344:132286:1,107347:132289:1,107770:133106:1,107771:133107:1,107774:133110:1,107775:133111:1,107999:133370:1,108122:133511:1,108123:134331:1,108136:133531:1,108143:133538:2,108144:134330:1,108628:134149:2,108704:136623:1,108723:134272:1,108726:134275:1,108727:134280:1,109449:135667:1,109503:135736:1,109871:136131:2,110009:136499:1,110011:136501:1,110104:136608:1,110105:136607:1,110106:136615:1,110107:136614:1,110108:136609:1,110109:136606:1,110110:136611:1,110111:136610:1,110112:136613:1,110113:136612:1,110114:136619:1,110115:136622:1,110116:136617:1,110117:136618:1,110165:136690:2,110166:136691:1,110167:136692:1,110168:136693:1,110170:136695:1,110171:136696:1,110173:136698:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 1480, 1, 'simc/midnight MID2_Demon_Hunter_Devourer_Void-Scarred', '90927:112837:1,90929:112839:1,90930:112840:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90937:112848:1,90938:112849:1,90939:112850:1,90940:112851:1,90941:112852:1,90942:112853:1,90949:112862:2,90950:112863:1,90994:112912:1,90996:112914:2,90997:117755:1,91000:112918:2,91002:112921:1,91006:112926:1,91007:112927:1,95149:117758:1,95150:117759:1,95152:117762:1,95154:117767:1,107336:132278:1,107339:132281:1,107340:132282:1,107341:132283:1,107342:132284:1,107343:132285:1,107344:132286:1,107347:132289:1,107770:133106:1,107771:133107:1,107774:133110:1,107775:133111:1,107999:133370:1,108122:133511:1,108123:134331:1,108136:133531:1,108143:133538:2,108144:134330:1,108628:134149:2,108704:136623:1,108723:134272:1,108726:134275:1,108727:134280:1,109449:135667:1,109503:135736:1,109871:136131:2,110009:136499:1,110011:136501:1,110104:136608:1,110105:136607:1,110106:136615:1,110107:136614:1,110108:136609:1,110109:136606:1,110110:136611:1,110111:136610:1,110112:136613:1,110113:136612:1,110114:136619:1,110115:136622:1,110116:136617:1,110117:136618:1,110165:136690:2,110166:136691:1,110167:136692:1,110168:136693:1,110170:136695:1,110171:136696:1,110173:136698:1', 'https://github.com/simulationcraft/simc/tree/midnight/profiles/simc_mid2');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1467, 0, 'Default: method.gg Scalecommander Single Target', '93272:115578:1,93273:115579:1,93274:115580:2,93275:115581:1,93280:115587:1,93281:115588:2,93284:115592:1,93285:115593:1,93288:115596:1,93289:115597:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93313:115623:1,93314:115624:1,93316:115627:1,93318:115629:1,93319:115631:1,93322:115634:1,93323:115635:1,93324:115636:1,93325:115637:1,93326:115638:1,93327:115639:1,93328:115640:1,93329:115641:2,93330:115642:1,93331:115643:1,93332:115645:1,93333:115646:1,93334:115647:1,93340:115654:1,93341:115655:1,93342:115656:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93366:115683:1,93715:116103:1,94921:117518:1,94928:120124:1,94933:117530:1,94934:117531:1,94936:117533:1,94939:117536:1,94941:117538:1,94943:120123:1,94944:117541:1,94952:117549:1,94953:117550:1,99827:123333:1,103843:128216:1,103844:128217:1,109793:136051:1,109794:136052:1,109795:136053:1,110064:136559:1,110414:137010:1', 'https://www.method.gg/guides/devastation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1467, 1, 'method.gg Scalecommander Single Target', '93272:115578:1,93273:115579:1,93274:115580:2,93275:115581:1,93280:115587:1,93281:115588:2,93284:115592:1,93285:115593:1,93288:115596:1,93289:115597:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93313:115623:1,93314:115624:1,93316:115627:1,93318:115629:1,93319:115631:1,93322:115634:1,93323:115635:1,93324:115636:1,93325:115637:1,93326:115638:1,93327:115639:1,93328:115640:1,93329:115641:2,93330:115642:1,93331:115643:1,93332:115645:1,93333:115646:1,93334:115647:1,93340:115654:1,93341:115655:1,93342:115656:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93366:115683:1,93715:116103:1,94921:117518:1,94928:120124:1,94933:117530:1,94934:117531:1,94936:117533:1,94939:117536:1,94941:117538:1,94943:120123:1,94944:117541:1,94952:117549:1,94953:117550:1,99827:123333:1,103843:128216:1,103844:128217:1,109793:136051:1,109794:136052:1,109795:136053:1,110064:136559:1,110414:137010:1', 'https://www.method.gg/guides/devastation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1468, 0, 'Default: method.gg Raiding Flameshaper Hero Talents (Recommended)', '93238:115540:1,93239:115541:1,93240:115542:1,93241:115543:1,93242:115544:1,93245:115549:1,93246:115550:2,93247:115551:2,93248:115552:1,93250:115554:1,93251:115555:1,93253:115557:1,93255:115559:1,93257:115561:1,93258:115562:1,93260:115565:1,93263:115568:2,93264:115570:1,93265:115571:1,93266:115572:1,93267:133527:1,93268:115574:2,93271:115577:1,93288:115596:1,93289:115597:1,93291:115599:1,93292:115600:2,93294:115602:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93336:115650:1,93337:115651:1,93338:115652:1,93339:115653:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93347:115662:2,93348:115663:1,93350:115665:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93715:116103:1,94920:117517:1,94922:117519:1,94923:117520:1,94931:117528:1,94937:117534:1,94945:117542:1,94946:117543:1,94949:117546:1,94950:117547:1,94954:117551:1,94956:128713:1,99826:123332:1,99857:123416:1,103843:128216:1,109796:136054:1,109797:136055:1,109798:136056:1,110064:136559:1,110413:137007:1', 'https://www.method.gg/guides/preservation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1468, 1, 'method.gg Raiding Flameshaper Hero Talents (Recommended)', '93238:115540:1,93239:115541:1,93240:115542:1,93241:115543:1,93242:115544:1,93245:115549:1,93246:115550:2,93247:115551:2,93248:115552:1,93250:115554:1,93251:115555:1,93253:115557:1,93255:115559:1,93257:115561:1,93258:115562:1,93260:115565:1,93263:115568:2,93264:115570:1,93265:115571:1,93266:115572:1,93267:133527:1,93268:115574:2,93271:115577:1,93288:115596:1,93289:115597:1,93291:115599:1,93292:115600:2,93294:115602:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93336:115650:1,93337:115651:1,93338:115652:1,93339:115653:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93347:115662:2,93348:115663:1,93350:115665:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93715:116103:1,94920:117517:1,94922:117519:1,94923:117520:1,94931:117528:1,94937:117534:1,94945:117542:1,94946:117543:1,94949:117546:1,94950:117547:1,94954:117551:1,94956:128713:1,99826:123332:1,99857:123416:1,103843:128216:1,109796:136054:1,109797:136055:1,109798:136056:1,110064:136559:1,110413:137007:1', 'https://www.method.gg/guides/preservation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1473, 0, 'Default: method.gg Raid Single Target (Chronowarden)', '93195:115493:1,93198:115496:1,93199:115690:1,93200:115498:1,93201:115499:1,93202:115500:1,93203:115502:1,93205:115504:1,93206:115505:1,93207:115506:1,93208:115507:1,93212:115512:1,93213:115513:1,93218:115518:1,93219:115519:1,93220:115520:1,93221:115521:1,93222:115522:1,93223:115523:1,93226:115527:1,93227:115528:1,93229:115530:1,93230:115531:1,93232:115533:1,93234:115536:1,93235:115706:1,93287:115595:1,93288:115596:1,93289:115597:1,93292:115600:2,93294:115602:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93354:115669:1,93355:115670:2,93358:115675:1,93367:115685:1,93368:115688:1,93715:116103:1,94925:117522:1,94929:117526:1,94930:126310:1,94932:117529:1,94935:117532:1,94942:117539:1,94947:117544:1,94948:117545:1,94951:117548:1,94954:117551:1,94955:117552:1,99825:123334:1,102248:126304:1,103843:128216:1,109508:135741:1,109509:135742:1,109510:135743:1,110415:137013:1', 'https://www.method.gg/guides/augmentation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1473, 1, 'method.gg Raid Single Target (Chronowarden)', '93195:115493:1,93198:115496:1,93199:115690:1,93200:115498:1,93201:115499:1,93202:115500:1,93203:115502:1,93205:115504:1,93206:115505:1,93207:115506:1,93208:115507:1,93212:115512:1,93213:115513:1,93218:115518:1,93219:115519:1,93220:115520:1,93221:115521:1,93222:115522:1,93223:115523:1,93226:115527:1,93227:115528:1,93229:115530:1,93230:115531:1,93232:115533:1,93234:115536:1,93235:115706:1,93287:115595:1,93288:115596:1,93289:115597:1,93292:115600:2,93294:115602:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93354:115669:1,93355:115670:2,93358:115675:1,93367:115685:1,93368:115688:1,93715:116103:1,94925:117522:1,94929:117526:1,94930:126310:1,94932:117529:1,94935:117532:1,94942:117539:1,94947:117544:1,94948:117545:1,94951:117548:1,94954:117551:1,94955:117552:1,99825:123334:1,102248:126304:1,103843:128216:1,109508:135741:1,109509:135742:1,109510:135743:1,110415:137013:1', 'https://www.method.gg/guides/augmentation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 71, 2, 'M+: method.gg Slayer - AoE / Mythic+', '90267:135932:1,90269:112121:1,90270:112122:1,90271:112123:1,90273:112125:1,90274:112126:1,90276:112128:1,90279:112131:1,90282:112134:1,90285:112137:1,90290:112144:1,90291:112145:1,90292:112146:1,90293:112147:1,90322:112179:2,90326:112183:1,90327:112184:1,90328:112185:1,90331:112188:1,90332:112190:1,90337:112198:1,90344:112206:1,90346:112208:1,90347:112209:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90438:112310:1,90441:112314:1,90444:112317:2,90445:112318:1,90447:112320:2,92536:114739:1,92537:114643:1,94784:117381:1,94786:117383:1,94787:123770:1,94788:117385:1,94795:117392:1,94801:117398:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94818:117415:1,94820:117417:1,95956:118850:1,99853:123390:1,108542:134031:1,108543:134032:1,108544:134033:1,108685:134225:1,108705:136627:1,109391:135597:1,109682:135937:1,109683:135939:1,109684:135940:1,109685:135941:1,109686:135942:1,109687:135944:2,109815:136074:1,109816:136075:1,109817:136076:1,110119:136626:1,110176:136703:1,110407:136989:1', 'https://www.method.gg/guides/arms-warrior/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 72, 2, 'M+: method.gg Slayer: AoE/Mythic+', '90325:112182:1,90326:112183:1,90328:112185:1,90331:112188:1,90344:112206:1,90346:112208:1,90347:112209:1,90348:112210:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90373:112240:2,90375:112242:1,90378:112245:1,90381:112248:2,90382:112249:1,90385:112253:1,90388:119139:1,90390:112259:1,90392:112261:1,90394:112263:1,90396:112265:1,90397:112266:2,90398:112267:1,90399:112268:1,90401:112270:1,90402:112271:1,90403:112272:1,90406:112275:1,90408:112277:1,90410:112279:1,90412:112281:1,90415:112284:1,90421:112292:2,90427:112298:1,90428:112299:2,90429:112300:1,90430:112301:1,92538:114644:1,94784:117381:1,94786:117383:1,94787:117384:1,94788:117385:1,94795:117392:1,94801:117398:1,94803:117400:1,94809:117406:1,94810:117407:1,94813:117410:1,94814:117411:1,94820:117417:1,95956:118850:1,99852:123389:1,108543:134032:1,108544:134033:1,108674:134213:1,108686:134226:1,109815:136074:1,109816:136075:1,109817:136076:1,109963:136448:1,109966:136451:1,109967:136452:1,109968:136453:1,109969:136454:1,110118:136625:1,110119:136626:1,110330:136890:1', 'https://www.method.gg/guides/fury-warrior/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (1, 73, 2, 'M+: method.gg Mythic+ Standard', '90261:112112:1,90264:112115:1,90265:112116:1,90295:112149:1,90297:112151:1,90298:112152:1,90300:112154:1,90302:112156:1,90303:112157:1,90304:112158:1,90305:112159:1,90306:112160:1,90308:112162:1,90309:112163:1,90311:112166:2,90312:132885:1,90314:112170:1,90315:112171:1,90317:112173:1,90318:112174:1,90319:112176:1,90320:112177:1,90324:112181:2,90326:112183:1,90328:112185:1,90330:112187:1,90331:112188:1,90337:112198:1,90343:112205:1,90346:112208:1,90347:112209:1,90351:112215:1,90352:112216:1,90353:112217:1,90355:112219:1,90360:112224:2,90366:112233:2,90368:112235:2,90371:112238:1,90375:112242:1,90381:112248:2,90382:112249:1,90385:112253:1,90432:112304:1,90433:112305:1,90434:112306:1,90435:112307:1,90449:112323:1,90451:112325:1,94785:117382:1,94792:118834:1,94797:117394:1,94798:117395:1,94800:117397:1,94803:117400:1,94805:117402:1,94807:117404:1,94808:117405:1,94816:117413:1,94817:118835:1,94818:117415:1,95956:118850:1,95959:118853:1,99851:123388:1,107577:132882:1,107579:132886:1,108542:134031:1,108543:134032:1,108544:134033:1,108685:134225:1,108705:136627:1,109809:136068:1,109810:136069:1,109811:136070:1,110119:136626:1,110411:137001:1,110653:137471:1', 'https://www.method.gg/guides/protection-warrior/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 65, 2, 'M+: method.gg Mythic+ Build', '81496:102465:1,81508:102477:1,81510:133481:1,81543:102518:1,81554:102533:1,81555:102534:1,81557:102536:1,81558:102537:1,81560:102539:1,81561:102540:1,81562:102541:1,81564:102544:1,81565:102545:1,81567:102548:1,81568:102549:1,81569:102550:1,81570:102551:1,81571:102553:1,81578:102562:1,81580:102564:1,81584:102569:1,81585:102570:1,81588:133501:1,81590:102575:1,81591:102577:1,81592:102578:1,81594:102580:1,81597:102583:1,81598:102584:1,81600:102587:1,81605:102592:1,81609:102597:1,81613:102601:1,81614:102602:1,81615:102603:1,81616:102604:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92220:114292:1,93009:115034:2,93180:115465:1,93191:128246:1,93520:115872:1,93521:115873:1,93522:115874:1,93523:115875:1,93927:116376:1,95069:117666:1,95071:117668:1,95072:117669:1,95073:117778:1,95080:117677:1,95086:117683:1,95094:117691:1,95095:117692:1,95098:117777:1,95099:117696:1,95105:117702:1,99839:123362:1,102502:126571:1,103851:128241:2,103852:128242:1,103853:128245:1,103856:128309:1,103858:128254:1,103863:128259:1,103864:128260:1,103866:128262:1,108034:133407:1,108099:133479:1,109748:136006:1,109749:136007:1,109750:136008:1,109998:136486:1,109999:136487:1,110012:136503:1,110092:136593:1,110257:136795:1,110417:137019:1', 'https://www.method.gg/guides/holy-paladin/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 66, 2, 'M+: method.gg Lightsmith (Mythic+)', '81469:102430:1,81471:102433:2,81476:137505:1,81477:102440:1,81479:102443:1,81481:102445:1,81483:102448:1,81484:102449:1,81486:102452:1,81487:102453:1,81488:137858:1,81489:102455:1,81490:102456:1,81491:102457:1,81492:102459:1,81493:102461:1,81494:102463:1,81495:102464:1,81497:102466:1,81499:102468:1,81502:102471:1,81503:102472:1,81504:102473:1,81505:102474:1,81506:102475:1,81507:102476:1,81510:133481:1,81543:102518:1,81597:102583:1,81598:102584:1,81600:102587:1,81603:102590:1,81604:102591:1,81605:102592:1,81607:102595:1,81608:102596:1,81609:102597:1,81612:102600:1,81614:102602:1,81615:102603:1,81616:102604:1,81621:102612:2,81628:102620:1,81630:102622:2,81631:128251:1,81632:102625:1,90062:137855:1,93009:115034:2,93165:115444:1,93187:115479:1,93192:128244:1,95180:117813:1,95228:117873:1,95229:117874:1,95230:117875:1,95231:117877:1,95232:117878:1,95233:117881:1,95234:117882:1,95235:117884:1,95236:117885:1,95237:117886:1,95238:117887:1,99838:123361:1,101927:102454:1,101928:102434:1,103851:128241:2,103863:128259:1,103864:128260:1,103867:128263:1,103877:128278:1,109742:136000:1,109743:136001:1,109744:136002:1,109999:136487:1,110006:136496:1,110012:136503:1,110257:136795:1,110418:137022:1,110862:111886:1', 'https://www.method.gg/guides/protection-paladin/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (2, 70, 2, 'M+: method.gg Templar (Raid Cleave & Mythic+)', '81507:102476:1,81510:133481:1,81512:115475:1,81521:114828:1,81523:102493:1,81525:102497:1,81526:102498:1,81527:102499:1,81532:102504:1,81533:102505:1,81534:102506:1,81541:102515:1,81542:102516:1,81543:102518:1,81544:102519:1,81545:102521:1,81597:102583:1,81598:102584:1,81600:102587:1,81603:102590:1,81605:102592:1,81608:102596:1,81609:102597:1,81614:102602:1,81615:102603:1,81616:102604:1,81618:128243:1,81621:102612:2,81630:102622:2,81631:128251:1,81632:102625:1,92686:114824:1,92689:114830:1,92838:115022:1,92839:115024:1,92854:115043:1,92952:115165:2,93009:115034:2,93160:115439:2,93164:115443:2,93173:115453:1,93174:115454:1,93181:115467:1,93189:115481:1,95099:117696:1,95177:117810:1,95178:117811:1,95179:117812:1,95180:117813:1,95181:117858:1,95182:117815:1,95183:117816:1,95184:117818:1,95185:117819:1,95186:117822:1,95187:117823:1,99837:123357:1,103851:128241:2,103861:128257:1,103863:128259:1,103864:128260:1,103867:128263:1,109368:135564:1,109369:135565:1,109371:115438:1,109372:115452:1,109373:115435:1,109374:136809:1,109745:136003:1,109746:136004:1,109747:136005:1,109867:136127:1,109999:136487:1,110012:136503:1,110091:136592:1,110093:136594:1,110419:137025:1', 'https://www.method.gg/guides/retribution-paladin/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 253, 2, 'M+: method.gg Pack Leader AoE / Mythic+ (Recommended)', '94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94979:123781:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99832:123347:1,102292:126352:1,102336:126397:2,102338:126399:1,102340:126402:1,102341:126403:1,102342:126404:1,102343:126405:1,102344:126406:1,102345:126407:2,102346:126408:1,102347:126409:1,102353:126415:1,102354:126416:1,102355:126417:1,102356:126418:1,102357:126419:1,102358:126420:1,102360:126422:1,102362:126424:1,102363:126425:1,102368:126431:1,102369:126432:1,102370:126433:1,102372:126435:1,102373:126436:1,102374:126437:1,102377:126440:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102389:126452:1,102390:126453:1,102391:126454:1,102394:135704:1,102395:126459:1,102396:126460:2,102397:126461:1,102401:126465:2,102406:126470:1,102409:126473:2,102411:126475:1,102415:126480:1,102416:126481:2,102422:126488:1,102423:126489:1,102424:126490:1,109483:135705:1,109484:135706:1,109485:135708:1,109487:135710:2,109488:135711:1,109489:135712:1,109802:136060:1,109803:136061:1,109804:136236:1,109961:136446:1,110157:136677:1,110158:136679:1,110164:136685:1,110428:137052:1,110692:126400:1', 'https://www.method.gg/guides/beast-mastery-hunter/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 254, 2, 'M+: method.gg Sentinel AoE / Trick Shots (Recommended)', '94958:117555:1,94965:117562:1,94970:117567:1,94971:117568:1,94973:117570:1,94976:117573:1,94978:117575:1,94980:117577:1,94981:117578:1,94989:117586:1,94990:117587:1,99831:123345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102389:126452:1,102390:126453:1,102391:126454:1,102395:126459:1,102396:126460:2,102401:126465:2,102402:126466:1,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103947:128367:1,103956:128376:1,103957:128378:1,103958:132194:1,103959:128380:1,103960:128381:1,103961:128383:1,103962:128384:1,103964:128386:1,103966:128388:1,103974:128396:1,103975:128397:1,103977:128399:1,103978:128400:2,103979:128401:1,103982:128404:1,103984:128406:1,103985:128407:1,103986:128408:1,103990:128413:1,104095:128609:1,104127:128710:1,104130:128717:1,107288:132192:1,107289:132193:1,109483:135705:1,109484:135706:1,109485:135708:1,109487:135710:2,109488:135711:1,109805:136063:1,109807:136065:1,109961:136446:1,110028:136521:1,110152:136670:1,110157:136677:1,110164:136685:1,110430:137058:1,110572:137375:1,110573:137635:1,110574:137377:1,110575:137378:1,110691:137506:1', 'https://www.method.gg/guides/marksmanship-hunter/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (3, 255, 2, 'M+: method.gg Pack Leader AoE', '79837:100543:1,94962:117559:1,94966:117563:1,94967:117564:1,94969:117566:1,94972:117569:1,94976:117573:1,94979:117576:1,94984:117581:1,94985:117582:1,94988:117585:1,94991:117588:1,94992:117589:1,99833:123350:1,102255:126314:1,102257:126316:1,102262:126322:1,102263:126323:1,102264:126324:1,102268:126328:1,102270:126330:1,102272:126332:1,102279:126339:1,102282:126342:1,102285:126345:1,102380:126443:1,102381:126444:1,102384:126447:2,102387:126450:1,102389:126452:1,102390:126453:1,102391:126454:1,102393:126457:1,102394:135704:1,102395:126459:1,102396:126460:2,102401:126465:2,102404:126468:1,102406:126470:1,102409:126473:2,102411:126475:1,102416:126481:2,102419:126484:1,102422:126488:1,102423:126489:1,102424:126490:1,103989:128412:1,109304:135495:1,109305:135496:1,109307:135498:1,109309:135500:1,109310:135501:1,109311:135502:1,109312:135503:2,109313:135504:1,109316:135507:1,109320:135511:2,109321:135512:1,109323:135514:1,109324:135515:1,109485:135708:1,109487:135710:2,109489:135712:1,109802:136060:1,109803:136061:1,109804:136236:1,110156:136676:1,110157:136677:1,110159:136680:1,110161:136682:1,110162:136683:1,110163:136684:1,110164:136685:1,110429:137055:1', 'https://www.method.gg/guides/survival-hunter/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (4, 259, 2, 'M+: method.gg Mythic+ / Open World', '90624:112509:2,90625:112510:1,90626:112511:1,90628:112513:1,90630:112515:1,90633:112518:1,90634:112519:1,90636:112521:1,90640:112526:1,90684:112572:1,90686:112574:1,90687:112575:1,90692:117152:1,90695:112583:1,90697:112585:1,90740:112630:1,90742:114737:1,90743:112633:1,90744:112634:1,90745:112635:1,90746:112636:1,90747:112638:1,90748:112639:1,90749:112640:2,90750:112642:1,90751:112643:2,90752:112644:1,90754:112646:1,90756:112648:1,90757:112649:1,90758:112650:1,90759:112651:2,90760:112652:1,90762:112654:1,90763:112655:1,90764:112657:1,90766:112659:2,90767:112660:1,90768:112661:1,90769:112662:1,90770:112663:1,90771:112664:1,90772:112665:1,90775:112668:2,90776:112669:1,90779:112672:1,90780:112673:1,90783:112676:1,90785:112678:2,94536:117106:1,94553:117131:1,94554:117133:1,94555:117135:1,94557:117139:1,94562:117145:1,95106:126029:1,95108:117705:1,95109:117706:1,95110:117707:1,95117:117714:1,95123:117720:1,95125:117722:1,95131:117728:1,95132:117729:1,95135:117732:1,95136:117733:1,95142:117739:1,99844:123375:1,101714:125615:1,109760:136018:1,109761:136019:1,109762:136020:1,110323:136881:1,110325:136883:1,110433:137067:1', 'https://www.method.gg/guides/assassination-rogue/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 256, 2, 'M+: method.gg Mythic+ Voidweaver (Recommended)', '82556:103834:1,82564:116182:1,82567:103692:1,82568:103693:1,82569:103694:1,82570:103695:1,82571:136829:1,82575:103700:1,82577:103702:1,82579:103704:1,82580:103705:1,82581:103706:1,82582:103708:1,82583:103709:2,82587:103713:1,82588:103714:1,82592:103721:1,82593:103722:1,82594:103723:1,82595:103724:1,82596:103725:1,82597:103726:1,82598:103727:1,82599:103728:1,82600:103729:2,82672:103818:1,82673:103819:1,82676:115884:1,82677:103823:1,82678:103825:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82697:103847:2,82701:103851:1,82702:103852:1,82703:103853:1,82710:103678:1,82712:103864:1,82713:103865:1,82715:103867:1,82716:103868:1,82717:103869:1,86730:103688:1,94668:117271:1,94669:117272:1,94670:117273:1,94683:117286:1,94692:117295:1,94693:123845:1,94694:117297:1,94695:125982:1,94696:123844:1,94703:117306:1,99801:123288:1,100212:123841:1,108731:134284:1,109006:103841:1,109009:103677:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109020:134859:1,109021:134860:1,109778:136036:1,109779:136037:1,109780:136038:1,109890:136157:1,109917:136185:1,110008:136498:1,110277:136828:1,110278:136830:1,110410:136998:1,110648:137463:1', 'https://www.method.gg/guides/discipline-priest/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 257, 2, 'M+: method.gg Mythic+ Archon (Recommended)', '82554:103675:1,82556:103834:1,82603:103734:1,82604:128613:1,82607:103739:1,82610:103743:1,82612:103745:1,82613:103747:1,82614:103748:1,82620:103754:1,82621:103755:1,82622:103756:1,82623:103757:1,82627:103762:1,82628:103763:1,82630:103765:1,82631:103766:1,82632:103767:1,82633:103769:1,82634:103770:1,82636:103773:1,82637:103774:1,82638:103775:1,82639:103776:1,82640:103777:1,82641:103779:1,82642:103780:1,82672:103818:1,82675:103821:1,82676:115884:1,82677:103823:1,82678:103825:1,82682:103831:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82696:103846:1,82697:103847:2,82701:103851:1,82702:103852:1,82703:103853:1,82710:103678:1,82715:103867:1,82716:103868:1,82717:103869:1,82718:103870:1,94676:117279:1,94677:117280:1,94678:125085:1,94680:117283:1,94681:117284:1,94683:117286:1,94685:117288:1,94686:125083:1,94688:117291:1,94699:117302:1,94702:117305:1,99802:123291:1,103900:103733:1,103914:128331:2,104097:128612:1,108724:134273:1,108730:134283:1,108731:134284:1,109006:103841:1,109009:103677:1,109010:134844:2,109012:134846:1,109015:134849:1,109020:134859:1,109021:134860:1,109775:136688:1,109776:136034:1,109777:136035:1,109890:136157:1,110409:136995:1', 'https://www.method.gg/guides/holy-priest/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (5, 258, 2, 'M+: method.gg Archon Mythic+', '82552:103781:1,82555:103817:1,82556:103834:1,82560:103683:2,82563:103686:1,82645:103784:2,82646:103785:1,82647:103786:1,82649:103789:2,82651:103792:1,82654:103796:1,82655:103797:1,82656:134052:1,82657:103674:1,82659:103801:1,82662:103805:1,82663:103806:1,82665:103808:1,82666:103809:1,82667:103811:1,82668:103812:1,82670:103814:1,82672:103818:1,82673:103819:1,82676:135091:1,82677:103823:1,82678:103825:1,82679:103826:1,82680:103828:1,82684:103833:2,82685:103835:1,82686:103836:2,82687:103837:1,82690:103840:1,82695:114588:1,82701:103851:1,82703:103853:1,82704:103854:1,82708:103860:1,82711:103863:1,82712:103864:1,82713:103865:1,82715:103867:1,93170:103810:1,93171:115448:1,94676:117279:1,94677:117280:1,94678:125085:1,94680:117283:1,94681:117284:1,94685:117288:1,94686:125083:1,94688:117291:1,94697:117300:1,94699:117302:1,94702:117305:1,99800:123289:1,108007:133378:1,108029:133400:1,108031:134051:1,108731:134284:1,109006:103841:1,109009:103677:1,109010:134844:2,109011:134845:1,109012:134846:1,109015:134849:1,109017:136223:1,109020:134859:1,109021:134860:1,109775:136688:1,109776:136034:1,109777:136035:1,109890:136157:1,109917:136185:1,110408:136992:1', 'https://www.method.gg/guides/shadow-priest/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 250, 2, 'M+: method.gg San’layn Mythic+', '76039:96167:1,76040:96168:1,76041:96169:1,76042:96170:1,76043:96171:1,76044:96172:1,76045:96173:1,76046:96174:1,76048:96176:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76056:96184:1,76057:96186:1,76058:96187:1,76061:96190:1,76064:96193:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76076:96205:1,76079:96208:2,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76125:96256:1,76126:96257:2,76128:96259:1,76129:96260:1,76130:96261:1,76131:96262:1,76132:96263:1,76133:96264:1,76135:96266:1,76137:96268:1,76138:96269:1,76141:96273:1,76142:96274:1,76144:96277:1,76166:96301:1,76167:96302:1,76168:96303:1,76169:96304:1,76170:96305:1,76171:96306:1,76172:96307:1,76173:96308:1,95033:117630:1,95040:117637:1,95045:117642:1,95046:117643:1,95048:117645:1,95051:117648:1,95053:117650:1,95055:117652:1,95056:117653:1,95062:117659:1,95064:117661:1,95065:117662:1,99822:123325:1,102007:126015:1,102008:126016:1,102242:126296:1,102243:126298:1,109736:135994:1,109737:135995:1,109738:135996:1,110030:136524:1,110353:136917:1', 'https://www.method.gg/guides/blood-death-knight/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 251, 2, 'M+: method.gg [Mythic+] Frostbane', '76033:96161:2,76044:96172:1,76045:96173:1,76046:96174:1,76051:96179:1,76052:96180:2,76054:96182:2,76055:96183:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76075:96204:1,76076:96205:1,76078:96207:1,76079:96208:2,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76091:96220:1,76093:96222:1,76096:96225:1,76098:96228:1,76099:96229:1,76101:96231:1,76106:96236:1,76108:96238:1,76109:96239:1,76110:96240:1,76112:96242:1,76113:96243:1,76114:96244:1,76115:96245:1,76116:96246:1,76117:96247:1,76118:96248:1,76121:96252:1,76122:96253:2,76123:96254:1,95032:117629:1,95034:117631:1,95035:123420:1,95036:117633:1,95043:117640:1,95049:117646:1,95057:117654:1,95058:117655:1,95061:117658:1,95062:117659:1,95066:117663:1,95068:117665:1,99821:123324:1,101929:125874:1,101930:125875:1,101931:125876:1,101933:125878:1,102007:126015:1,102008:126016:1,102009:126017:1,106790:131618:1,109258:133362:1,109733:135991:1,109734:135992:1,109735:135993:1,110029:136523:1,110030:136524:1,110031:136525:1,110400:136968:1', 'https://www.method.gg/guides/frost-death-knight/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (6, 252, 2, 'M+: method.gg [Mythic+] San’layn Pets', '76044:96172:1,76045:96173:1,76046:96174:1,76051:96179:1,76052:96180:2,76054:96182:2,76056:96184:1,76058:96187:1,76061:96190:1,76064:136526:1,76065:96194:1,76066:96195:1,76067:96196:1,76068:96197:1,76069:96198:2,76071:96200:1,76072:96201:1,76073:96202:1,76074:96203:1,76075:96204:1,76076:96205:1,76078:96207:1,76079:96208:2,76081:96210:1,76084:96213:1,76085:96214:1,76087:96216:1,76148:96282:1,76149:96283:2,76150:96284:2,76155:96289:1,76162:96296:1,76176:96311:1,76178:96313:1,76179:96314:1,76182:96318:1,76184:96321:1,76185:96322:1,76186:133365:1,76189:96326:1,76190:96327:1,76191:96328:1,76193:96330:1,76194:96331:1,76196:96333:1,76197:96334:1,95033:117630:1,95040:117637:1,95045:117642:1,95046:117643:1,95048:136836:1,95051:117648:1,95053:117650:1,95055:117652:1,95056:117653:1,95064:117892:1,95065:117662:1,95066:117663:1,99820:123321:1,101882:125815:1,102007:126015:1,102008:126016:1,108126:133515:1,108129:133522:1,108130:125816:1,108131:133523:1,108151:133546:1,109392:133517:1,109458:135676:1,109736:135994:1,109737:135995:1,109738:135996:1,110029:136523:1,110031:136525:1,110260:136797:1,110354:136920:1', 'https://www.method.gg/guides/unholy-death-knight/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 262, 2, 'M+: method.gg Farseer Mythic+', '80978:101844:1,80981:101850:1,80983:101853:1,80984:127924:1,80985:101855:1,80988:101859:1,80989:101860:1,80990:101861:1,80992:101864:1,80995:101867:1,80997:101870:1,80998:101871:1,80999:101872:1,81000:101874:1,81002:101876:1,81004:101879:1,81007:101883:1,81008:101885:1,81015:101892:1,94858:117455:1,94860:117457:1,94861:117458:1,94862:123632:1,94869:117466:1,94875:117472:1,94883:117480:1,94884:123630:1,94887:117484:1,94888:117485:1,94892:117489:1,94894:117491:1,99845:123377:1,103579:127851:1,103581:127854:1,103582:127855:2,103583:127856:1,103584:127857:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127864:1,103593:127868:1,103596:127871:1,103598:127873:1,103599:136567:1,103602:127877:1,103605:127880:1,103606:127881:1,103607:127882:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103624:127905:1,103625:127906:1,103626:127908:1,103627:127909:1,103628:127910:1,103630:127912:1,103631:127913:1,103632:127914:2,103633:127915:1,103635:127917:1,103637:101884:1,103638:127919:1,103639:127920:1,103640:127921:1,109387:135591:1,109388:135592:1,109730:135988:1,109731:135989:1,109732:135990:1,110066:136561:1,110085:136585:1,110402:136974:1', 'https://www.method.gg/guides/elemental-shaman/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 263, 2, 'M+: method.gg Mythic+ Stormbringer', '80938:101801:1,80939:101802:1,80941:101804:1,80942:101805:1,80943:101806:1,80944:101808:1,80949:101813:1,80950:101814:2,80951:101815:1,80953:101818:1,80954:101819:1,80958:101823:1,80959:101824:1,80960:101825:1,80961:101826:1,80962:101827:1,80967:101832:1,80968:101833:1,80969:101834:1,80973:101839:1,80974:101840:1,92219:114291:1,94863:128226:1,94867:117464:1,94868:117465:1,94870:117467:1,94873:128225:1,94877:117474:1,94880:117477:1,94885:117482:1,94886:117483:1,94889:117486:1,94892:117489:1,94893:117490:1,99847:123381:1,103579:127851:1,103581:127853:1,103582:127855:2,103583:127856:1,103585:127858:1,103586:127859:1,103588:127861:1,103591:127865:1,103593:127868:1,103594:127869:1,103596:127871:1,103599:136567:1,103602:127877:1,103605:127880:1,103606:127881:1,103608:127884:1,103611:127888:1,103612:127889:1,103613:127890:1,103614:127891:2,103615:127892:1,103616:127893:1,103617:127894:2,103618:127896:2,103622:127902:1,103624:127905:1,103625:127906:1,103627:127909:1,103642:101799:1,103871:128270:1,109190:135252:1,109192:135254:1,109193:135255:1,109194:128236:1,109387:135591:1,109389:135593:1,109727:135985:1,109728:135986:1,109729:135987:1,109909:136176:1,110085:136585:1,110401:136971:1', 'https://www.method.gg/guides/enhancement-shaman/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (7, 264, 2, 'M+: method.gg Mythic+ Totemic (Recommended)', '80976:101842:1,81018:101895:1,81021:101899:1,81022:101900:1,81024:101902:1,81027:101905:1,81031:101911:1,81032:135486:1,81033:101913:1,81037:101919:1,81039:101922:1,81040:101923:1,81041:101924:1,81042:101925:1,81044:101928:1,81047:101932:1,81048:101934:1,81049:101935:1,81050:101936:1,81051:101937:1,81055:101942:1,81073:101964:1,92675:114811:1,92677:114813:1,94859:117456:1,94866:125824:1,94871:117468:1,94872:117469:1,94874:117471:1,94877:117474:1,94879:117476:1,94881:125822:1,94882:117479:1,94888:117485:1,94890:117487:1,94891:117488:1,99846:123378:1,103428:127672:1,103429:127673:2,103432:127678:1,103433:127679:1,103579:127851:1,103581:127853:1,103582:127855:2,103583:127856:1,103584:127857:1,103586:127859:1,103588:127861:1,103590:127863:1,103591:127864:1,103593:127868:1,103594:127869:1,103596:127871:1,103598:127873:1,103599:136567:1,103601:127876:1,103602:127877:1,103606:127881:1,103607:127882:1,103611:127888:1,103613:127890:1,103615:127892:1,103616:127893:1,103617:127894:2,103620:127899:1,103624:127905:1,103625:127906:1,103626:127908:1,103627:127909:1,103628:127910:1,103915:128332:1,109386:135590:1,109387:135591:1,109388:135592:1,109724:135982:1,109725:135983:1,109726:135984:1,110403:136977:1,113376:140663:1', 'https://www.method.gg/guides/restoration-shaman/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 62, 2, 'M+: method.gg Spellslinger Arcane Mythic+ / Raid Cleave Build', '62084:80140:1,62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:2,62104:80161:1,62105:80163:1,62114:80173:2,62115:80174:1,62121:80180:1,62122:80181:1,62123:80182:2,62124:80183:1,62127:80187:1,93524:115877:1,94647:117250:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99830:123344:1,101883:125818:1,102438:126508:1,102445:126515:1,102446:126516:1,102449:126519:1,102451:126521:1,102460:134025:1,102465:134020:1,102467:126537:1,102468:126538:1,102470:126540:1,102471:126541:1,102474:126544:1,102475:126545:1,102480:126550:2,104113:128689:1,108535:134023:2,108536:134024:1,108537:134026:2,108538:134027:1,108539:134028:1,108541:134030:1,108654:134183:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108662:134192:2,108664:134194:1,108665:134196:1,109002:134834:1,109478:135698:1,109667:135918:1,109668:135919:1,109669:135946:1,110080:136578:1,110081:136579:1,110420:137028:1,110442:137084:1,110597:137410:1,110849:137841:1,110850:137842:1', 'https://www.method.gg/guides/arcane-mage/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (8, 64, 2, 'M+: method.gg Spellslinger Mythic+ Build', '62084:80140:1,62085:80141:1,62086:80142:1,62091:80147:1,62094:126060:1,62096:80153:1,62098:80155:1,62100:80157:1,62102:80159:1,62104:80161:1,62105:80163:1,62114:80173:2,62115:80174:1,62116:80175:1,62117:80176:1,62122:80181:1,62123:80182:2,62124:80183:1,62127:80187:1,62150:134540:1,62151:80214:1,62153:80216:1,62157:80220:1,62163:80226:1,62164:80227:1,62170:80234:1,62173:80237:1,62176:80241:1,62177:80242:1,62178:80243:1,62179:80244:1,62180:80245:1,62182:80248:1,62184:80250:1,81468:102429:1,93524:115877:1,94636:117239:1,94654:117257:1,94655:117258:1,94656:117259:1,94657:128267:1,94658:117261:1,94659:117262:1,94660:117263:1,94661:117264:1,94662:117265:1,94663:117266:1,94664:117267:1,99828:123339:1,101883:125818:1,103771:128077:1,108653:134180:1,108654:134183:1,108655:134185:1,108657:134187:1,108658:134188:1,108659:134189:1,108660:134190:1,108661:134191:1,108662:134192:2,108849:134405:1,108850:136839:1,108851:134407:1,108855:134411:1,108858:134414:2,108859:134415:1,108864:134421:1,109667:135918:1,109668:135919:1,109669:135946:1,109915:136182:1,109916:136183:1,110079:136577:1,110081:136579:1,110258:136796:1,110283:136837:1,110422:137034:1,110597:137410:1', 'https://www.method.gg/guides/frost-mage/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 265, 2, 'M+: method.gg Multi Target / Mythic+ Soul Harvester (Recommended)', '71918:91425:1,71922:91430:1,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71941:91451:1,71942:91452:1,71947:91457:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71954:91465:1,71955:91466:1,71956:91468:1,71957:91469:1,71987:91504:1,72032:91552:1,72033:91553:1,72034:91554:1,72037:91558:1,72041:91562:1,72045:124692:1,72046:91567:1,72047:91568:1,72049:91570:1,72050:91571:1,72051:91572:1,72054:91576:1,72058:91580:2,94821:117418:1,94823:123839:1,94824:117421:1,94825:117422:1,94832:117429:1,94838:117435:1,94840:117437:1,94846:117443:1,94847:117444:1,94850:123840:1,94851:117448:1,94857:117454:1,99850:123384:1,100941:124694:1,102247:126303:1,109837:136096:1,109838:136097:1,109839:136098:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109847:136107:1,109848:136738:1,109849:136109:1,109851:136111:1,109853:136113:1,109854:136114:1,109859:136119:1,109860:136120:1,109861:136121:1,109862:136122:1,109863:136123:1,109864:136124:1,109866:136126:2,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110269:136812:1,110270:136813:1,110405:136983:1', 'https://www.method.gg/guides/affliction-warlock/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 266, 2, 'M+: method.gg Diabolist Mythic+/AoE/Raid Cleave', '71918:91425:1,71922:91430:1,71923:91431:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71933:91441:1,71936:91444:1,71937:91445:1,71942:91452:1,71947:91457:1,71949:91460:1,71950:91461:2,71952:91463:2,71955:91466:1,71956:91468:1,71957:91469:1,94826:117423:1,94830:117427:1,94831:117428:1,94833:117430:1,94836:117433:1,94843:117440:1,94848:118838:1,94849:117446:1,94851:117448:1,94852:118839:1,94855:117452:1,94856:117453:1,99849:123386:1,100941:124694:1,101888:125830:1,101891:125834:1,101892:125835:1,101893:125836:1,101894:125837:1,101895:125838:1,101903:125848:2,101905:125850:1,101908:125854:1,101909:125855:1,101914:125860:2,101920:125866:1,101923:125869:1,109241:135303:1,109244:135306:1,109250:135312:1,109252:135314:1,109253:135315:1,109257:135319:1,109831:136090:1,109832:136091:1,109833:136092:1,109840:136100:1,109842:136102:2,109843:136103:1,109845:136105:1,109847:136107:1,109848:136738:1,109934:136227:1,109936:136229:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110076:136573:1,110191:136719:1,110193:136721:1,110194:136722:1,110197:136726:1,110198:136727:1,110199:136728:1,110201:136730:1,110404:136980:1', 'https://www.method.gg/guides/demonology-warlock/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (9, 267, 2, 'M+: method.gg Hellcaller (Mythic+)', '71918:91425:1,71922:91430:1,71924:91432:2,71926:91434:1,71930:91438:1,71931:91439:1,71932:91440:1,71933:91441:1,71936:91444:1,71937:91445:1,71938:91447:1,71942:91452:1,71948:91459:1,71949:91460:1,71950:91461:2,71952:91463:2,71955:91466:1,71956:91467:1,71957:91469:1,71960:126494:1,71961:91474:1,71964:91477:1,71965:91478:1,71966:91479:1,71968:91481:1,71969:91482:2,71971:91484:1,71973:91486:1,71974:91488:1,71975:91489:1,71979:91494:1,71980:91496:1,71982:91499:1,71985:91502:1,72059:91581:1,72060:91582:1,72062:91584:1,72065:91588:1,72066:91589:2,72067:91590:1,72068:91591:1,72069:128601:1,94822:117419:1,94829:117426:1,94834:117431:1,94835:117432:1,94837:117434:1,94840:117437:1,94842:117439:1,94844:117441:1,94845:117442:1,94853:117450:1,94854:123310:1,94855:117452:1,99848:123382:1,100941:124694:1,101992:126002:1,101994:126004:1,102003:91423:1,102427:126493:1,109834:136093:1,109835:136094:1,109836:136095:1,109842:136102:2,109843:136103:1,109845:136105:1,109846:136106:1,109847:136107:1,109848:136738:1,110071:136568:1,110072:136569:1,110073:136570:1,110074:136571:1,110075:136572:1,110282:136835:1,110406:136986:1', 'https://www.method.gg/guides/destruction-warlock/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 268, 2, 'M+: method.gg Mythic+ Standard (Shado-Pan) - Recommended', '101064:124838:1,101065:136148:1,101067:136146:1,101069:124843:1,101071:124845:1,101072:124846:1,101075:124849:1,101077:124851:1,101078:124853:1,101079:124854:1,101080:124855:1,101081:124856:2,101082:124857:1,101085:124862:1,101086:124863:1,101087:124864:1,101088:124865:1,101090:124867:1,101135:124924:1,101136:124926:1,101140:124930:1,101141:124931:1,101142:124932:1,101145:124935:1,101146:124936:1,101147:124937:1,101152:124943:1,101153:124944:1,101156:124948:1,101158:124950:1,101160:124954:1,101163:124957:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124969:1,101177:124974:1,101178:124975:1,101179:124976:2,101181:124979:1,101183:124982:1,101184:124983:2,101187:124987:1,101188:124988:1,101189:124990:1,101190:124992:1,101193:124996:1,101195:124999:1,101196:136149:1,101201:125006:1,101202:125008:1,101219:125027:1,101223:125033:1,101244:125063:1,101245:125064:1,101246:125066:1,101247:125068:1,101248:125069:1,101249:125070:1,101250:125071:1,101251:125072:1,101252:125073:1,101253:125074:1,101254:125075:1,102004:124859:1,102433:126501:1,109697:135955:1,109698:135956:1,109699:135957:1,109826:136085:1,109827:136086:1,109882:136145:1,109910:136177:1,110435:137075:1', 'https://www.method.gg/guides/brewmaster-monk/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 269, 2, 'M+: method.gg Shado-Pan Mythic+', '101035:124805:2,101036:124806:1,101037:124807:1,101039:124810:1,101048:124820:1,101050:124822:1,101052:124824:1,101053:124826:1,101054:124827:1,101055:124828:1,101056:124829:1,101057:134453:1,101059:124833:1,101060:124834:1,101136:124926:1,101137:124927:1,101140:124930:1,101141:124931:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101150:124941:1,101153:124944:1,101159:124953:1,101162:124956:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124969:1,101175:124971:1,101178:124975:1,101179:124976:2,101182:124980:1,101183:124982:1,101184:124983:1,101185:124984:1,101186:124985:1,101203:125010:1,101205:125012:1,101206:125013:1,101207:134452:1,101208:125015:1,101209:125016:1,101210:125017:1,101211:125018:1,101213:125020:1,101214:125021:1,101215:125022:1,101216:125023:1,101217:125025:1,101218:125026:1,101232:125046:1,101244:125063:1,101245:125065:1,101246:125066:1,101247:125068:1,101248:125069:1,101249:125070:1,101250:125071:1,101251:125072:1,101252:125073:1,101253:125074:1,101254:125076:1,108946:134543:1,109697:135955:1,109698:135956:1,109699:135957:1,110020:136511:1,110022:136514:1,110023:136515:1,110067:136562:1,110098:136599:1,110436:137076:1', 'https://www.method.gg/guides/windwalker-monk/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (10, 270, 2, 'M+: method.gg Mythic+ (Conduit of the Celestials) - Preferred', '101093:124871:1,101095:124874:1,101096:124875:1,101097:124876:1,101098:124878:1,101099:124879:1,101102:124882:1,101104:124885:1,101107:124888:1,101109:124890:1,101110:124891:1,101111:124892:2,101112:124893:1,101113:124894:1,101115:124897:1,101117:124900:1,101118:124901:1,101119:124902:1,101120:124904:1,101121:124905:1,101125:124909:1,101127:125932:1,101128:124913:1,101129:124914:1,101130:124916:1,101131:124919:1,101132:124920:1,101133:124921:1,101134:124922:1,101136:124926:1,101139:124929:1,101140:124930:1,101142:124932:1,101143:124933:1,101144:124934:1,101146:124936:1,101147:124937:1,101153:124944:1,101157:124949:1,101161:124955:1,101163:124957:1,101164:124958:1,101165:124960:1,101166:124961:2,101167:124962:1,101168:124963:1,101169:124964:2,101170:124965:1,101173:124968:1,101174:124969:1,101175:124971:1,101178:124975:1,101179:124976:2,101182:124980:1,101183:124982:1,101184:124983:2,101185:124984:1,101186:124985:1,101223:125033:1,101231:125045:1,101233:125048:1,101234:125050:1,101235:125052:1,101236:125054:1,101237:125055:1,101238:125056:1,101239:125058:1,101240:125059:1,101242:125061:1,109516:135749:1,109700:135958:1,109701:135959:1,110019:136510:1,110026:136519:1,110067:136562:1,110097:136598:1,110211:136747:1,110218:136754:1', 'https://www.method.gg/guides/mistweaver-monk/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 102, 2, 'M+: method.gg Mythic+ - Elune’s Chosen', '82198:103276:1,82201:103279:1,82202:103280:1,82206:103284:1,82207:128589:1,82208:103286:1,82209:103287:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82225:103303:2,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82237:103316:1,82241:103320:1,88201:109833:1,88203:109835:1,88204:109836:1,88206:109839:1,88207:109840:2,88208:109842:1,88209:109843:1,88212:109846:1,88214:109848:2,88215:109849:1,88216:109850:1,88218:109852:1,88221:109856:1,88222:109857:1,88223:109858:1,88224:109859:1,88225:109861:1,88227:109863:2,88231:109867:1,88232:109868:1,88234:109870:1,88236:109872:1,91048:115458:1,93714:116102:1,94585:117772:1,94586:117177:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:123304:1,94598:117193:1,94600:117195:1,94607:117204:1,94608:117205:1,99808:123302:1,100175:123794:1,100176:123795:1,100177:123796:2,100223:123868:1,103846:128230:1,103847:128231:1,104078:128579:1,104080:128584:1,104082:128586:1,104083:128588:1,104085:128591:1,108032:133404:1,109718:135976:1,109719:135977:1,109720:135978:1,110279:136832:1,110421:137031:1', 'https://www.method.gg/guides/balance-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 104, 2, 'M+: method.gg Elune’s Chosen (Mythic+)', '82126:103190:1,82127:103191:1,82129:103193:1,82131:103195:1,82135:103199:1,82136:103201:1,82138:103203:2,82140:103206:1,82142:103209:1,82143:103210:2,82145:103212:1,82146:103213:2,82147:103214:1,82149:103216:1,82152:103221:1,82154:103223:2,82156:103225:1,82159:103228:1,82160:103229:1,82161:103231:1,82198:103276:1,82199:103277:1,82206:103284:1,82207:128589:1,82209:103287:1,82214:103292:2,82218:103296:1,82219:103297:1,82220:103298:1,82223:103301:1,82224:103302:1,82225:103303:2,82227:103305:1,82228:103306:1,82229:103307:1,82230:103308:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82237:103316:1,82239:103318:1,82241:103320:1,82242:103322:1,82246:103326:1,92226:103208:1,92227:103218:1,92585:136806:1,92587:114700:1,94585:117176:1,94586:117177:1,94587:117179:1,94588:117181:1,94590:117183:1,94594:117769:1,94596:117190:1,94597:117192:1,94598:117193:1,94607:117204:1,94608:117205:1,94609:117206:1,99807:123295:1,100175:123794:1,100176:123795:1,100177:123796:1,104078:128580:1,104080:128584:1,104081:128585:1,104085:128591:1,109375:135568:1,109377:135491:1,109718:135976:1,109719:135977:1,109720:135978:1,110431:137061:1', 'https://www.method.gg/guides/guardian-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (11, 105, 2, 'M+: method.gg Mythic+: Wildstalker (Best)', '82043:117104:1,82047:103098:1,82049:103100:1,82050:103101:1,82051:103103:1,82052:103105:1,82054:103108:1,82055:103109:1,82057:103111:1,82058:103112:1,82059:103113:1,82060:103114:1,82063:103118:1,82064:103119:1,82065:103121:1,82068:103124:1,82071:103127:1,82072:103128:1,82073:103129:1,82074:103130:1,82076:103132:1,82079:137507:1,82081:103139:1,82082:103141:1,82083:103142:1,82198:103276:1,82199:103277:1,82205:103283:1,82206:103284:1,82207:128589:1,82209:103287:1,82210:103288:1,82214:103292:2,82217:103295:1,82218:103296:1,82219:103297:1,82220:103298:1,82222:103300:1,82223:103301:1,82225:103303:2,82228:103306:1,82229:103307:1,82231:103309:1,82232:128581:1,82233:103311:2,82234:103312:1,82235:103313:1,82236:103314:1,82239:103318:1,82240:103319:1,82243:103323:1,82244:103324:1,82246:103326:1,94535:117105:1,94600:117195:1,94621:117221:1,94622:119855:1,94623:117223:1,94624:117224:1,94625:119854:1,94626:117226:1,94627:117227:1,94628:117229:1,94629:117231:1,94630:117232:1,94631:117234:1,99806:123298:1,100174:123793:1,100175:123794:1,100176:123795:1,103873:128274:1,103874:128708:1,103876:128277:1,104078:128580:1,104084:128590:1,104085:128591:1,104125:128707:1,109715:135973:1,109716:135974:1,109717:135975:1,110424:137040:1', 'https://www.method.gg/guides/restoration-druid/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 577, 2, 'M+: method.gg Fel-Scarred - Raid Cleave / Mythic+ (Recommended):', '90914:112823:1,90915:112824:1,90916:112825:1,90917:112826:1,90918:112827:1,90919:112828:1,90921:112830:1,90922:112831:1,90923:112832:1,90925:112834:1,90927:136502:1,90928:112838:1,90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90939:112850:1,90940:112851:1,90941:112852:1,90942:112853:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90993:112911:1,90994:117768:1,90997:117755:1,91000:112918:2,91001:112919:1,91002:112921:1,91003:112923:1,91006:112926:1,91007:112927:1,91008:112928:1,91017:112938:1,91018:112939:1,91021:112943:1,91022:112944:1,91024:112947:1,91025:112948:1,91026:112949:1,91027:112950:1,91028:112951:1,91032:112955:1,91033:112956:1,91034:112957:2,91036:112959:1,93014:115245:1,93015:115246:1,93016:115248:1,94899:117496:1,94901:117498:1,94902:124009:1,94904:117501:1,94905:117502:1,94909:117506:1,94912:117509:1,94913:124011:1,94915:117512:1,94916:117513:1,94917:117514:1,94918:117515:1,95143:117741:1,95147:117754:2,95149:117758:1,95150:117759:1,95152:117762:1,99824:123329:1,109772:136030:1,109773:136031:1,109774:136032:1,110011:136501:1,110427:137049:1', 'https://www.method.gg/guides/havoc-demon-hunter/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 581, 2, 'M+: method.gg Annihilator (Mythic+)', '90928:112838:1,90929:112839:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90938:112849:1,90941:112852:1,90942:112853:1,90945:112858:1,90946:112859:1,90948:112861:1,90949:112862:2,90950:112863:1,90951:112864:1,90956:112869:1,90958:112872:2,90959:112873:1,90961:112876:1,90962:112877:2,90966:112881:1,90967:112882:1,90968:112883:1,90970:112886:1,90971:112887:1,90972:112888:1,90974:112890:1,90975:112891:1,90976:112892:2,90977:112893:1,90978:112894:1,90979:112895:1,90980:112896:1,90981:112897:2,90983:112899:1,90987:112903:1,90988:112905:1,90989:112906:1,90990:112907:1,90991:112908:1,90994:117768:1,90999:112917:1,91000:112918:2,91001:112919:1,91002:112921:1,91004:112924:2,91007:112927:1,94915:117512:1,95149:117758:1,95150:117759:1,95151:117761:1,95152:117762:1,95154:117767:1,99823:134253:1,108722:134271:1,108729:134282:1,109442:135660:1,109443:135661:1,109444:135662:1,109445:135663:1,109446:135664:1,109447:135665:1,109448:135659:1,109449:135667:1,109450:136810:1,109451:135669:1,109452:135670:1,109453:135671:1,109454:135672:1,109455:135673:1,110011:136501:1,110425:137043:1', 'https://www.method.gg/guides/vengeance-demon-hunter/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (12, 1480, 2, 'M+: method.gg Void-Scarred Melee Mythic+ (Recommended)', '90927:136502:1,90928:112838:1,90929:112839:1,90930:112840:1,90931:112841:1,90933:112844:1,90934:112845:1,90935:112846:2,90936:112847:2,90937:112848:1,90938:112849:1,90939:112850:1,90940:112851:1,90942:112853:1,90946:112859:1,90949:112862:2,90950:112863:1,90997:117755:1,91000:112918:2,91001:112919:1,91002:112921:1,91006:112926:1,91007:112927:1,95149:117758:1,95150:117759:1,95152:117762:1,95154:117767:1,107336:132278:1,107338:132280:1,107339:132281:1,107340:132282:1,107341:132283:1,107342:132284:1,107343:132285:1,107344:132286:1,107345:132287:1,107346:132288:1,107347:132289:1,107770:133106:1,107771:133107:1,107774:133110:1,107999:133370:1,108122:133511:1,108123:134331:1,108136:133531:1,108143:133538:2,108144:134330:1,108628:134149:2,108704:136623:1,108723:134272:1,108727:134280:1,109449:135667:1,109503:135736:1,109871:136131:2,110009:136499:1,110011:136501:1,110104:136608:1,110105:136607:1,110106:136615:1,110107:136614:1,110108:136609:1,110109:136606:1,110110:136611:1,110111:136610:1,110112:136613:1,110113:136612:1,110114:136619:1,110115:136622:1,110116:136617:1,110117:136620:1,110165:136690:2,110166:136691:1,110167:136692:1,110168:136693:1,110170:136695:1,110172:136697:1,110173:136698:1', 'https://www.method.gg/guides/devourer-demon-hunter/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1467, 2, 'M+: method.gg Scalecommander Mythic+ & Cleave', '93272:115578:1,93274:115580:2,93275:115581:1,93283:115591:2,93284:115592:1,93285:115593:1,93288:115596:1,93289:115597:1,93294:115602:1,93295:115603:2,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93313:115623:1,93314:115624:1,93315:115626:1,93316:115627:1,93317:115628:1,93318:115629:1,93319:115631:1,93320:115632:1,93323:115635:1,93324:115636:1,93325:115637:1,93326:115638:1,93327:115639:1,93328:115640:1,93329:115641:2,93330:115642:1,93331:115643:1,93332:115645:1,93333:115646:1,93334:115647:1,93340:115654:1,93341:115655:1,93342:115656:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93353:115668:1,93354:115669:1,93355:115670:2,93366:115683:1,93715:116103:1,94921:117518:1,94928:120124:1,94933:117530:1,94934:117531:1,94936:117533:1,94939:117536:1,94941:117538:1,94943:120123:1,94944:117541:1,94952:117549:1,94953:117550:1,99827:123333:1,103843:128216:1,109793:136051:1,109794:136052:1,109795:136053:1,110064:136559:1,110414:137010:1', 'https://www.method.gg/guides/devastation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1468, 2, 'M+: method.gg Mythic+ Flameshaper Hero Talents (Recommended for +11 and Lower)', '93236:115538:2,93237:115539:1,93238:115540:1,93239:115541:1,93240:115542:1,93241:115543:1,93242:115544:1,93243:115546:1,93245:115549:1,93246:115550:2,93247:115551:2,93248:115552:1,93250:115554:1,93253:115557:1,93255:115559:1,93257:115561:1,93258:115563:1,93259:115564:1,93260:115565:1,93267:133527:1,93268:115574:2,93271:115577:1,93288:115596:1,93289:115597:1,93291:115599:1,93292:115600:2,93294:115602:1,93295:115603:2,93298:115607:1,93300:115609:1,93304:115613:1,93305:115614:1,93306:115615:1,93309:115618:1,93311:115620:1,93312:115621:1,93336:115650:1,93337:115651:1,93338:115652:1,93339:115653:1,93340:115654:1,93341:115655:1,93342:115656:1,93343:115657:1,93345:115660:1,93346:115661:1,93347:115662:2,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93354:115669:1,93355:115670:2,94920:117517:1,94922:117519:1,94923:117520:1,94931:117528:1,94937:123404:1,94945:117542:1,94946:117543:1,94949:117546:1,94950:117547:1,94954:117551:1,94956:128713:1,99804:123294:1,99826:123332:1,99857:123416:1,103843:128216:1,103844:128217:1,109796:136054:1,109797:136055:1,109798:136056:1,110413:137007:1', 'https://www.method.gg/guides/preservation-evoker/talents');
REPLACE INTO playerbot_v2_talent_build (class_id, spec_id, context, label, entries_json, source_url) VALUES (13, 1473, 2, 'M+: method.gg Mythic+ (Chronowarden)', '93195:115493:1,93198:115496:1,93199:115690:1,93200:115498:1,93201:115499:1,93202:115500:1,93203:115502:1,93205:115504:1,93206:115505:1,93207:115506:1,93208:115507:1,93212:115512:1,93213:115513:1,93218:115518:1,93219:115519:1,93220:115520:1,93221:115521:1,93222:115522:1,93223:115523:1,93226:115527:1,93227:115528:1,93229:115530:1,93230:115531:1,93232:115533:1,93234:115536:1,93235:115706:1,93287:115595:1,93288:115596:1,93289:115597:1,93292:115600:2,93293:115601:1,93294:115602:1,93300:115609:1,93302:115611:2,93304:115613:1,93305:115614:1,93306:115615:1,93308:115617:1,93309:115618:1,93310:115619:2,93311:115620:1,93312:115621:1,93340:115654:1,93341:115655:1,93343:115657:1,93344:115658:1,93346:115661:1,93348:115663:1,93349:115664:2,93350:115665:1,93351:115666:1,93352:115667:1,93354:115669:1,93355:115670:2,93358:115675:1,93367:115685:1,93368:115688:1,93715:116103:1,94925:117522:1,94929:117526:1,94930:126310:1,94932:117529:1,94935:117532:1,94942:117539:1,94947:117544:1,94948:117545:1,94951:117548:1,94954:117551:1,94955:117552:1,99825:123334:1,102248:126304:1,103843:128216:1,103844:128217:1,109508:135741:1,109509:135742:1,109510:135743:1,110415:137013:1', 'https://www.method.gg/guides/augmentation-evoker/talents');
-- Record this migration as applied.
INSERT INTO playerbot_v2_schema_version (version, sha256)
VALUES (16, 'pending-fill-at-release-time-with-actual-sha256-of-this-file');
+141
View File
@@ -0,0 +1,141 @@
-- Migration: 0017_shared_split
-- Date: 2026-09-11
-- Purpose: Give the four realm-independent V2 tables a home in the SHARED
-- playerbot database, and carry over any rows an existing realm has
-- already accumulated in its character database.
-- Reverts: yes (DROP the four {SHARED} tables).
--
-- WHY THIS EXISTS
-- Playerbot data splits by scope. Anything keyed on a character guid, an account
-- id, or this realm's operational state must stay in the realm's character
-- database - character guid 12442 exists on every realm, so pooling those rows
-- into one schema shared by several realms collides. That covers
-- playerbot_v2_character / _personality / _preferences / _squad_preset /
-- _account, bot_guild_meta / _member_meta / _name_reserved (guild ids and
-- founder_low / rival_low), bot_craft_orders (requester_low / crafter_low),
-- _fleet_vitals_sample (per-realm telemetry) and _population_target (realm_id).
-- Those tables are NOT touched here; they stay exactly where they are.
--
-- The four below carry no realm identity. They are content: class/spec talent
-- builds, map-derived world metadata, quest-objective diagnostics, and the bot
-- name pool. One copy serves every realm.
--
-- The name pool is the instructive case. The list of available names is static
-- and shared, but whether a name is TAKEN is a per-realm fact - character names
-- are unique per realm, so a name consumed on one realm says nothing about
-- another. The pool therefore lives here while its usage columns (is_taken,
-- is_used, used_by_guid) are realm state; see the note at the end of this file.
--
-- Migrations 0001-0016 are deliberately left untouched. They have already been
-- recorded as applied on every existing realm, so editing them would change
-- history that will never be replayed. This file is additive.
-- @target: shared
CREATE TABLE IF NOT EXISTS {SHARED}.playerbot_v2_talent_build (
class_id TINYINT UNSIGNED NOT NULL,
spec_id INT UNSIGNED NOT NULL,
context VARCHAR(32) NOT NULL DEFAULT 'default',
label VARCHAR(64) NULL,
entries_json MEDIUMTEXT NOT NULL,
source_url VARCHAR(255) NULL,
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (class_id, spec_id, context)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS {SHARED}.playerbot_v2_world_metadata (
id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
map_id INT UNSIGNED NOT NULL,
zone_id INT UNSIGNED NOT NULL DEFAULT 0,
kind VARCHAR(32) NOT NULL,
pos_x FLOAT NOT NULL DEFAULT 0,
pos_y FLOAT NOT NULL DEFAULT 0,
pos_z FLOAT NOT NULL DEFAULT 0,
radius FLOAT NOT NULL DEFAULT 0,
label VARCHAR(128) NULL,
notes TEXT NULL,
created_by VARCHAR(64) NULL,
created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
KEY idx_map_zone (map_id, zone_id),
KEY idx_kind (kind)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS {SHARED}.playerbot_v2_stuck_objective (
quest_id INT UNSIGNED NOT NULL,
obj_id INT UNSIGNED NOT NULL,
category VARCHAR(32) NOT NULL DEFAULT '',
hit_count INT UNSIGNED NOT NULL DEFAULT 0,
first_seen DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
last_seen DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
sample_map INT UNSIGNED NOT NULL DEFAULT 0,
sample_zone INT UNSIGNED NOT NULL DEFAULT 0,
sample_x FLOAT NOT NULL DEFAULT 0,
sample_y FLOAT NOT NULL DEFAULT 0,
sample_bot BIGINT UNSIGNED NOT NULL DEFAULT 0,
PRIMARY KEY (quest_id, obj_id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS {SHARED}.playerbots_names (
name_id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
name VARCHAR(12) NOT NULL,
gender TINYINT UNSIGNED NOT NULL DEFAULT 0,
race_mask INT UNSIGNED NOT NULL DEFAULT 0,
is_taken TINYINT(1) NOT NULL DEFAULT 0,
is_used TINYINT(1) NOT NULL DEFAULT 0,
used_by_guid BIGINT UNSIGNED NULL,
created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
updated_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
UNIQUE KEY uk_name (name),
KEY idx_unused (is_used, gender)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- Carry over rows an existing realm already has in its character database.
--
-- The unqualified source names resolve to the character database, because that
-- is the connection's default schema. No existence guard is needed: migrations
-- 0001-0016 are left untouched and still create all four tables there, and they
-- sort before 0017, so the sources always exist by the time this runs - on a
-- fresh install as well as an existing realm.
--
-- Deliberately NOT written with SET @var / PREPARE / EXECUTE. Each statement in
-- a migration is dispatched through DatabaseWorkerPool::DirectExecute, which
-- calls GetFreeConnection() per statement and unlocks afterwards, so
-- consecutive statements may run on DIFFERENT pooled connections. User
-- variables and prepared-statement handles are session-scoped, so they would
-- vanish between statements - intermittently, depending on pool size and
-- contention. Every statement below is therefore self-contained.
--
-- INSERT IGNORE, so re-running this migration never clobbers rows the shared
-- database already holds - the shared copy wins once it exists.
INSERT IGNORE INTO {SHARED}.playerbot_v2_talent_build
(class_id, spec_id, context, label, entries_json, source_url, updated_at)
SELECT class_id, spec_id, context, label, entries_json, source_url, updated_at
FROM playerbot_v2_talent_build;
INSERT IGNORE INTO {SHARED}.playerbot_v2_world_metadata
(id, map_id, zone_id, kind, pos_x, pos_y, pos_z, radius, label, notes, created_by, created_at, updated_at)
SELECT id, map_id, zone_id, kind, pos_x, pos_y, pos_z, radius, label, notes, created_by, created_at, updated_at
FROM playerbot_v2_world_metadata;
INSERT IGNORE INTO {SHARED}.playerbot_v2_stuck_objective
(quest_id, obj_id, category, hit_count, first_seen, last_seen, sample_map, sample_zone, sample_x, sample_y, sample_bot)
SELECT quest_id, obj_id, category, hit_count, first_seen, last_seen, sample_map, sample_zone, sample_x, sample_y, sample_bot
FROM playerbot_v2_stuck_objective;
-- The name pool copies across WITHOUT its usage columns: is_taken, is_used and
-- used_by_guid describe which names THIS realm has consumed, and those flags are
-- meaningless (and actively wrong) on any other realm. The shared pool therefore
-- starts pristine and every realm tracks its own consumption.
INSERT IGNORE INTO {SHARED}.playerbots_names
(name_id, name, gender, race_mask, is_taken, is_used, used_by_guid, created_at, updated_at)
SELECT name_id, name, gender, race_mask, 0, 0, NULL, created_at, updated_at
FROM playerbots_names;
-- NOTE - still outstanding after this migration:
-- The runtime still READS these four tables through unqualified names, i.e. from
-- the character database. Moving the read paths onto {SHARED} is a separate
-- change; until it lands, this migration only establishes the shared copies and
-- keeps them in step. Nothing regresses in the meantime because the character
-- side is untouched.
@@ -0,0 +1,15 @@
-- Migration: 0018_companion_roster
-- Date: 2026-10-05
-- Purpose: The owner's saved companion roster (`.bot save` / `.bot unsave`): `.bot call all` and the ForeverBots
-- "Call all" button bring back only the saved companions, not every bot the owner ever made.
--
-- Columns:
-- companion_saved 1 = on its owner's roster. Only meaningful for owned bots (owner_account_id != 0).
-- Reverts: yes (DROP COLUMN companion_saved).
ALTER TABLE playerbot_v2_character
ADD COLUMN companion_saved TINYINT UNSIGNED NOT NULL DEFAULT 0;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(18, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,16 @@
-- Migration: 0020_starter_pet_granted
-- Date: 2026-10-05
-- Purpose: A hunter companion's starter pet (the pet its Taming the Beast quest would have given it) is granted once
-- per bot, ever. Without the flag the companion upkeep tamed a new pet every pass once the owner abandoned
-- the first, and the bot's pet slot blocked the owner's own Tame Beast.
--
-- Columns:
-- starter_pet_granted 1 = the bot has had its starter pet (granted, or it already had a pet of its own).
-- Reverts: yes (DROP COLUMN starter_pet_granted).
ALTER TABLE playerbot_v2_character
ADD COLUMN starter_pet_granted TINYINT UNSIGNED NOT NULL DEFAULT 0;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(20, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+42
View File
@@ -0,0 +1,42 @@
-- Migration: 0022_bot_text_weight
-- Date: 2026-10-05
-- Purpose: Keep the ike3 texts' weighting. ike3 made a line more likely by listing it more than once
-- (ai_playerbot_texts has six such repeats: one 'broadcast_looting_item_normal' line, four
-- 'broadcast_looting_item_rare' lines, one 'suggest_instance' line). 0019 inserts through a
-- unique key on (name, reply_type, text) so that re-running it is a no-op, and that key
-- silently dropped every repeat, flattening the odds.
--
-- The repeat count becomes data instead of a duplicate row:
-- playerbot_v2_bot_text.weight relative odds of the line among the rows of its key
-- (and, for 'reply', among the rows of its reply_type).
-- Default 1. Bot/BotTextMgr.cpp picks weighted.
-- The six rows ike3 listed twice get weight 2. New content that wants a line said more often
-- raises its weight; the unique key stays, so text inserts remain idempotent.
-- Reverts: yes (DROP COLUMN weight).
-- @target: shared
ALTER TABLE {SHARED}.playerbot_v2_bot_text
ADD COLUMN weight SMALLINT UNSIGNED NOT NULL DEFAULT 1 AFTER reply_type;
UPDATE {SHARED}.playerbot_v2_bot_text SET weight = 2
WHERE name = 'broadcast_looting_item_normal' AND reply_type = 0 AND text = 'wonder what %item_link tastes like';
UPDATE {SHARED}.playerbot_v2_bot_text SET weight = 2
WHERE name = 'broadcast_looting_item_rare' AND reply_type = 0 AND text = '%item_link is hunter bis';
UPDATE {SHARED}.playerbot_v2_bot_text SET weight = 2
WHERE name = 'broadcast_looting_item_rare' AND reply_type = 0 AND text = '%item_link is %my_class bis';
UPDATE {SHARED}.playerbot_v2_bot_text SET weight = 2
WHERE name = 'broadcast_looting_item_rare' AND reply_type = 0 AND text = 'RNG is not bad today %item_link';
UPDATE {SHARED}.playerbot_v2_bot_text SET weight = 2
WHERE name = 'broadcast_looting_item_rare' AND reply_type = 0 AND text = 'sweet %item_link, freshly looted';
UPDATE {SHARED}.playerbot_v2_bot_text SET weight = 2
WHERE name = 'suggest_instance' AND reply_type = 0 AND text = 'What about %instance_name?';
INSERT INTO {SHARED}.playerbot_v2_schema_version (version, sha256) VALUES
(22, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
@@ -0,0 +1,19 @@
-- Migration: 0023_companion_gear_varied
-- Date: 2026-10-06
-- Purpose: Companions geared before per-bot gear variety (BotGearGenerator picks among equally good items by the
-- bot's guid) all wear the single top-scoring item per slot, and the re-gear pass never replaces gear that
-- is already good enough. Each companion gets one full re-roll of its equipment with the varied generator
-- (BotPopulationManager::RerollCompanionGear) and is then marked here so it never happens again.
-- `.bot regear` re-rolls on demand whatever the flag says.
--
-- Columns:
-- gear_varied 1 = the companion's equipment has had its one re-roll with the varied generator.
-- Every existing row starts at 0, which is how the companions made before variety are found.
-- Reverts: yes (DROP COLUMN gear_varied).
ALTER TABLE playerbot_v2_character
ADD COLUMN gear_varied TINYINT UNSIGNED NOT NULL DEFAULT 0;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(23, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+17
View File
@@ -0,0 +1,17 @@
-- Migration: 0024_companion_role
-- Date: 2026-10-07
-- Purpose: A companion's declared role (`.bot add <class> tank|healer|dps`, `/setrole`) lived only in memory (BotAI
-- role override plus the Classic virtual spec), so a relog, `.bot call` or restart dropped it and the role
-- was re-inferred from the bought talents; hybrids (druids, paladins) came back as tanks. The role is now
-- stored with the bot and re-applied at login and when it is called.
--
-- Columns:
-- companion_role 0 = none declared, 1 = tank, 2 = healer, 3 = dps. Only meaningful for owned bots.
-- Reverts: yes (DROP COLUMN companion_role).
ALTER TABLE playerbot_v2_character
ADD COLUMN companion_role TINYINT UNSIGNED NOT NULL DEFAULT 0;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(24, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+20
View File
@@ -0,0 +1,20 @@
-- Migration: 0025_owner_gear_mode
-- Date: 2026-10-10
-- Purpose: A player chooses how the gear of the companions they own is picked: `match` (default; the best gear for the bot's
-- level, at the cap up to the owner's own gear level), `best`, or the class tier set `t1` / `t2` / `t3` (level cap only).
-- The choice is per owner account and kept across relog and restart.
--
-- Columns:
-- owner_account_id the owning account (one row per owner)
-- gear_mode 0 = match, 1 = best, 2 = t1, 3 = t2, 4 = t3 (Gear::Owned::GearMode)
-- Reverts: yes (DROP TABLE playerbot_v2_owner_gear).
CREATE TABLE IF NOT EXISTS playerbot_v2_owner_gear (
owner_account_id INT UNSIGNED NOT NULL,
gear_mode TINYINT UNSIGNED NOT NULL DEFAULT 0,
PRIMARY KEY (owner_account_id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(25, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
@@ -0,0 +1,16 @@
-- Migration: 0026_companion_subgroup
-- Date: 2026-10-11
-- Purpose: A raid built on purpose (two tanks and two healers in sub-group 1, the DPS behind them) came back jumbled after a relog or
-- `.bot call all`: every companion joins the first free sub-group in the order it logs in. The sub-group of an owned
-- companion is now stored (`.bot save`, and whenever the leader moves it) and put back when it joins the owner's raid.
--
-- Columns:
-- companion_subgroup 0 = none stored, otherwise the raid sub-group number 1-8 (Group sub-group index + 1)
-- Reverts: yes (DROP COLUMN companion_subgroup).
ALTER TABLE playerbot_v2_character
ADD COLUMN companion_subgroup TINYINT UNSIGNED NOT NULL DEFAULT 0;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(26, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+17
View File
@@ -0,0 +1,17 @@
-- Migration: 0027_companion_spec
-- Date: 2026-10-11
-- Purpose: `.bot save` stored a companion's role (tank / healer / dps) but not its talent spec, so a call or relog re-derived the spec from the
-- role: a DPS paladin or druid came back as whichever DPS spec the class defaults to, not the one it was saved in. The Classic spec
-- id the bot plays (ClassicSpec: what the talent build and the rotation follow) is now stored with it and pinned again when the
-- bot is set up on a call or login; the talents are re-bought for it as for any spec change.
--
-- Columns:
-- companion_spec 0 = none stored, otherwise the Classic spec id (Playerbot::Classic::EffectiveSpecId)
-- Reverts: yes (DROP COLUMN companion_spec).
ALTER TABLE playerbot_v2_character
ADD COLUMN companion_spec SMALLINT UNSIGNED NOT NULL DEFAULT 0;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(27, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+17
View File
@@ -0,0 +1,17 @@
-- Migration: 0028_companion_order
-- Date: 2026-10-11
-- Purpose: `.bot save` stored each companion's raid sub-group but not its place inside it. The raid frame lists a sub-group in the order of
-- the group's member list (join order), which differs from call to call because the bots log in asynchronously. The member's
-- position in the group list at save time is stored with it, and the restore after a call puts the owned members back in
-- that order.
--
-- Columns:
-- companion_order 0 = none stored, otherwise the member's index in the group member list at save time + 1
-- Reverts: yes (DROP COLUMN companion_order).
ALTER TABLE playerbot_v2_character
ADD COLUMN companion_order TINYINT UNSIGNED NOT NULL DEFAULT 0;
INSERT INTO playerbot_v2_schema_version (version, sha256) VALUES
(28, REPEAT('0', 64))
ON DUPLICATE KEY UPDATE applied_at = CURRENT_TIMESTAMP;
+27
View File
@@ -0,0 +1,27 @@
# Playerbot V2 — SQL migrations
Per `v2/SCHEMA.md`. Migration files in this directory are numbered, append-only, and idempotent. Run by `Persistence/PlayerbotMigrationMgr` at module init.
For full setup instructions (schema creation, config, world fixes) see
`v2/INSTALL.md`.
## Order
Applied in ascending numeric order; each file records itself in
`playerbot_v2_schema_version`. Current set:
- `0001_init.sql` — schema_version + core tables (account, character, personality, preferences, population_target)
- `0002`–`0014` — owner/squad control, talent builds, population columns, guild metadata, world metadata, leveling zone, fleet vitals, archetype, craft orders, stuck-objective ledger
- `0015_name_pool.sql` — the curated ~107k-row random bot **name pool** (`playerbots_names`), shipped with use-state reset so a fresh install starts with the whole pool available
- `0016`–`0017` — talent builds for 12.1, shared-database split
- `0018_companion_roster.sql` — `companion_saved` on `playerbot_v2_character`: the owner's saved companion roster
- `0019_bot_texts.sql` — (shared DB) the bots' speech lines and per-key speak chances, carried over from the ike3 build's `ai_playerbot_texts`
- `0020_starter_pet_granted.sql` — `playerbot_v2_character.starter_pet_granted`: a hunter companion's starter pet is granted once, never again after its owner abandons it
- `0022_bot_text_weight.sql` — (shared DB) `playerbot_v2_bot_text.weight`: a line's relative odds within its key, restoring the ike3 lines that 0019's unique key had collapsed
- `0023_companion_gear_varied.sql` — `playerbot_v2_character.gear_varied`: a companion geared before per-bot gear variety gets one full gear re-roll, then never again
- `0024_companion_role.sql` — `playerbot_v2_character.companion_role`: a companion's declared role (tank/healer/dps), kept across relog, `.bot call` and restart
- `0025_owner_gear_mode.sql` — `playerbot_v2_owner_gear`: the gear mode (match / best / t1 / t2 / t3) an owner chose for their companions, per owner account
## Discipline
- Never edit a numbered migration after it ships. Add a new one to amend.
- Each migration is self-contained: no cross-file dependencies on application order beyond numbering.
- Reversibility documented in the file header.
@@ -0,0 +1,4 @@
-- normal players may use `.summon all` / `.summon <own bot>` (PlayerbotV2 companions). The handler
-- (cs_misc.cpp -> PlayerbotV2TrySummon) gives non-GM callers the bot path only, so summoning real players stays GM-only.
-- 195 = Role: Player, 528 = Command: summon.
INSERT IGNORE INTO `rbac_linked_permissions` (`id`, `linkedId`) VALUES (195, 528);
@@ -0,0 +1,25 @@
--
-- Fix corrupt spell_proc for Vampiric Embrace (15286).
--
-- The WCDB base shipped a broken proc definition for Vampiric Embrace:
-- SchoolMask 0, SpellFamilyName 0, ProcFlags 2424832, SpellTypeMask 0,
-- SpellPhaseMask 1 (PROC_SPELL_PHASE_CAST).
-- With SpellPhaseMask = CAST the aura procs on a spell cast, where the proc
-- event carries no DamageInfo. spell_pri_vampiric_embrace::CheckProc then
-- dereferences eventInfo.GetDamageInfo() (a null) and segfaults the whole
-- worldserver. It was hit live 2026-09-15 by a Priest bot casting a non-damage
-- spell (528, Cure Disease); gdb pinned the crash to spell_priest.cpp CheckProc.
--
-- Restore the canonical TrinityCore values (TDB 1210.26091, the 12.1.0.69814
-- release this branch is merged to): the aura procs on Shadow (SchoolMask 32),
-- Priest family (6), spell DAMAGE (SpellTypeMask 1) on HIT (SpellPhaseMask 2),
-- which is the event shape the script's damage-leech logic requires.
--
-- The script is also hardened to null-check GetDamageInfo() regardless, but this
-- row is the actual data bug and is corrected from the authoritative TDB, not
-- hand-authored.
DELETE FROM `spell_proc` WHERE `SpellId` = 15286;
INSERT INTO `spell_proc`
(`SpellId`,`SchoolMask`,`SpellFamilyName`,`SpellFamilyMask0`,`SpellFamilyMask1`,`SpellFamilyMask2`,`SpellFamilyMask3`,`ProcFlags`,`ProcFlags2`,`SpellTypeMask`,`SpellPhaseMask`,`HitMask`,`AttributesMask`,`DisableEffectsMask`,`ProcsPerMinute`,`Chance`,`Cooldown`,`Charges`) VALUES
(15286, 32, 6, 0, 0, 0, 0, 0, 0, 1, 2, 0, 2, 0, 0, 0, 0, 0);
+8
View File
@@ -18,3 +18,11 @@ endif(SERVERS)
if(TOOLS)
add_subdirectory(tools)
endif(TOOLS)
# Deferred link: src/server/game/CMakeLists.txt needs to link against
# extractor_common for Road::ApplyCorridorsToNavmesh, but at the time game
# is processed the tools subtree hasn't been visited yet — so the target
# does not exist. Wire the link here, after both subtrees are configured.
if(SERVERS AND TOOLS AND TARGET game AND TARGET extractor_common)
target_link_libraries(game PRIVATE extractor_common)
endif()
+21
View File
@@ -28,6 +28,7 @@
#include <G3D/AABox.h>
#include <G3D/Ray.h>
#include <G3D/Vector3.h>
#include <mutex>
namespace {
@@ -97,6 +98,16 @@ struct DynTreeImpl : public ParentTree/*, public Intersectable*/
TimeTracker rebalance_timer;
int unbalanced_times;
// Serializes all access to the underlying BIH/grid. The tree is lazily
// rebuilt (balance()) on both the write path and the read path
// (intersectPoint/intersectRay -> BIHWrap::balance() when unbalanced),
// so two threads touching the same map's tree — e.g. a MapUpdater worker
// and a main-thread PlayerbotV2 login doing a terrain query — would race
// on the rebuild and double-free the BIH's internal vector. Held only for
// the duration of a single tree operation and never while calling back
// into Map/other locked subsystems, so it is a leaf lock (deadlock-safe).
mutable std::mutex _treeMutex;
};
DynamicMapTree::DynamicMapTree() : impl(new DynTreeImpl()) { }
@@ -105,26 +116,31 @@ DynamicMapTree::~DynamicMapTree() = default;
void DynamicMapTree::insert(GameObjectModel const& mdl)
{
std::scoped_lock guard(impl->_treeMutex);
impl->insert(mdl);
}
void DynamicMapTree::remove(GameObjectModel const& mdl)
{
std::scoped_lock guard(impl->_treeMutex);
impl->remove(mdl);
}
bool DynamicMapTree::contains(GameObjectModel const& mdl) const
{
std::scoped_lock guard(impl->_treeMutex);
return impl->contains(mdl);
}
void DynamicMapTree::balance()
{
std::scoped_lock guard(impl->_treeMutex);
impl->balance();
}
void DynamicMapTree::update(uint32 t_diff)
{
std::scoped_lock guard(impl->_treeMutex);
impl->update(t_diff);
}
@@ -184,6 +200,7 @@ private:
bool DynamicMapTree::getIntersectionTime(G3D::Ray const& ray, G3D::Vector3 const& endPos, PhaseShift const& phaseShift, float& maxDist) const
{
std::scoped_lock guard(impl->_treeMutex);
float distance = maxDist;
DynamicTreeIntersectionCallback callback(phaseShift);
impl->intersectRay(ray, callback, distance, endPos);
@@ -239,6 +256,7 @@ bool DynamicMapTree::isInLineOfSight(G3D::Vector3 const& startPos, G3D::Vector3
G3D::Ray r(startPos, (endPos - startPos) / maxDist);
DynamicTreeLosCallback callback(phaseShift);
std::scoped_lock guard(impl->_treeMutex);
impl->intersectRay(r, callback, maxDist, endPos);
return !callback.didHit();
@@ -249,6 +267,7 @@ float DynamicMapTree::getHeight(float x, float y, float z, float maxSearchDist,
G3D::Vector3 v(x, y, z);
G3D::Ray r(v, G3D::Vector3(0, 0, -1));
DynamicTreeIntersectionCallback callback(phaseShift);
std::scoped_lock guard(impl->_treeMutex);
impl->intersectZAllignedRay(r, callback, maxSearchDist);
if (callback.didHit())
@@ -261,6 +280,7 @@ bool DynamicMapTree::getAreaAndLiquidData(float x, float y, float z, PhaseShift
{
G3D::Vector3 v(x, y, z + 0.5f);
DynamicTreeLocationInfoCallback intersectionCallBack(phaseShift);
std::scoped_lock guard(impl->_treeMutex);
impl->intersectPoint(v, intersectionCallBack);
if (VMAP::GroupModel const* hitModel = intersectionCallBack.GetLocationInfo().hitModel)
{
@@ -284,5 +304,6 @@ bool DynamicMapTree::getAreaAndLiquidData(float x, float y, float z, PhaseShift
std::span<GameObjectModel const* const> DynamicMapTree::getModelsInGrid(uint32 gx, uint32 gy) const
{
// convert from map tile X/Y to RegularGrid internal representation
std::scoped_lock guard(impl->_treeMutex);
return impl->getObjects(63 - int32(gx), 63 - int32(gy));
}
+125
View File
@@ -0,0 +1,125 @@
/*
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef TRINITYCORE_ROAD_MAP_DEFINES_H
#define TRINITYCORE_ROAD_MAP_DEFINES_H
#include "Define.h"
#include <array>
#include <cstdint>
#include <string>
// ----------------------------------------------------------------------------
// Road-aware mmaps parallel file format.
//
// The road-aware mmap workstream (design doc: ROAD_AWARE_PATHFINDING_PLAN.md)
// extends terrain extraction with a per-MCNK road mask. Rather than modify
// the existing .map file format (which would force ALL existing extracted
// maps to be re-generated), we store road metadata in a PARALLEL file:
//
// maps/<NN>/<NN><XX><YY>.road
//
// Where NN is the map id (zero-padded), XX/YY are ADT tile coords.
// The format is fixed-size: 24-byte header + 256 bytes of mask = 280 bytes
// per ADT. Servers + mmaps_generator look for these files alongside the
// existing .map files; absence means "no road data, behave as today".
//
// Rationale:
// 1. Old maps without road files Just Work — zero forced re-extraction.
// 2. New extraction is additive: produces .map (unchanged) + .road (new).
// 3. mmaps regen is the ONLY hard step required to activate road behavior.
// 4. Format is self-contained — magic + version make corruption visible.
// ----------------------------------------------------------------------------
namespace TrinityCore::RoadMap
{
// ASCII magic 'ROAD' (little-endian: stored as bytes R,O,A,D on disk).
inline constexpr uint32 kRoadFileMagic = 0x44414F52u; // 'D','A','O','R' in LE = "ROAD" on disk
inline constexpr uint32 kRoadFileVersion = 1u;
// 16x16 MCNK grid per ADT.
inline constexpr std::size_t kMcnksPerAdtSide = 16;
inline constexpr std::size_t kMcnksPerAdt =
kMcnksPerAdtSide * kMcnksPerAdtSide; // 256
enum class RoadFileFlags : uint32
{
kNone = 0,
kLowConfidence = 0x1, // classifier flagged this regen as low-confidence
// (e.g. corpus precision/recall below quality bar
// at time of writing) — server logs a warning
kExperimental = 0x2, // reserved for future iteration tags
};
// 24-byte header. Plain-old-data, written with fwrite, read with fread.
// The mask follows immediately after the header in the file.
struct RoadFileHeader
{
uint32 magic = kRoadFileMagic;
uint32 version = kRoadFileVersion;
uint32 flags = 0; // bitfield, see RoadFileFlags
uint32 mapId = 0; // for sanity check at load time
uint8 adtX = 0; // 0..63
uint8 adtY = 0; // 0..63
uint8 reserved[6] = { }; // pads to multiple of 4; future use
};
static_assert(sizeof(RoadFileHeader) == 24,
"RoadFileHeader must be exactly 24 bytes for forward compatibility");
// Per-MCNK road byte. Nonzero = MCNK is road. Currently only 0/1
// semantics are used, but the byte width is intentional so future
// extensions (e.g. road sub-types: bit 0 = dirt road, bit 1 = paved,
// bit 2 = bridge approach) can be added without a version bump as
// long as nonzero continues to mean "is road".
using RoadMaskGrid = std::array<uint8, kMcnksPerAdt>;
static_assert(sizeof(RoadMaskGrid) == 256,
"RoadMaskGrid must be exactly 256 bytes (16x16 MCNK grid)");
inline constexpr std::size_t kRoadFileSize =
sizeof(RoadFileHeader) + sizeof(RoadMaskGrid); // 280 bytes
// Compose a road-file path for a given map directory, mapId, and ADT
// coords. Mirrors the .map filename convention:
//
// maps/<NN><XX><YY>.map (existing)
// maps/<NN><XX><YY>.road (this file)
//
// where NN/XX/YY are 4-digit / 2-digit / 2-digit zero-padded.
//
// The returned string is POSIX-slash-separated; callers wrap in their
// platform's path type as needed.
inline std::string MakeRoadFilePath(std::string const& mapsDir,
uint32 mapId, uint8 adtX, uint8 adtY)
{
// Filename pattern mirrors TC's existing .map convention:
// maps/<mapId:04>_<adtX:02>_<adtY:02>.map
// → maps/<mapId:04>_<adtX:02>_<adtY:02>.road
// The underscores are required — TerrainBuilder::loadRoadMask uses
// Trinity::StringFormat("{:04}_{:02}_{:02}.road", ...) to read.
char buf[256];
std::snprintf(buf, sizeof(buf), "%s/%04u_%02u_%02u.road",
mapsDir.c_str(), mapId,
static_cast<unsigned>(adtX),
static_cast<unsigned>(adtY));
return std::string(buf);
}
}
#endif // TRINITYCORE_ROAD_MAP_DEFINES_H
+113
View File
@@ -0,0 +1,113 @@
/*
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef TRINITYCORE_WMO_ROAD_FILE_H
#define TRINITYCORE_WMO_ROAD_FILE_H
#include "Define.h"
#include <cstdint>
// ----------------------------------------------------------------------------
// WMO road-aware mmaps parallel file format.
//
// Phase 2 of the road-aware pathfinding workstream (see
// ROAD_AWARE_PATHFINDING_PLAN.md §5 + WMO_ROAD_EXTRACTION_RESEARCH.md).
//
// vmap4_extractor writes one .vmo.road sidecar alongside each .vmo it
// produces in Buildings/. The sidecar carries per-collision-triangle road
// classification verdicts for that WMO (across all its groups).
//
// File layout:
//
// [WmoRoadFileHeader (16 bytes)]
// uint32 magic 'WROD' on disk
// uint32 version 1
// uint32 nGroups count of group records following the header
// uint32 flags reserved (e.g. low_confidence_extraction marker)
//
// For each of nGroups groups (in the same order the corresponding
// groups appear in the main .vmo file):
//
// [WmoRoadGroupHeader (8 bytes)]
// uint32 nColTriangles number of collision triangles in this group
// uint32 flagsBytes count of bytes that follow = ceil(nColTriangles/8)
//
// [packed bit array]
// uint8 bits[flagsBytes] bit (i % 8) of byte (i / 8) = 1 iff
// collision triangle i has a road material
//
// Rationale for sidecar (vs extending .vmo):
// The .vmo binary format is read at runtime by VMapManager for LoS +
// collision. Extending it would force the entire vmap fleet to be
// regenerated AND break compat with any cached vmap files. The sidecar
// approach is additive — old WMOs (no .vmo.road) simply have no road
// tags applied; new ones do.
//
// Why per-collision-triangle (not just per-material bitmap):
// ConvertToVMAPGroupWmo filters source triangles by collision flag and
// only writes COLLISION triangles to .vmo. The mapping from .vmo triangle
// index → source materialId is lost. Storing the road verdict per-
// collision-triangle (after filtering) keeps the sidecar self-sufficient
// and aligned with what VMapManager loads.
// ----------------------------------------------------------------------------
namespace TrinityCore::WmoRoad
{
inline constexpr uint32 kWmoRoadMagic = 0x444F5257u; // 'D','O','R','W' on disk = "WROD"
inline constexpr uint32 kWmoRoadVersion = 1u;
enum class WmoRoadFileFlags : uint32
{
kNone = 0,
kLowConfidence = 0x1, // reserved
};
struct WmoRoadFileHeader
{
uint32 magic = kWmoRoadMagic;
uint32 version = kWmoRoadVersion;
uint32 nGroups = 0;
uint32 flags = 0;
};
struct WmoRoadGroupHeader
{
uint32 nColTriangles = 0;
uint32 flagsBytes = 0; // = (nColTriangles + 7) / 8
};
static_assert(sizeof(WmoRoadFileHeader) == 16, "header must be 16 bytes");
static_assert(sizeof(WmoRoadGroupHeader) == 8, "group header must be 8 bytes");
inline constexpr std::size_t BytesNeededForFlags(uint32 nColTriangles)
{
return (nColTriangles + 7) / 8;
}
inline bool GetTriangleRoadBit(uint8 const* bits, uint32 triangleIdx)
{
return (bits[triangleIdx / 8] >> (triangleIdx % 8)) & 1u;
}
inline void SetTriangleRoadBit(uint8* bits, uint32 triangleIdx)
{
bits[triangleIdx / 8] |= (uint8(1) << (triangleIdx % 8));
}
}
#endif // TRINITYCORE_WMO_ROAD_FILE_H
@@ -18,6 +18,8 @@
#include "WorldModel.h"
#include "MapTree.h"
#include "VMapDefinitions.h"
#include "ModelIgnoreFlags.h"
#include "WmoRoadFile.h"
#include <array>
#include <cstring>
@@ -643,6 +645,68 @@ namespace VMAP
}
fclose(rf);
// Road-aware mmaps Phase 2: attempt to load the parallel
// .vmo.road sidecar if present. Absence is normal — old WMOs
// (extracted before Phase 2) have no sidecar, and WMOs with no
// road materials also don't produce one. Failure to read is
// silent and non-fatal; the runtime path doesn't depend on this
// data.
if (result)
LoadRoadSidecar(filename);
return result;
}
void WorldModel::LoadRoadSidecar(const std::string& vmoFilename)
{
std::string sidecar = vmoFilename + ".road";
FILE* rf = fopen(sidecar.c_str(), "rb");
if (!rf)
return;
TrinityCore::WmoRoad::WmoRoadFileHeader hdr;
if (fread(&hdr, sizeof(hdr), 1, rf) != 1 ||
hdr.magic != TrinityCore::WmoRoad::kWmoRoadMagic ||
hdr.version != TrinityCore::WmoRoad::kWmoRoadVersion)
{
fclose(rf);
return;
}
uint32 nGroups = hdr.nGroups;
// The sidecar lists groups in the same order they appear in the
// .vmo. The .vmo only writes groups that pass ShouldSkip + have
// collision triangles, matching our extractor side. Iterate and
// attach flags to matching GroupModels by ordinal index.
std::size_t modelIdx = 0;
for (uint32 g = 0; g < nGroups; ++g)
{
TrinityCore::WmoRoad::WmoRoadGroupHeader gh;
if (fread(&gh, sizeof(gh), 1, rf) != 1)
break;
std::vector<uint8> packed(gh.flagsBytes);
if (gh.flagsBytes > 0 &&
fread(packed.data(), 1, gh.flagsBytes, rf) != gh.flagsBytes)
break;
// Find the next GroupModel with matching nColTriangles. We
// don't store group ordinals in the .vmo, so use a count match
// as a sanity check.
while (modelIdx < groupModels.size() &&
groupModels[modelIdx].GetTriangles().size() != gh.nColTriangles)
++modelIdx;
if (modelIdx >= groupModels.size())
break;
std::vector<uint8> flags(gh.nColTriangles, 0);
for (uint32 t = 0; t < gh.nColTriangles; ++t)
if (TrinityCore::WmoRoad::GetTriangleRoadBit(packed.data(), t))
flags[t] = 1;
groupModels[modelIdx].triangleRoadFlags = std::move(flags);
++modelIdx;
}
fclose(rf);
}
}
+14
View File
@@ -105,6 +105,14 @@ namespace VMAP
std::vector<MeshTriangle> triangles;
BIH meshTree;
WmoLiquid* iLiquid;
public:
// Road-aware mmaps Phase 2: optional per-triangle road flag.
// Parallel to `triangles` (one byte per collision triangle).
// Populated from the .vmo.road sidecar in WorldModel::readFile
// (mmaps_generator's path). Empty when no sidecar exists —
// runtime LoS/collision queries don't consult this field, so
// adding it has no behavioral impact for the worldserver.
std::vector<uint8> triangleRoadFlags;
};
struct WorldModelLocationInfoQueryResult
@@ -130,6 +138,12 @@ namespace VMAP
bool readFile(const std::string &filename);
bool IsM2() const { return Flags.HasFlag(ModelFlags::IsM2); }
std::vector<GroupModel> const& getGroupModels() const { return groupModels; }
// Road-aware mmaps Phase 2: load the optional .vmo.road sidecar
// (filename + ".road") and populate per-group triangleRoadFlags.
// Called from readFile() — silent no-op when sidecar is absent
// or has unknown magic/version. Public for testability.
void LoadRoadSidecar(const std::string &vmoFilename);
protected:
EnumFlag<ModelFlags> Flags;
uint32 RootWMOID;
@@ -4,6 +4,7 @@
// FILE: WheatyExceptionReport.CPP
//==========================================
#include "WheatyExceptionReport.h"
#include "AppenderCrashRing.h"
#include "Errors.h"
#include "GitRevision.h"
#include "Memory.h"
@@ -224,6 +225,21 @@ LONG WheatyExceptionReport::UnhandledExceptionFilterImpl(PEXCEPTION_POINTERS pEx
m_reportFile = nullptr;
}
// the last log lines before the crash ({same name}.log): what the server was doing, not only where it stopped
{
static char lastLines[1 << 17]; // static: the heap may be what is corrupted
size_t const length = AppenderCrashRing::Snapshot(lastLines, sizeof(lastLines));
if (length)
{
_tcscpy_s(crashPath, m_tempPathBufferChars - (crashPath - m_tempPathBuffer), _T("log"));
if (FILE* logFile = _tfopen(m_tempPathBuffer, _T("wb")))
{
fwrite(lastLines, 1, length, logFile);
fclose(logFile);
}
}
}
if (m_previousFilter)
return m_previousFilter(pExceptionInfo);
else
+5
View File
@@ -33,6 +33,11 @@ char const* GitRevision::GetBranch()
return TRINITY_GIT_COMMIT_BRANCH;
}
char const* GitRevision::GetUpstreamPin()
{
return FOREVER_UPSTREAM_PIN;
}
char const* GitRevision::GetCMakeCommand()
{
return TRINITY_BUILD_CMAKE_COMMAND;
+1
View File
@@ -25,6 +25,7 @@ namespace GitRevision
TC_COMMON_API char const* GetHash();
TC_COMMON_API char const* GetDate();
TC_COMMON_API char const* GetBranch();
TC_COMMON_API char const* GetUpstreamPin();
TC_COMMON_API char const* GetCMakeCommand();
TC_COMMON_API char const* GetCMakeVersion();
TC_COMMON_API char const* GetHostOSVersion();
+83
View File
@@ -0,0 +1,83 @@
/*
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "AppenderCrashRing.h"
#include "LogMessage.h"
#include "StringConvert.h"
#include <algorithm>
#include <atomic>
#include <cstring>
namespace
{
// Fixed storage: the crash handler reads it without taking a lock or allocating. Log messages reach the appenders one at a time (one
// strand), so the writer needs no lock either; a line being written while the process dies may come out cut, which is acceptable.
char s_lines[AppenderCrashRing::MaxLines][AppenderCrashRing::LineChars];
std::atomic<uint64> s_written{ 0 }; // total lines ever written
std::atomic<uint32> s_capacity{ 200 }; // lines kept (configurable, at most MaxLines)
}
AppenderCrashRing::AppenderCrashRing(uint8 id, std::string name, LogLevel level, AppenderFlags flags, std::vector<std::string_view> const& args) :
Appender(id, std::move(name), level, flags)
{
if (args.size() > 3)
{
Optional<uint32> lines = Trinity::StringTo<uint32>(args[3]);
if (!lines || *lines == 0 || *lines > MaxLines)
throw InvalidAppenderArgsException("Log::CreateAppenderFromConfig: crash ring appender needs a line count between 1 and 1024");
s_capacity = *lines;
}
}
void AppenderCrashRing::_write(LogMessage const* message)
{
uint64 const index = s_written.load(std::memory_order_relaxed);
char* slot = s_lines[index % s_capacity.load(std::memory_order_relaxed)];
size_t length = std::min<size_t>(message->prefix.size(), LineChars - 1);
std::memcpy(slot, message->prefix.data(), length);
size_t const textLength = std::min<size_t>(message->text.size(), LineChars - 1 - length);
std::memcpy(slot + length, message->text.data(), textLength);
length += textLength;
slot[length] = '\0';
s_written.store(index + 1, std::memory_order_release);
}
size_t AppenderCrashRing::Snapshot(char* out, size_t capacity)
{
if (!out || !capacity)
return 0;
uint64 const written = s_written.load(std::memory_order_acquire);
uint32 const kept = s_capacity.load(std::memory_order_relaxed);
uint64 const first = written > kept ? written - kept : 0;
size_t used = 0;
for (uint64 i = first; i < written; ++i)
{
char const* line = s_lines[i % kept];
size_t const length = strnlen(line, LineChars);
if (used + length + 2 > capacity)
break;
std::memcpy(out + used, line, length);
used += length;
out[used++] = '\n';
}
out[used] = '\0';
return used;
}
+47
View File
@@ -0,0 +1,47 @@
/*
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef APPENDERCRASHRING_H
#define APPENDERCRASHRING_H
#include "Appender.h"
#include <vector>
/// Keeps the last log lines in a fixed block of memory so that a crash report can print what the server was doing right before it
/// died (no file to flush, no allocation at crash time). Config: `Appender.CrashRing=4,3,7` (type 4, info and above, with timestamp,
/// level and filter prefix), optional1 = number of lines kept (default 200, at most 1024); link it to the loggers whose lines should
/// appear (`Logger.root=5,Console Server CrashRing`, `Logger.playerbot.v2=3,Playerbot CrashRing`).
class TC_COMMON_API AppenderCrashRing : public Appender
{
public:
static constexpr AppenderType type = APPENDER_CRASH_RING;
static constexpr uint32 MaxLines = 1024;
static constexpr uint32 LineChars = 480;
AppenderCrashRing(uint8 id, std::string name, LogLevel level, AppenderFlags flags, std::vector<std::string_view> const& args);
AppenderType getType() const override { return type; }
/// Copies the kept lines, oldest first, one per '\n', into `out` (at most `capacity` bytes, NUL terminated). Only reads fixed
/// memory, so it is safe to call from the crash handler. Returns the number of bytes written (without the NUL).
static size_t Snapshot(char* out, size_t capacity);
private:
void _write(LogMessage const* message) override;
};
#endif
+37
View File
@@ -20,12 +20,14 @@
#include "LogMessage.h"
#include "StringConvert.h"
#include <algorithm>
#include <filesystem>
AppenderFile::AppenderFile(uint8 id, std::string name, LogLevel level, AppenderFlags flags, std::vector<std::string_view> const& args) :
Appender(id, std::move(name), level, flags),
logfile(nullptr),
_logDir(sLog->GetLogsDir()),
_maxFileSize(0),
_maxBackups(0),
_fileSize(0)
{
if (args.size() < 4)
@@ -54,6 +56,15 @@ AppenderFile::AppenderFile(uint8 id, std::string name, LogLevel level, AppenderF
throw InvalidAppenderArgsException(Trinity::StringFormat("Log::CreateAppenderFromConfig: Invalid size '{}' for appender {}", args[5], name));
}
// optional4: how many rotated backups of this file to keep (0 = all). Together with MaxFileSize this caps the disk the log can use.
if (6 < args.size())
{
if (Optional<uint32> backups = Trinity::StringTo<uint32>(args[6]))
_maxBackups = *backups;
else
throw InvalidAppenderArgsException(Trinity::StringFormat("Log::CreateAppenderFromConfig: Invalid backup count '{}' for appender {}", args[6], name));
}
_dynamicName = std::string::npos != _fileName.find("%s");
_backup = (flags & APPENDER_FLAGS_MAKE_FILE_BACKUP) != 0;
@@ -110,6 +121,7 @@ FILE* AppenderFile::OpenFile(std::string const& filename, std::string const& mod
newName.append(LogMessage::getTimeStr(time(nullptr)));
std::replace(newName.begin(), newName.end(), ':', '-');
rename(fullName.c_str(), newName.c_str()); // no error handling... if we couldn't make a backup, just ignore
PruneBackups(fullName);
}
if (FILE* ret = fopen(fullName.c_str(), mode.c_str()))
@@ -121,6 +133,31 @@ FILE* AppenderFile::OpenFile(std::string const& filename, std::string const& mod
return nullptr;
}
// Backups are named "<file>.<timestamp>" (see OpenFile); removes the oldest ones beyond _maxBackups.
void AppenderFile::PruneBackups(std::string const& fullName) const
{
if (!_maxBackups)
return;
namespace sfs = std::filesystem;
std::error_code ec;
sfs::path const file(fullName);
std::string const prefix = file.filename().string() + ".";
std::vector<sfs::path> backups;
for (sfs::directory_entry const& entry : sfs::directory_iterator(file.parent_path().empty() ? sfs::path(".") : file.parent_path(), ec))
if (entry.is_regular_file(ec) && entry.path().filename().string().starts_with(prefix))
backups.push_back(entry.path());
if (backups.size() <= _maxBackups)
return;
// the timestamp is part of the name, so the names sort oldest first
std::ranges::sort(backups);
for (size_t i = 0; i < backups.size() - _maxBackups; ++i)
sfs::remove(backups[i], ec);
}
void AppenderFile::CloseFile()
{
if (logfile)
+2
View File
@@ -34,6 +34,7 @@ class TC_COMMON_API AppenderFile : public Appender
private:
void CloseFile();
void PruneBackups(std::string const& fullName) const;
void _write(LogMessage const* message) override;
FILE* logfile;
std::string _fileName;
@@ -41,6 +42,7 @@ class TC_COMMON_API AppenderFile : public Appender
bool _dynamicName;
bool _backup;
uint64 _maxFileSize;
uint32 _maxBackups;
std::atomic<uint64> _fileSize;
};
+2
View File
@@ -17,6 +17,7 @@
#include "Log.h"
#include "AppenderConsole.h"
#include "AppenderCrashRing.h"
#include "AppenderFile.h"
#include "Config.h"
#include "Errors.h"
@@ -32,6 +33,7 @@ Log::Log() : AppenderId(0), lowestLogLevel(LOG_LEVEL_FATAL), m_logsTimestamp('_'
{
RegisterAppender<AppenderConsole>();
RegisterAppender<AppenderFile>();
RegisterAppender<AppenderCrashRing>();
}
Log::~Log()
+1
View File
@@ -42,6 +42,7 @@ enum AppenderType : uint8
APPENDER_CONSOLE,
APPENDER_FILE,
APPENDER_DB,
APPENDER_CRASH_RING,
APPENDER_INVALID = 0xFF // SKIP
};
+4 -1
View File
@@ -89,12 +89,13 @@ TC_API_EXPORT EnumText EnumUtils<AppenderType>::ToString(AppenderType value)
case APPENDER_CONSOLE: return { "APPENDER_CONSOLE", "APPENDER_CONSOLE", "" };
case APPENDER_FILE: return { "APPENDER_FILE", "APPENDER_FILE", "" };
case APPENDER_DB: return { "APPENDER_DB", "APPENDER_DB", "" };
case APPENDER_CRASH_RING: return { "APPENDER_CRASH_RING", "APPENDER_CRASH_RING", "" };
default: throw std::out_of_range("value");
}
}
template <>
TC_API_EXPORT size_t EnumUtils<AppenderType>::Count() { return 4; }
TC_API_EXPORT size_t EnumUtils<AppenderType>::Count() { return 5; }
template <>
TC_API_EXPORT AppenderType EnumUtils<AppenderType>::FromIndex(size_t index)
@@ -105,6 +106,7 @@ TC_API_EXPORT AppenderType EnumUtils<AppenderType>::FromIndex(size_t index)
case 1: return APPENDER_CONSOLE;
case 2: return APPENDER_FILE;
case 3: return APPENDER_DB;
case 4: return APPENDER_CRASH_RING;
default: throw std::out_of_range("index");
}
}
@@ -118,6 +120,7 @@ TC_API_EXPORT size_t EnumUtils<AppenderType>::ToIndex(AppenderType value)
case APPENDER_CONSOLE: return 1;
case APPENDER_FILE: return 2;
case APPENDER_DB: return 3;
case APPENDER_CRASH_RING: return 4;
default: throw std::out_of_range("value");
}
}
@@ -0,0 +1,146 @@
#include "RoadOverrides.h"
#include "Log.h"
#include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <fstream>
#include <sstream>
#include <string>
namespace MMAP
{
RoadOverrides& RoadOverrides::Instance()
{
static RoadOverrides inst;
return inst;
}
namespace
{
// CSV parser tolerant of:
// * blank lines
// * #-prefixed comment lines
// * trailing whitespace
// * quoted fields containing commas (rare — operator labels)
// Returns false on a record whose required fields can't be parsed.
// Records with kind != 1 are skipped silently (caller observes via
// non-incrementing count).
bool ParseLine(std::string const& line, RoadOverridePoint& out, uint32& kind_out)
{
// Skip blank / comment
size_t i = 0;
while (i < line.size() && std::isspace(static_cast<unsigned char>(line[i]))) ++i;
if (i >= line.size() || line[i] == '#') return false;
// Field order (from `.playerbot meta export`):
// id,map_id,zone_id,kind,kind_name,x,y,z,radius,label,notes
std::vector<std::string> fields;
std::string cur;
bool in_quote = false;
for (size_t p = i; p < line.size(); ++p)
{
char c = line[p];
if (in_quote)
{
if (c == '"') in_quote = false;
else cur.push_back(c);
}
else if (c == '"')
in_quote = true;
else if (c == ',')
{ fields.push_back(std::move(cur)); cur.clear(); }
else
cur.push_back(c);
}
fields.push_back(std::move(cur));
// Need at least 9 fields (through radius). label/notes optional.
if (fields.size() < 9) return false;
// Use strtoull / strtod for resilience to whitespace.
// id is fields[0] — not stored on out (we use the cache).
out.map_id = static_cast<uint32>(std::strtoul(fields[1].c_str(), nullptr, 10));
// zone_id (fields[2]) ignored.
kind_out = static_cast<uint32>(std::strtoul(fields[3].c_str(), nullptr, 10));
// kind_name (fields[4]) ignored (redundant with kind).
out.x = static_cast<float>(std::strtod(fields[5].c_str(), nullptr));
out.y = static_cast<float>(std::strtod(fields[6].c_str(), nullptr));
out.z = static_cast<float>(std::strtod(fields[7].c_str(), nullptr));
out.radius = static_cast<float>(std::strtod(fields[8].c_str(), nullptr));
if (out.radius <= 0.0f) out.radius = 10.0f;
return true;
}
}
int RoadOverrides::LoadFromFile(std::string const& csv_path)
{
std::ifstream in(csv_path);
if (!in)
{
// Not an error — file is opt-in
TC_LOG_INFO("maps.mmapgen",
"[RoadOverrides] no override CSV at '{}'; skipping",
csv_path);
return 0;
}
road_points_.clear();
road_points_.reserve(256);
std::string line;
int loaded = 0;
int skipped = 0;
int malformed = 0;
while (std::getline(in, line))
{
RoadOverridePoint p{};
uint32 kind = 0;
if (!ParseLine(line, p, kind))
{
// ParseLine returns false for blank / comment / malformed.
// We can't distinguish blanks from malformed without
// pre-trimming — so we accept the noise; only complain
// visibly if a row WITH a kind=1 prefix fails. Cheap.
if (!line.empty() && line[0] != '#')
++malformed;
continue;
}
if (kind != 1) { ++skipped; continue; }
road_points_.push_back(p);
++loaded;
}
TC_LOG_INFO("maps.mmapgen",
"[RoadOverrides] loaded {} road-kind row(s) from {} "
"({} non-road kinds skipped, {} malformed)",
loaded, csv_path, skipped, malformed);
return loaded;
}
std::vector<RoadOverridePoint>
RoadOverrides::PointsOverlappingTile(uint32 map_id,
float minX, float minZ,
float maxX, float maxZ) const
{
std::vector<RoadOverridePoint> out;
if (road_points_.empty()) return out;
// The tile bbox in TC navmesh coords: minX/maxX bound world X,
// minZ/maxZ bound world Z (== world Y in TC's name conventions).
// The override point's (x, y) are in TC world XY. We need to
// compare TC-X against minX..maxX and TC-Y against minZ..maxZ.
// Expand the rect by the override's radius so points just outside
// whose circle reaches in still get returned.
out.reserve(16);
for (auto const& p : road_points_)
{
if (p.map_id != map_id) continue;
const float r = p.radius;
if (p.x < minX - r || p.x > maxX + r) continue;
if (p.y < minZ - r || p.y > maxZ + r) continue;
out.push_back(p);
}
return out;
}
} // namespace MMAP
@@ -0,0 +1,82 @@
// RoadOverrides — operator-curated road waypoints loaded at mmaps_generator
// startup, applied to navmesh polygons by TileBuilder's road post-pass.
//
// Purpose: Bridge the gap between the texture-based road classifier and
// the actual roads that the classifier misses. The classic example is
// Teldrassil: the `tileset/kalidar/*road*` textures resolve in the
// listfile and the classifier's substring matcher tags them as road,
// but `RoadConfidenceFromEffectId() > 0.3` rejects them (the doodad-
// density signal labels Teldrassil's road MCNKs as "vegetated" because
// the cobblestone is rendered as a thin alpha-blended layer on top of
// ferns/wood ground). The result: 0 road bits in .road files for every
// Teldrassil tile despite road textures being referenced.
//
// Solution: a GM in-game uses `.playerbot meta add road` to capture
// waypoints along the actual visible road. The command writes both DB
// (characters.playerbot_v2_world_metadata) and an export CSV that
// mmaps_generator reads at regen time. For each waypoint, polygons
// whose centroid lies within `radius` get tagged NAV_AREA_ROAD — exactly
// the same area tag the texture classifier would have set.
//
// CSV format (one row per metadata point; lines starting with # ignored):
// id,map_id,zone_id,kind,kind_name,x,y,z,radius,label,notes
//
// mmaps_generator reads ONLY `kind=1` (Road) rows. Other kinds are
// ignored by the generator but persist in the same file because the
// editor exports the whole metadata table.
//
// Auto-discovery: the consumer looks for `<input>/world_metadata.csv`
// at startup (no CLI flag needed). Operators can also pass
// `--roadOverrides <path>` to point at a different file.
#pragma once
#include "Define.h"
#include <cstdint>
#include <string>
#include <vector>
namespace MMAP
{
struct RoadOverridePoint
{
uint32 map_id;
float x;
float y;
float z;
float radius;
};
class RoadOverrides
{
public:
static RoadOverrides& Instance();
// Load from CSV. Returns count of road-kind rows loaded.
// Returns 0 if the file is absent (not an error — overrides
// are opt-in). Returns -1 on malformed file.
int LoadFromFile(std::string const& csv_path);
bool Empty() const { return road_points_.empty(); }
size_t Size() const { return road_points_.size(); }
// Filter to points within the bounding rect of a tile, expanded
// by the maximum override radius so points just outside the
// rect whose radius reaches into it are still considered. The
// caller (TileBuilder) does per-polygon distance check.
std::vector<RoadOverridePoint>
PointsOverlappingTile(uint32 map_id,
float minX, float minZ,
float maxX, float maxZ) const;
private:
RoadOverrides() = default;
RoadOverrides(RoadOverrides const&) = delete;
RoadOverrides& operator=(RoadOverrides const&) = delete;
// All kind=1 (Road) points; other kinds dropped on load.
// Hundreds-of-points scale max, so a linear scan per tile is
// fine (only runs at mmaps_generator regen, not at runtime).
std::vector<RoadOverridePoint> road_points_;
};
}
@@ -22,9 +22,11 @@
#include "MMapDefines.h"
#include "Memory.h"
#include "ModelInstance.h"
#include "RoadMapDefines.h"
#include "StringFormat.h"
#include "Util.h"
#include "VMapManager.h"
#include <cstring>
#include <unordered_map>
namespace MMAP
@@ -79,9 +81,63 @@ namespace MMAP
loadMap(mapID, tileX, tileY-1, meshData, vmapManager, RIGHT);
loadMap(mapID, tileX+1, tileY, meshData, vmapManager, TOP);
loadMap(mapID, tileX-1, tileY, meshData, vmapManager, BOTTOM);
// Road-aware mmaps: opportunistic load of the parallel .road file
// for the center tile. Absence is fine — meshData.roadMask stays
// zero and TileBuilder behaves as it did pre-feature.
loadRoadMask(mapID, tileX, tileY, meshData);
}
}
bool TerrainBuilder::loadRoadMask(uint32 mapID, uint32 tileX, uint32 tileY, MeshData& meshData)
{
// The road extractor writes <mapID>_<tileX>_<tileY> in the order the
// map extractor expects (see System.cpp's WriteRoadFileForAdt call).
// Note the historical TileX vs ADT-x: the existing TC convention
// passes (tileX, tileY) where tileX corresponds to the ADT row index
// and tileY to the column when read by MapBuilder. We mirror the
// exact .map filename pattern for the .road sibling.
std::string roadFileName = Trinity::StringFormat("{}/maps/{:04}_{:02}_{:02}.road",
m_inputDirectory.generic_string(), mapID, tileX, tileY);
auto roadFile = Trinity::make_unique_ptr_with_deleter<&::fclose>(fopen(roadFileName.c_str(), "rb"));
if (!roadFile)
{
// Absent file is normal — see header comment.
meshData.hasRoadMask = false;
return false;
}
TrinityCore::RoadMap::RoadFileHeader header;
if (fread(&header, sizeof(header), 1, roadFile.get()) != 1)
{
TC_LOG_ERROR("maps.mmapgen", "Could not read .road header for {}", roadFileName);
return false;
}
if (header.magic != TrinityCore::RoadMap::kRoadFileMagic)
{
TC_LOG_ERROR("maps.mmapgen", "{} has wrong magic (got 0x{:x})", roadFileName, header.magic);
return false;
}
if (header.version != TrinityCore::RoadMap::kRoadFileVersion)
{
TC_LOG_ERROR("maps.mmapgen", "{} has unknown version {} (expected {})",
roadFileName, header.version, TrinityCore::RoadMap::kRoadFileVersion);
return false;
}
if (fread(meshData.roadMask.data(), meshData.roadMask.size(), 1, roadFile.get()) != 1)
{
TC_LOG_ERROR("maps.mmapgen", "Could not read .road mask for {}", roadFileName);
std::memset(meshData.roadMask.data(), 0, meshData.roadMask.size());
return false;
}
meshData.hasRoadMask = true;
return true;
}
/**************************************************************************/
bool TerrainBuilder::loadMap(uint32 mapID, uint32 tileX, uint32 tileY, MeshData& meshData, VMAP::VMapManager* vmapManager, Spot portion)
{
@@ -616,8 +672,25 @@ namespace MMAP
{
// first handle collision mesh
int offset = meshData.solidVerts.size() / 3;
std::size_t triCountBefore = meshData.solidTris.size() / 3;
transformVertices(it->GetVertices(), meshData.solidVerts, scale, rotation, position);
copyIndices(it->GetTriangles(), meshData.solidTris, offset, isM2);
std::size_t triCountAfter = meshData.solidTris.size() / 3;
std::size_t trianglesAdded = triCountAfter - triCountBefore;
// Road-aware mmaps Phase 2: extend solidTriRoadFlags in parallel
// to solidTris. If this group has road flags from the sidecar,
// copy them in; otherwise pad with zeros.
meshData.solidTriRoadFlags.resize(triCountAfter, 0);
std::vector<uint8> const& groupFlags = it->triangleRoadFlags;
if (!groupFlags.empty() && groupFlags.size() == it->GetTriangles().size())
{
// The group's triangle count must match what copyIndices
// appended (this->GetTriangles().size()). M2 triangle flip
// doesn't change count, so 1:1 mapping holds.
for (std::size_t i = 0; i < trianglesAdded && i < groupFlags.size(); ++i)
meshData.solidTriRoadFlags[triCountBefore + i] = groupFlags[i];
}
// now handle liquid data
VMAP::WmoLiquid const* liquid = it->GetLiquid();
@@ -21,6 +21,7 @@
#include "MMapDefines.h"
#include "WorldModel.h"
#include <G3D/Vector3.h>
#include <array>
#include <boost/filesystem/path.hpp>
namespace VMAP
@@ -51,7 +52,7 @@ namespace MMAP
static const int V9_SIZE_SQ = V9_SIZE*V9_SIZE;
static const int V8_SIZE = 128;
static const int V8_SIZE_SQ = V8_SIZE*V8_SIZE;
static const float GRID_SIZE = 533.3333f;
static constexpr float GRID_SIZE = 533.3333f;
static const float GRID_PART_SIZE = GRID_SIZE/V8_SIZE;
// see contrib/extractor/system.cpp, CONF_use_minHeight
@@ -77,6 +78,22 @@ namespace MMAP
std::vector<unsigned char> offMeshConnectionDirs;
std::vector<unsigned char> offMeshConnectionsAreas;
std::vector<unsigned short> offMeshConnectionsFlags;
// Road-aware mmaps: per-MCNK road mask sourced from the parallel
// <map>_<x>_<y>.road file. Indexed [iy * 16 + ix]; nonzero means
// "this MCNK's dominant texture is a road". TileBuilder consults
// this when assigning polygon area tags. Default-zeroed when no
// .road file is present (legacy maps, road extraction disabled).
std::array<uint8, 256> roadMask{};
bool hasRoadMask = false;
// Road-aware mmaps Phase 2 (WMO): per-triangle road flag, parallel
// to `solidTris` (one byte per triangle in `solidTris` / 3).
// Populated by TerrainBuilder::loadVMapModel from each GroupModel's
// triangleRoadFlags (which the WorldModel reader loads from the
// sidecar). Triangles from terrain MCNKs leave the byte = 0.
// TileBuilder consults this when seeding triangle area_id.
std::vector<uint8> solidTriRoadFlags;
};
class TC_MMAPS_COMMON_API TerrainBuilder
@@ -85,6 +102,13 @@ namespace MMAP
explicit TerrainBuilder(boost::filesystem::path const& inputDirectory, bool skipLiquid);
void loadMap(uint32 mapID, uint32 tileX, uint32 tileY, MeshData& meshData, VMAP::VMapManager* vmapManager);
// Loads the optional parallel road-mask file for the given ADT.
// Populates meshData.roadMask + meshData.hasRoadMask. No-op when
// the .road file is absent (legacy map, road extraction disabled).
// Returns true if a road file was found and parsed.
bool loadRoadMask(uint32 mapID, uint32 tileX, uint32 tileY, MeshData& meshData);
bool loadVMap(uint32 mapID, uint32 tileX, uint32 tileY, MeshData& meshData, VMAP::VMapManager* vmapManager);
void loadVMapModel(VMAP::WorldModel const* worldModel, G3D::Vector3 const& position, G3D::Matrix3 const& rotation, float scale,
MeshData& meshData, VMAP::VMapManager* vmapManager);
+632 -12
View File
@@ -20,9 +20,61 @@
#include "Log.h"
#include "MMapDefines.h"
#include "Memory.h"
#include "RoadOverrides.h"
#include "StringFormat.h"
#include "VMapManager.h"
#include <DetourNavMeshBuilder.h>
#include <cmath>
#include <limits>
#include <queue>
#include <vector>
// Generator tuning overrides (see MMapDefines.h). Default-constructed =
// partition Layers + all sentinels, i.e. the existing fork behaviour. The
// mmaps_generator CLI mutates this once before tile building begins.
MmapGenTuning g_mmapGenTuning;
#ifdef _WIN32
#ifndef NOMINMAX
#define NOMINMAX // windows.h min/max macros break std::min/max below
#endif
#include <windows.h>
namespace
{
// Plain C++ relay so the SEH frame below stays destructor-free
// (MSVC C2712: __try cannot coexist with object unwinding).
void DoBuildMoveMapTile(MMAP::TileBuilder* b, uint32 mapID, uint32 tileX, uint32 tileY,
MMAP::MeshData* meshData, float* bmin, float* bmax,
dtNavMeshParams const* params,
MMAP::TileBuilder::TileResult* outResult)
{
*outResult = b->buildMoveMapTile(mapID, tileX, tileY, *meshData,
*reinterpret_cast<float(*)[3]>(bmin),
*reinterpret_cast<float(*)[3]>(bmax),
params);
}
}
// SEH guard for one tile build. Recast can ACCESS_VIOLATION on degenerate
// input geometry (observed 2026-06-12: rcBuildPolyMesh removeVertex AV on
// Eastern Kingdoms tiles fed by the fixed vmap extractor's much richer WMO
// collision — killed the whole world build at tile 853). One poisoned tile
// must not abort a multi-hour batch: skip it, report it, keep going.
extern "C" unsigned int SehSafeBuildMoveMapTile(
MMAP::TileBuilder* b, unsigned int mapID, unsigned int tileX, unsigned int tileY,
MMAP::MeshData* meshData, float* bmin, float* bmax,
dtNavMeshParams const* params, MMAP::TileBuilder::TileResult* outResult) noexcept
{
__try
{
DoBuildMoveMapTile(b, mapID, tileX, tileY, meshData, bmin, bmax, params, outResult);
return 0;
}
__except (EXCEPTION_EXECUTE_HANDLER)
{
return GetExceptionCode();
}
}
#endif
namespace
{
@@ -94,6 +146,13 @@ namespace MMAP
}
TC_LOG_INFO("maps.mmapgen", "{} [Map {:04}] Building tile [{:02},{:02}]", GetProgressText(), mapID, tileX, tileY);
// Unbuffered breadcrumb: TC_LOG console output is block-buffered
// through redirected pipes and is LOST on a hard crash (observed
// 2026-06-12: three 0-byte logs from heap-corruption deaths). This
// stderr line + flush survives, so the crash log names the in-
// flight tiles. Cheap (one line per tile) — keep.
std::fprintf(stderr, "[tile-begin] map=%04u tile=%02u,%02u\n", mapID, tileX, tileY);
std::fflush(stderr);
MeshData meshData;
@@ -135,7 +194,23 @@ namespace MMAP
m_terrainBuilder.loadOffMeshConnections(mapID, tileX, tileY, meshData, *m_offMeshConnections);
// build navmesh tile
TileResult tileResult = buildMoveMapTile(mapID, tileX, tileY, meshData, bmin, bmax, navMesh->getParams());
TileResult tileResult;
#ifdef _WIN32
// SEH-guarded: a Recast AV on degenerate geometry skips THIS tile
// instead of killing the whole batch (see SehSafeBuildMoveMapTile).
if (unsigned int seh = SehSafeBuildMoveMapTile(this, mapID, tileX, tileY,
&meshData, bmin, bmax, navMesh->getParams(), &tileResult))
{
TC_LOG_ERROR("maps.mmapgen",
"[Map {:04}] SEH 0x{:08X} building tile [{:02},{:02}] — SKIPPED "
"(degenerate input geometry?)",
mapID, seh, tileX, tileY);
OnTileDone();
return;
}
#else
tileResult = buildMoveMapTile(mapID, tileX, tileY, meshData, bmin, bmax, navMesh->getParams());
#endif
if (tileResult.data)
saveMoveMapTileToFile(mapID, tileX, tileY, navMesh, tileResult);
@@ -224,6 +299,43 @@ namespace MMAP
memset(triFlags.get(), NAV_AREA_GROUND_STEEP, tTriCount * sizeof(unsigned char));
rcClearUnwalkableTriangles(&m_rcContext, tileCfg.walkableSlopeAngle, tVerts, tVertCount, tTris, tTriCount, triFlags.get());
rcMarkWalkableTriangles(&m_rcContext, tileCfg.walkableSlopeAngleNotSteep, tVerts, tVertCount, tTris, tTriCount, triFlags.get(), NAV_AREA_GROUND);
// Road-aware mmaps Phase 2 (WMO): promote triangles whose
// GroupModel material is a road texture (sidecar-flagged)
// to NAV_AREA_ROAD. Run AFTER rcMarkWalkableTriangles so we
// override its NAV_AREA_GROUND for the road triangles.
// Triangles without a road flag keep whatever
// ClearUnwalkable / MarkWalkable assigned (GROUND, STEEP,
// or RC_NULL_AREA for too-steep).
//
// Texture detector tags stone-textured mountains as roads —
// curated handcrafted_road/RoadOverrides are the road
// sources; audit 2026-07-03. This WMO-sidecar signal is
// texture-classifier derived, so only consume it under
// --textureRoads (default off).
if (g_mmapGenTuning.textureRoads && !meshData.solidTriRoadFlags.empty())
{
int promoted = 0;
int limit = std::min<int>(tTriCount, static_cast<int>(meshData.solidTriRoadFlags.size()));
for (int i = 0; i < limit; ++i)
{
if (meshData.solidTriRoadFlags[i] != 0 &&
triFlags[i] != RC_NULL_AREA)
{
triFlags[i] = NAV_AREA_ROAD;
++promoted;
}
}
if (promoted > 0)
meshData.hasRoadMask = true; // signal post-pass to run
}
else if (!meshData.solidTriRoadFlags.empty())
{
// Present on disk but ignored by policy — flagged for the
// one-line-per-run summary in PathGenerator.cpp.
g_mmapGenTuning.textureRoadsIgnoredSeen.store(true, std::memory_order_relaxed);
}
rcRasterizeTriangles(&m_rcContext, tVerts, tVertCount, tTris, triFlags.get(), tTriCount, *tile.solid, config.walkableClimb);
rcFilterLowHangingWalkableObstacles(&m_rcContext, config.walkableClimb, *tile.solid);
@@ -254,13 +366,90 @@ namespace MMAP
continue;
}
if (!rcBuildDistanceField(&m_rcContext, *tile.chf))
// Region partitioning — selectable via g_mmapGenTuning.partition
// (mmaps_generator --partition). The fork default is Layers
// (rcBuildLayerRegions), chosen 2026-05-21 after probe-based
// validation: watershed produced disconnected polygon islands
// for spiral-stair / multi-floor WMOs (Aldrassil's Tenaron
// Stormgrip room was unreachable — ground polys and upper-floor
// polys landed in separate regions with no edges between them).
//
// Recast docs (Mikko Mononen): watershed yields the nicest,
// most regular regions on open terrain but overlaps/holes in
// "narrow spiral corridors e.g. spiral stairs"; monotone never
// produces holes (long thin polys instead); layered is the
// middle ground and links multi-floor geometry. RecastDemo's
// "indoor" sample uses MONOTONE for exactly this reason.
//
// Watershed is the only method that needs the distance field,
// so it is built only on that branch (saves work on the others).
// Source ref: src/modules/PlayerbotV2/docs/MMAP_PARAMETER_TUNING.md
// Resolve the effective method. Auto picks PER SUBTILE from the
// compact-heightfield's vertical-layering fraction — the fraction
// of occupied cells carrying >=2 walkable spans (i.e. a floor with
// something walkable above it: bridges, multi-floor WMOs, caves).
// That 2.5D signal is the principled discriminator: open terrain
// is ~0 layered, a barrow-den/tower tile is materially layered.
// >0.06 -> Layers (link the floors; the connectivity win)
// <0.005 -> Watershed (flat/open: smoothest, most regular)
// else -> Monotone (mixed: never holes, predictable)
MmapPartitionMethod method = g_mmapGenTuning.partition;
// Instanced dungeon/raid maps: the Layers default islands
// winding WMO mine tunnels into disconnected navmesh regions
// (Deadmines foundry — root-caused + live-validated 2026-07-01;
// Monotone meshes the tunnels and does NOT regress multi-floor
// linkage, Aldrassil verified). Switch such maps Layers->Monotone
// unless the operator gave an explicit --partition.
if (!g_mmapGenTuning.partitionExplicit
&& method == MmapPartitionMethod::Layers
&& g_mmapGenTuning.instanceMaps.count(mapID))
method = MmapPartitionMethod::Monotone;
if (method == MmapPartitionMethod::Auto)
{
TC_LOG_ERROR("maps.mmapgen", "{} Failed building distance field!", tileString);
continue;
uint32 occupied = 0, layered = 0;
const int cellCount = tile.chf->width * tile.chf->height;
for (int ci = 0; ci < cellCount; ++ci)
{
const rcCompactCell& cc = tile.chf->cells[ci];
if (cc.count == 0) continue;
++occupied;
if (cc.count >= 2) ++layered;
}
const float layeredFrac = occupied ? float(layered) / float(occupied) : 0.f;
if (layeredFrac > 0.06f) method = MmapPartitionMethod::Layers;
else if (layeredFrac < 0.005f) method = MmapPartitionMethod::Watershed;
else method = MmapPartitionMethod::Monotone;
}
if (!rcBuildRegions(&m_rcContext, *tile.chf, tileCfg.borderSize, tileCfg.minRegionArea, tileCfg.mergeRegionArea))
bool regionOk = false;
switch (method)
{
case MmapPartitionMethod::Watershed:
if (!rcBuildDistanceField(&m_rcContext, *tile.chf))
{
TC_LOG_ERROR("maps.mmapgen", "{} Failed building distance field!", tileString);
break;
}
regionOk = rcBuildRegions(&m_rcContext, *tile.chf,
tileCfg.borderSize, tileCfg.minRegionArea, tileCfg.mergeRegionArea);
break;
case MmapPartitionMethod::Monotone:
regionOk = rcBuildRegionsMonotone(&m_rcContext, *tile.chf,
tileCfg.borderSize, tileCfg.minRegionArea, tileCfg.mergeRegionArea);
break;
case MmapPartitionMethod::Layers:
default:
regionOk = rcBuildLayerRegions(&m_rcContext, *tile.chf,
tileCfg.borderSize, tileCfg.minRegionArea);
break;
}
// Safety net: if watershed/monotone failed on this subtile, fall
// back to layered (the most robust for our multi-floor geometry)
// so a partitioner hiccup never silently drops the subtile.
if (!regionOk && method != MmapPartitionMethod::Layers)
regionOk = rcBuildLayerRegions(&m_rcContext, *tile.chf,
tileCfg.borderSize, tileCfg.minRegionArea);
if (!regionOk)
{
TC_LOG_ERROR("maps.mmapgen", "{} Failed building regions!", tileString);
continue;
@@ -325,6 +514,114 @@ namespace MMAP
dmmerge = nullptr;
tiles = nullptr;
// Road-aware mmaps: pre-pass that promotes a polygon's area to
// NAV_AREA_ROAD when its centroid falls in an MCNK flagged as road
// by the extractor (parallel .road file consumed by TerrainBuilder).
//
// The promotion happens BEFORE the flag-computation loop below, so
// road polygons get NAV_ROAD in `flags[i]` via the standard formula
// (1 << (NAV_AREA_MAX_VALUE - NAV_AREA_ROAD) == 0x10). Non-road
// polygons are untouched and retain NAV_AREA_GROUND / *_STEEP /
// *_WATER / *_MAGMA_SLIME exactly as before.
// Override candidates for this tile from the operator-curated
// road_points (see RoadOverrides.h). Computed once outside the
// poly loop because all polys in the tile share the same bbox.
// Done outside the `hasRoadMask` branch so override tagging
// works even on tiles where the texture classifier produced an
// empty road mask (the entire point of overrides).
std::vector<MMAP::RoadOverridePoint> tile_overrides;
{
float const tileMinX = bmin[0];
float const tileMinZ = bmin[2];
float const tileMaxX = bmin[0] + (bmax[0] - bmin[0]);
float const tileMaxZ = bmin[2] + (bmax[2] - bmin[2]);
tile_overrides = MMAP::RoadOverrides::Instance()
.PointsOverlappingTile(mapID, tileMinX, tileMinZ,
tileMaxX, tileMaxZ);
}
if (meshData.hasRoadMask || !tile_overrides.empty())
{
// Texture-derived ADT road mask present but policy says ignore it
// (see g_mmapGenTuning.textureRoads comment in MMapDefines.h) —
// flag once per tile for the one-line-per-run summary rather than
// spamming per-poly below.
if (meshData.hasRoadMask && !g_mmapGenTuning.textureRoads)
g_mmapGenTuning.textureRoadsIgnoredSeen.store(true, std::memory_order_relaxed);
int const nvp = iv.polyMesh->nvp;
float const cs = config.cs;
// World-space origin of this tile (matches TerrainBuilder's
// (tileX - 32) * GRID_SIZE convention via bmin[0]/bmin[2]).
float const tileMinX = bmin[0];
float const tileMinZ = bmin[2];
for (int i = 0; i < iv.polyMesh->npolys; ++i)
{
uint8 area = iv.polyMesh->areas[i] & NAV_AREA_ALL_MASK;
// Only promote GROUND/GROUND_STEEP polys — water/lava don't
// become roads.
if (area != NAV_AREA_GROUND && area != NAV_AREA_GROUND_STEEP)
continue;
// Polygon centroid in tile-local coords (then world coords).
unsigned short const* poly = &iv.polyMesh->polys[i * 2 * nvp];
int sx = 0, sz = 0, n = 0;
for (int j = 0; j < nvp; ++j)
{
if (poly[j] == RC_MESH_NULL_IDX) break;
unsigned short const* v = &iv.polyMesh->verts[poly[j] * 3];
sx += v[0];
sz += v[2];
++n;
}
if (n == 0) continue;
float worldX = tileMinX + (static_cast<float>(sx) / n) * cs;
float worldZ = tileMinZ + (static_cast<float>(sz) / n) * cs;
// Texture-classifier road mask (per-MCNK 16x16 grid).
// Texture detector tags stone-textured mountains as roads —
// curated handcrafted_road/RoadOverrides are the road
// sources; audit 2026-07-03. Ignored unless --textureRoads
// opts back into the (mistagging) legacy behavior.
if (g_mmapGenTuning.textureRoads && meshData.hasRoadMask)
{
static constexpr float kChunkSize = GRID_SIZE / 16.0f;
int mcnkCol = static_cast<int>((worldX - tileMinX) / kChunkSize);
int mcnkRow = static_cast<int>((worldZ - tileMinZ) / kChunkSize);
if (mcnkRow < 0) mcnkRow = 0;
if (mcnkRow > 15) mcnkRow = 15;
if (mcnkCol < 0) mcnkCol = 0;
if (mcnkCol > 15) mcnkCol = 15;
std::size_t maskIdx = static_cast<std::size_t>(mcnkRow * 16 + mcnkCol);
if (meshData.roadMask[maskIdx] != 0)
{
iv.polyMesh->areas[i] = NAV_AREA_ROAD;
continue;
}
}
// Operator overrides — exact world-space distance check.
// Polys whose centroid is within ANY override's radius
// get tagged. Continues looping over polys (don't break
// out of the for(i) loop because other polys may match
// other override points).
for (auto const& ov : tile_overrides)
{
const float dx = worldX - ov.x;
// The Y axis in TC is the Z axis in Detour internal
// coords — bmin/bmax are in Detour layout (XZY).
// Override's `y` is TC world-Y == Detour Z.
const float dz = worldZ - ov.y;
if (dx*dx + dz*dz <= ov.radius * ov.radius)
{
iv.polyMesh->areas[i] = NAV_AREA_ROAD;
break;
}
}
}
}
// set polygons as walkable
// TODO: special flags for DYNAMIC polygons, ie surfaces that can be turned on and off
for (int i = 0; i < iv.polyMesh->npolys; ++i)
@@ -338,6 +635,242 @@ namespace MMAP
}
}
// Post-build island pruning: flood-fill from the largest connected
// component and mark isolated tiny islands (< 5 polys) as empty so
// bots never land on unreachable navmesh fragments. These arise from
// the minRegionArea=rcSqr(12) reduction: rooftops, awning ledges,
// and small geometry artifacts survive area filtering but produce
// disconnected poly groups that Detour can findNearestPoly onto
// but can't route out of.
{
int const npolys = iv.polyMesh->npolys;
int const nvp = iv.polyMesh->nvp;
if (npolys > 0)
{
// Build adjacency from shared edges (polys sharing 2 verts).
std::vector<std::vector<int>> adj(npolys);
for (int i = 0; i < npolys; ++i)
{
for (int j = 0; j < nvp; ++j)
{
unsigned short nei = iv.polyMesh->polys[i * 2 * nvp + nvp + j];
if (nei == RC_MESH_NULL_IDX) continue;
int neiIdx = static_cast<int>(nei);
if (neiIdx >= 0 && neiIdx < npolys)
adj[i].push_back(neiIdx);
}
}
// Flood-fill connected components.
std::vector<int> comp_id(npolys, -1);
std::vector<int> comp_sizes;
int num_comps = 0;
for (int i = 0; i < npolys; ++i)
{
if (comp_id[i] >= 0) continue;
if (iv.polyMesh->areas[i] == 0) continue;
int cid = num_comps++;
int sz = 0;
std::queue<int> q;
q.push(i);
comp_id[i] = cid;
while (!q.empty())
{
int cur = q.front(); q.pop();
++sz;
for (int nb : adj[cur])
{
if (comp_id[nb] < 0 && iv.polyMesh->areas[nb] != 0)
{
comp_id[nb] = cid;
q.push(nb);
}
}
}
comp_sizes.push_back(sz);
}
// Find the largest component.
int largest_id = -1;
int largest_sz = 0;
for (int c = 0; c < num_comps; ++c)
{
if (comp_sizes[c] > largest_sz)
{
largest_sz = comp_sizes[c];
largest_id = c;
}
}
// Per-poly centroid in Recast space (same space as the navmesh
// verts and off-mesh connection endpoints). Recast axes:
// x/z = horizontal plane, y = up.
std::vector<float> cx(npolys, 0.f), cy(npolys, 0.f), cz(npolys, 0.f);
{
float const* bmin = iv.polyMesh->bmin;
float const cs = iv.polyMesh->cs, chh = iv.polyMesh->ch;
for (int i = 0; i < npolys; ++i)
{
unsigned short const* p = &iv.polyMesh->polys[i * 2 * nvp];
int n = 0;
for (int j = 0; j < nvp; ++j)
{
if (p[j] == RC_MESH_NULL_IDX) break;
unsigned short const* v = &iv.polyMesh->verts[p[j] * 3];
cx[i] += bmin[0] + v[0] * cs;
cy[i] += bmin[1] + v[1] * chh;
cz[i] += bmin[2] + v[2] * cs;
++n;
}
if (n) { cx[i] /= n; cy[i] /= n; cz[i] /= n; }
}
}
// Bridge-or-prune each non-largest component:
// * If a substantial component sits a SHORT, ~LEVEL gap from
// the main mesh, emit a bidirectional off-mesh connection
// instead of pruning it. Fixes piers/docks, detached
// platforms, and narrow water/gangplank gaps the navmesh
// can't auto-link (a horizontal gap that walkableClimb,
// which only bridges vertical steps, never closes). The
// near-level gate (small vertical delta) is the safety
// valve: rooftops/awnings/cliff ledges — which make up most
// isolated fragments — have a LARGE vertical delta and are
// therefore never bridged (so bots don't "jump" onto roofs).
// * Otherwise, prune tiny unreachable fragments (< 10 polys)
// as before so bots never findNearestPoly onto a dead-end.
// 30y horizontal reach: tree-canopy / overhang holes (Teldrassil,
// forested zones) leave isolated near-level navmesh fragments
// ~25-30y from the main mesh where the walkable ground is real
// but the gen raycast was occluded. 20y missed them (verified:
// a Teldrassil fragment at (9919,777) sits ~27y from reachable
// mesh, unreachable from every direction → bot Uraimus trapped).
// The ≤3y vertical gate still blocks rooftops/cliffs, so a 30y
// NEAR-LEVEL gap is almost always genuinely walkable ground.
constexpr float kBridgeMaxHoriz = 30.0f; // yards
constexpr float kBridgeMaxHorizSq = kBridgeMaxHoriz * kBridgeMaxHoriz;
constexpr float kBridgeMaxVert = 3.0f; // near-level only
constexpr int kMinBridgeComp = 4; // skip noise slivers
// Each off-mesh connection costs 2 verts + 1 poly in the tile
// data. Detour stores vertex indices as uint16, so the total
// (base verts + cons*2) must stay < 0xffff or dtCreateNavMeshData
// fails and the tile is dropped. WMO-dense expansion tiles
// (Outland/Shadowlands) have many isolated fragments; left
// unbounded the bridges overflowed the budget and silently
// killed ~250 tiles per such map. Cap per-tile bridge count and
// stop before the vertex budget; the dtCreateNavMeshData retry
// below is the final safety net.
constexpr int kMaxBridgesPerTile = 48;
constexpr int kBridgeSkipPolys = 2000; // also bounds the O(n^2) search
int pruned = 0, bridged = 0;
int const baseCons = static_cast<int>(meshData.offMeshConnections.size() / 6);
if (largest_id >= 0 && npolys <= kBridgeSkipPolys)
{
// Nearest main-mesh poly per non-largest component
// (min horizontal gap subject to the near-level gate).
std::vector<float> bestSq(num_comps, std::numeric_limits<float>::max());
std::vector<int> bestIso(num_comps, -1), bestMain(num_comps, -1);
for (int i = 0; i < npolys; ++i)
{
int const c = comp_id[i];
if (c < 0 || c == largest_id) continue;
if (comp_sizes[c] < kMinBridgeComp) continue;
for (int m = 0; m < npolys; ++m)
{
if (comp_id[m] != largest_id) continue;
// Relaxed centroid vertical gate for SELECTION only —
// the strict per-vertex ≤3y check happens in the
// refine pass below. Using kBridgeMaxVert here would
// skip a valid near-level main poly whose CENTROID Y
// differs by >3y (large/sloped poly) even though its
// nearest edge vertex is level with the fragment.
if (std::fabs(cy[i] - cy[m]) > 8.0f) continue;
float const dx = cx[i] - cx[m], dz = cz[i] - cz[m];
float const d = dx * dx + dz * dz;
if (d < bestSq[c]) { bestSq[c] = d; bestIso[c] = i; bestMain[c] = m; }
}
}
float const* bmin = iv.polyMesh->bmin;
float const csz = iv.polyMesh->cs, chh = iv.polyMesh->ch;
for (int c = 0; c < num_comps; ++c)
{
if (c == largest_id) continue;
bool bridged_this = false;
if (bestIso[c] >= 0)
{
// Refine the gap to the true EDGE distance: centroid-
// to-centroid OVERESTIMATES for large polys (a real 27y
// edge gap reads as ~37y between centroids), which wrongly
// rejected genuine near-level holes — e.g. the Teldrassil
// canopy hole that traps every Night Elf bot. Walk the
// nearest near-level VERTEX pair between the two polys; use
// it for BOTH the threshold test and the off-mesh endpoints
// (anchored on the actual walkable edges, nudged ~1.5y inward
// so Detour's findNearestPoly resolves each end to its poly).
float ea[3] = {0,0,0}, eb[3] = {0,0,0};
float bestv = std::numeric_limits<float>::max();
unsigned short const* pa = &iv.polyMesh->polys[bestIso[c] * 2 * nvp];
unsigned short const* pb = &iv.polyMesh->polys[bestMain[c] * 2 * nvp];
for (int ja = 0; ja < nvp && pa[ja] != RC_MESH_NULL_IDX; ++ja)
{
unsigned short const* va = &iv.polyMesh->verts[pa[ja] * 3];
float const vax = bmin[0] + va[0]*csz, vay = bmin[1] + va[1]*chh, vaz = bmin[2] + va[2]*csz;
for (int jb = 0; jb < nvp && pb[jb] != RC_MESH_NULL_IDX; ++jb)
{
unsigned short const* vb = &iv.polyMesh->verts[pb[jb] * 3];
float const vbx = bmin[0] + vb[0]*csz, vby = bmin[1] + vb[1]*chh, vbz = bmin[2] + vb[2]*csz;
if (std::fabs(vay - vby) > kBridgeMaxVert) continue;
float const dx = vax - vbx, dz = vaz - vbz, d = dx*dx + dz*dz;
if (d < bestv) { bestv = d; ea[0]=vax;ea[1]=vay;ea[2]=vaz; eb[0]=vbx;eb[1]=vby;eb[2]=vbz; }
}
}
bool const budget_ok =
bridged < kMaxBridgesPerTile &&
(iv.polyMesh->nverts + (baseCons + bridged + 1) * 2) < 0xff00;
if (budget_ok && bestv <= kBridgeMaxHorizSq)
{
// Nudge each endpoint ~1.5y toward its poly centroid.
auto nudge = [](float* e, float gx, float gy, float gz) {
float const dx = gx - e[0], dy = gy - e[1], dz = gz - e[2];
float const len = std::sqrt(dx*dx + dy*dy + dz*dz);
if (len > 0.01f) { float const t = (len < 1.5f ? len : 1.5f) / len;
e[0] += dx*t; e[1] += dy*t; e[2] += dz*t; }
};
nudge(ea, cx[bestIso[c]], cy[bestIso[c]], cz[bestIso[c]]);
nudge(eb, cx[bestMain[c]], cy[bestMain[c]], cz[bestMain[c]]);
meshData.offMeshConnections.push_back(ea[0]);
meshData.offMeshConnections.push_back(ea[1]);
meshData.offMeshConnections.push_back(ea[2]);
meshData.offMeshConnections.push_back(eb[0]);
meshData.offMeshConnections.push_back(eb[1]);
meshData.offMeshConnections.push_back(eb[2]);
meshData.offMeshConnectionRads.push_back(2.0f);
meshData.offMeshConnectionDirs.push_back(1); // bidirectional
meshData.offMeshConnectionsAreas.push_back(NAV_AREA_GROUND);
meshData.offMeshConnectionsFlags.push_back(NAV_GROUND);
++bridged;
bridged_this = true;
}
}
if (!bridged_this && comp_sizes[c] < 10)
{
for (int i = 0; i < npolys; ++i)
if (comp_id[i] == c)
{
iv.polyMesh->areas[i] = 0;
iv.polyMesh->flags[i] = 0;
++pruned;
}
}
// else: large + unbridgeable component — leave intact.
}
}
if (pruned > 0 || bridged > 0)
{
TC_LOG_DEBUG("maps.mmapgen", "{} Island pass: bridged {}, pruned {} ({} components, largest={})",
tileString, bridged, pruned, num_comps, largest_sz);
}
}
}
// setup mesh parameters
dtNavMeshCreateParams params = {};
params.verts = iv.polyMesh->verts;
@@ -433,6 +966,26 @@ namespace MMAP
TC_LOG_DEBUG("maps.mmapgen", "{} Building navmesh tile...", tileString);
if (!dtCreateNavMeshData(&params, &navData, &tileResult.size))
{
// SAFETY NET: the auto-bridge off-mesh connections can push a dense
// tile past Detour's per-tile budget, failing creation. Never drop
// the tile over a best-effort bridge — retry without off-mesh
// connections so navmesh coverage is preserved exactly as before
// the bridge feature (worst case: this one tile has no bridges).
if (params.offMeshConCount > 0)
{
params.offMeshConVerts = nullptr;
params.offMeshConRad = nullptr;
params.offMeshConDir = nullptr;
params.offMeshConAreas = nullptr;
params.offMeshConFlags = nullptr;
params.offMeshConCount = 0;
if (dtCreateNavMeshData(&params, &navData, &tileResult.size))
{
TC_LOG_DEBUG("maps.mmapgen", "{} Built without auto-bridges (off-mesh budget overflow).", tileString);
tileResult.data.reset(navData);
return tileResult;
}
}
TC_LOG_ERROR("maps.mmapgen", "{} Failed building navmesh tile!", tileString);
return tileResult;
}
@@ -522,8 +1075,17 @@ namespace MMAP
rcVcopy(config.bmax, bmax);
config.maxVertsPerPoly = DT_VERTS_PER_POLYGON;
config.cs = tileConfig.BASE_UNIT_DIM;
config.ch = tileConfig.BASE_UNIT_DIM;
// cs/ch coupled to BASE_UNIT_DIM by default. --cellSize sets an explicit
// value; --fineCells halves it (4x voxel density) for the resolution probe.
{
float cs = tileConfig.BASE_UNIT_DIM;
if (g_mmapGenTuning.cellSize > 0.f)
cs = g_mmapGenTuning.cellSize;
else if (g_mmapGenTuning.fineCells)
cs *= 0.5f;
config.cs = cs;
config.ch = cs;
}
// Keeping these 2 slope angles the same reduces a lot the number of polys.
// 55 should be the minimum, maybe 70 is ok (keep in mind blink uses mmaps), 85 is too much for players
config.walkableSlopeAngle = m_maxWalkableAngle.value_or(55.0f);
@@ -533,15 +1095,73 @@ namespace MMAP
config.borderSize = config.walkableRadius + 3;
config.maxEdgeLen = tileConfig.VERTEX_PER_TILE + 1; // anything bigger than tileSize
config.walkableHeight = m_bigBaseUnit ? 3 : 6;
// a value >= 3|6 allows npcs to walk over some fences
// a value >= 4|8 allows npcs to walk over all fences
config.walkableClimb = m_bigBaseUnit ? 3 : 6;
config.minRegionArea = rcSqr(60);
config.mergeRegionArea = rcSqr(50);
// Walkable climb — vertical step a navmesh agent can ascend in
// one voxel column. Recast.h: "value >= 4|8 allows npcs to walk
// over all fences". Bumped 2026-05-21 from 6 → 10 (1.6y → 2.67y)
// because spiral-stair WMOs (Aldrassil) have ramp-entry step
// rises ~2y that the 1.6y climb couldn't bridge — ground polys
// never linked to the first ramp poly, so even with the right
// partition method the navmesh was a disconnected graph.
// Trade-off: bots may climb low fences/walls (≤2.67y) they
// previously couldn't. This is a known acceptable behavior in
// most Blizzard content where short walls are intentional
// hop-overs (1-yard walls in BG bases, garden edges, etc).
config.walkableClimb = m_bigBaseUnit ? 5 : 10;
// Region-area thresholds — tuned 2026-05-21 after the Aldrassil
// navmesh investigation (see WMO_COLLIDE_HIT_FIX.md).
//
// Previous values rcSqr(60)=3600 vx² / rcSqr(50)=2500 vx² are 50×
// larger than the upstream Recast demo defaults (rcSqr(8)=64).
// At cs=0.266 yards, 3600 vx² ≈ 256 yards² — anything smaller got
// discarded as "noise". That filtered out:
// * Aldrassil's top floor (Tenaron Stormgrip's room, ~36 yards²)
// * Every elevated single-room poly in towers and dungeons
// * Most small ledges and platforms
// The discarded regions appeared in the pmesh as singleton 1-poly
// regions disconnected from the surrounding navmesh, so Detour
// could find them via findNearestPoly but couldn't path TO them
// (no graph edges into the region).
//
// Lowered to rcSqr(12)² = 144 / rcSqr(20)² = 400 — matches the
// RecastDemo "indoor" sample profile while staying conservative
// vs. the 64/400 demo defaults. Trade-off: marginally noisier
// navmesh on rooftops / awnings / small unwalkable platforms,
// but those filter out via the higher-level walkability gate
// anyway. The 30× reduction in minRegionArea unlocks every
// small-room interior navmesh that was previously trimmed.
config.minRegionArea = rcSqr(12);
config.mergeRegionArea = rcSqr(20);
config.maxSimplificationError = 1.8f; // eliminates most jagged edges (tiny polygons)
config.detailSampleDist = config.cs * 16;
config.detailSampleMaxError = config.ch * 1;
// --------------------------------------------------------------------
// CLI sweep overrides (g_mmapGenTuning). Applied AFTER the baseline
// literals but BEFORE the per-map switch(mapID) below, so intentional
// map-specific special cases (map 48 ch*2, map 562 radius=0, etc.) still
// win over a global sweep flag. Sentinels (<0 / false) leave the default.
// Values are raw voxel counts / area-in-vx² (e.g. --minRegionArea 144).
// --------------------------------------------------------------------
if (g_mmapGenTuning.minRegionArea >= 0)
config.minRegionArea = g_mmapGenTuning.minRegionArea;
if (g_mmapGenTuning.mergeRegionArea >= 0)
config.mergeRegionArea = g_mmapGenTuning.mergeRegionArea; // inert under Layers
if (g_mmapGenTuning.maxSimplificationError >= 0.f)
config.maxSimplificationError = g_mmapGenTuning.maxSimplificationError;
if (g_mmapGenTuning.maxEdgeLen >= 0)
config.maxEdgeLen = g_mmapGenTuning.maxEdgeLen;
if (g_mmapGenTuning.walkableClimb >= 0)
config.walkableClimb = g_mmapGenTuning.walkableClimb;
if (g_mmapGenTuning.walkableRadius >= 0)
{
config.walkableRadius = g_mmapGenTuning.walkableRadius;
config.borderSize = config.walkableRadius + 3; // borderSize tracks radius
}
if (g_mmapGenTuning.detailSampleDist >= 0.f)
config.detailSampleDist = g_mmapGenTuning.detailSampleDist;
if (g_mmapGenTuning.detailSampleMaxError >= 0.f)
config.detailSampleMaxError = g_mmapGenTuning.detailSampleMaxError;
switch (mapID)
{
// Blade's Edge Arena
+87 -2
View File
@@ -20,6 +20,8 @@
#include "Define.h"
#include <DetourNavMesh.h>
#include <atomic>
#include <unordered_set>
inline uint32 constexpr MMAP_MAGIC = 0x4d4d4150; // 'MMAP'
inline uint32 constexpr MMAP_VERSION = 16;
@@ -62,8 +64,9 @@ enum NavArea
NAV_AREA_GROUND_STEEP = 10,
NAV_AREA_WATER = 9,
NAV_AREA_MAGMA_SLIME = 8, // don't need to differentiate between them
NAV_AREA_ROAD = 7, // road-aware-mmaps: tagged by mmaps_generator when the underlying MCNK is dominantly a road texture; cheaper for Detour's setAreaCost biasing pathfinding toward roads. Value chosen so the existing (NAV_AREA_MAX_VALUE - area) bit formula yields an unused bit (0x10) without disturbing the other flag bits.
NAV_AREA_MAX_VALUE = NAV_AREA_GROUND,
NAV_AREA_MIN_VALUE = NAV_AREA_MAGMA_SLIME,
NAV_AREA_MIN_VALUE = NAV_AREA_ROAD,
NAV_AREA_ALL_MASK = 0x3F // max allowed value
};
@@ -73,7 +76,8 @@ enum NavTerrainFlag : uint16
NAV_GROUND = 1 << (NAV_AREA_MAX_VALUE - NAV_AREA_GROUND),
NAV_GROUND_STEEP = 1 << (NAV_AREA_MAX_VALUE - NAV_AREA_GROUND_STEEP),
NAV_WATER = 1 << (NAV_AREA_MAX_VALUE - NAV_AREA_WATER),
NAV_MAGMA_SLIME = 1 << (NAV_AREA_MAX_VALUE - NAV_AREA_MAGMA_SLIME)
NAV_MAGMA_SLIME = 1 << (NAV_AREA_MAX_VALUE - NAV_AREA_MAGMA_SLIME),
NAV_ROAD = 1 << (NAV_AREA_MAX_VALUE - NAV_AREA_ROAD)
};
enum OffMeshConnectionFlag : uint8
@@ -94,4 +98,85 @@ struct OffMeshData
NavTerrainFlag Flags;
};
// ---------------------------------------------------------------------------
// Generator tuning overrides — set ONCE from the mmaps_generator CLI before any
// tile is built (single-threaded arg-parse phase), then read by TileBuilder on
// every tile. Defined in TileBuilder.cpp. A sentinel (<0 for numeric fields)
// means "keep the built-in TileBuilder default", so behaviour is byte-identical
// to before unless a flag is explicitly passed. This lets the map-1 navmesh
// optimization sweep vary the region-partition method and the highest-leverage
// rcConfig values WITHOUT recompiling per variant.
//
// The three partition methods are the canonical Recast region builders:
// Watershed rcBuildDistanceField + rcBuildRegions — smoothest open terrain,
// can island multi-floor WMOs.
// Monotone rcBuildRegionsMonotone — no holes, long thin polys.
// Layers rcBuildLayerRegions — current default; best for
// multi-floor WMO/cave linkage.
enum class MmapPartitionMethod : int
{
Watershed = 0,
Monotone = 1,
Layers = 2,
// Auto: choose the method PER SUBTILE from the compact-heightfield's
// vertical-layering fraction (cells with >=2 walkable spans). Open/flat
// tiles -> Watershed (smoothest regions); multi-floor WMO/cave tiles ->
// Layers (linked floors); mixed -> Monotone (no holes). Prototype merge.
Auto = 3
};
struct MmapGenTuning
{
MmapPartitionMethod partition = MmapPartitionMethod::Layers; // current fork default
int minRegionArea = -1; // <0 => keep rcSqr(12)
int mergeRegionArea = -1; // <0 => keep rcSqr(20); inert under Layers
float maxSimplificationError = -1.f; // <0 => keep 1.8
int maxEdgeLen = -1; // <0 => keep VERTEX_PER_TILE+1
int walkableClimb = -1; // <0 => keep (bigBaseUnit?5:10)
int walkableRadius = -1; // <0 => keep (bigBaseUnit?1:2)
float cellSize = -1.f; // <0 => keep BASE_UNIT_DIM (cs == ch)
float detailSampleDist = -1.f; // <0 => keep cs*16
float detailSampleMaxError = -1.f; // <0 => keep ch*1
bool fineCells = false; // true => halve cs/ch (4x voxels) — resolution probe
// Instance-map partition policy (2026-07-01). Instanced dungeon/raid maps
// default to Monotone: the Layers default islands winding WMO mine tunnels
// into disconnected navmesh regions (Deadmines foundry — root-caused +
// validated live). Monotone never produces holes so the tunnels mesh, and
// it does NOT regress multi-floor linkage (Aldrassil ground<->Tenaron
// verified identical). currentMapIsInstance is set per-map by the generator
// (MapBuilder::buildMap, which has sMapStore) before its tiles are built.
// partitionExplicit is set when --partition is passed on the CLI, so an
// explicit operator choice always overrides the instance default.
bool partitionExplicit = false; // true => --partition given; respect it as-is
// Map IDs whose InstanceType is dungeon/raid — filled ONCE by the generator
// (MapBuilder::buildMaps, which has sMapStore) before any tile is queued, so
// the concurrent tile workers only ever read it. buildMoveMapTile consults it
// to switch such maps from Layers to Monotone.
std::unordered_set<uint32> instanceMaps;
// Handcrafted-only road tagging (audit 2026-07-03). The texture-based road
// auto-detector (per-MCNK ADT roadMask + WMO-sidecar solidTriRoadFlags,
// both populated by TerrainBuilder) tags stone-textured mountains as roads:
// it is a bare substring match against the texture filename with no slope
// gate, and the vegetation gate meant to guard it is inert in production.
// Curated sources — the handcrafted_road runtime overlay and the
// RoadOverrides CSV baked in via TileBuilder — are therefore the ONLY road
// sources by default. textureRoads is OFF unless the operator passes
// --textureRoads on the mmaps_generator CLI (set once in PathGenerator.cpp
// before any tile is queued, same as partitionExplicit above); TileBuilder
// gates its two texture-consumption sites on this flag, opt-in for
// experiments only.
bool textureRoads = false;
// Set (relaxed, best-effort) by TileBuilder worker threads when texture-
// derived road input was present on a tile but ignored because
// textureRoads is off. Read once at the end of the generator run
// (PathGenerator.cpp main()) to print a single summary line instead of
// spamming per-tile.
std::atomic<bool> textureRoadsIgnoredSeen{false};
};
// Definition lives in TileBuilder.cpp (generator-only TU). Unreferenced in the
// worldserver link, so the bare extern there costs nothing.
extern MmapGenTuning g_mmapGenTuning;
#endif // MMapDefines_h__
@@ -23,6 +23,7 @@
#include "MapUtils.h"
#include "Memory.h"
#include <algorithm>
#include <mutex>
namespace MMAP
{
@@ -43,6 +44,22 @@ namespace MMAP
// dummy struct to hold map's mmap data
struct MMapData
{
// Per-map mutex. Held by `MMapManager::loadMap` for the entire
// duration of `loadMapData` → `meshData.try_emplace` →
// `navMesh.addTile`. Without this, concurrent loadMap calls
// for the same mapId (e.g. multiple instance Maps of one
// dungeon being updated by different MapUpdater worker
// threads, sharing the same `MMapMapData` because most maps
// route through `GetInstanceIdForMeshLookup() == 0`) race on
// `meshData.try_emplace` AND on `dtNavMesh::addTile`'s tile
// list mutation. The race manifests as a 60s+ hang in
// `connectExtLinks::findConnectingPolys` walking a corrupted
// link list (cause of the FreezeDetector abort).
// Granularity is per-mapId: different maps don't contend, and
// same-map loads serialize — which is correct since they were
// never supposed to interleave inside dtNavMesh.
std::mutex loadLock;
MeshDataMap meshData;
// we have to use single dtNavMeshQuery for every instance, since those are not thread safe
@@ -205,6 +222,21 @@ namespace MMAP
LoadResult MMapManager::loadMap(std::string_view basePath, uint32 mapId, uint32 instanceId, int32 x, int32 y)
{
// Serialize per-mapId. `loadMapData` mutates `meshData` and
// `addTile` below mutates `navMesh` — both are non-thread-safe
// and two map worker threads loading tiles for the same mapId
// (different instance copies of one dungeon) hit the same
// `MMapMapData` instance for shared-mesh maps. Without this
// lock, concurrent `addTile` corrupts the dtNavMesh link list,
// and the next `connectExtLinks` walk hangs for 60+ seconds
// (FreezeDetector abort observed 2026-05-15).
// loadedMMaps itself is populated once at startup via
// InitializeThreadUnsafe so the outer lookup is read-only here.
MMapData* mmap = Trinity::Containers::MapGetValuePtr(loadedMMaps, mapId);
if (!mmap)
return LoadResult::FileNotFound;
std::lock_guard<std::mutex> loadGuard(mmap->loadLock);
// make sure the mmap is loaded and ready to load tiles
switch (LoadResult mapResult = loadMapData(basePath, mapId, instanceId))
{
@@ -215,8 +247,10 @@ namespace MMAP
return mapResult;
}
// get this mmap data
MMapData* mmap = Trinity::Containers::MapGetValuePtr(loadedMMaps, mapId);
// get this mmap data (re-fetch under lock — mmap pointer was
// resolved before the lock, so the MMapMapData inside may have
// been populated by another thread that won the race for first
// entry. We re-call GetMeshData / find under the lock.)
MMapMapData& meshData = mmap->GetMeshData(mapId, instanceId).first->second;
// check if we already have this tile loaded
@@ -304,6 +338,14 @@ namespace MMAP
bool MMapManager::loadMapInstance(std::string_view basePath, uint32 meshMapId, uint32 instanceMapId, uint32 instanceId)
{
// Per-mapId lock — protects navMeshQueries.try_emplace + meshData
// lookup against concurrent loadMap / unloadMap from other Map
// worker threads on the same mapId. See loadMap's comment.
MMapData* mmap = Trinity::Containers::MapGetValuePtr(loadedMMaps, meshMapId);
if (!mmap)
return false;
std::lock_guard<std::mutex> loadGuardMutex(mmap->loadLock);
switch (loadMapData(basePath, meshMapId, instanceId))
{
case LoadResult::Success:
@@ -313,7 +355,6 @@ namespace MMAP
return false;
}
MMapData* mmap = Trinity::Containers::MapGetValuePtr(loadedMMaps, meshMapId);
auto [queryItr, inserted] = mmap->navMeshQueries.try_emplace({ instanceMapId, instanceId });
if (!inserted)
return true;
@@ -324,7 +365,13 @@ namespace MMAP
});
// allocate mesh query
if (dtStatusFailed(queryItr->second.init(&mmap->GetMeshData(meshMapId, instanceId).first->second.navMesh, 1024)))
// A* node pool raised 1024 -> 8192 (owner's call) to recover budget-wedged
// objectives (docs/MMAP_SWEEP_FINDINGS.md: ~41% of wedges, WEDGE 6587->3902
// on map 1). NOTE: at fleet scale this adds per-hard-path A* cost in
// Map::Update on an already-high tick (~524ms @ 869 bots, snapshot-build
// bound); watch for movement rubber-banding. The real headroom is in the
// 245ms snapshot build, not this pool.
if (dtStatusFailed(queryItr->second.init(&mmap->GetMeshData(meshMapId, instanceId).first->second.navMesh, 8192)))
{
TC_LOG_ERROR("maps", "MMAP:GetNavMeshQuery: Failed to initialize dtNavMeshQuery for mapId {:04} instanceId {}", instanceMapId, instanceId);
return false;
@@ -335,6 +382,120 @@ namespace MMAP
return true;
}
namespace
{
struct TileLinkCorruption
{
int polyIndex; // poly whose chain is broken, or -1 for the free-link list
unsigned int badValue; // the out-of-range link index that was found
void const* fieldAddress; // address of the corrupt firstLink/next field
};
// Walks every poly link chain and the free-link list of a tile,
// verifying each link index is either DT_NULL_LINK or within
// [0, maxLinkCount), with a chain-length cap as a cycle guard.
// Returns false and fills `out` on the first violation.
//
// Why this exists (2026-06-12, worldserver.exe.335304.dmp): a single
// 4 KB page of a LIVE tile's poly array (map 1931, tile [25,07]) was
// found replaced with foreign data — decompressed BC1 texture pixels,
// every dword 0xFFxxxxxx — while the surrounding pages were intact.
// No code in worldserver produces texture pixels, the pattern existed
// exactly once in the whole address space, and all navmesh mutation
// paths are serialized by MMapData::loadLock (verified in the dump:
// 1 of 95 threads in mmap code). The corruption came from OUTSIDE the
// process: lost/garbled pagefile writes under commit exhaustion
// (System log: Ntfs event 50 "delayed write failed", Ntfs 140, and
// Resource-Exhaustion-Detector 2004 naming worldserver) or bad RAM.
// dtNavMesh::unconnectLinks then dereferenced a pixel value as a link
// index and died with an unattributable wild AV. Validating here
// converts that into an immediate, fully-attributed fatal report at
// the first point the corrupt chain would be walked. It never fires
// on healthy memory and costs no more than the unconnectLinks walk
// that removeTile performs anyway.
bool ValidateTileLinkIntegrity(dtMeshTile const* tile, TileLinkCorruption& out)
{
if (!tile || !tile->header || !tile->links || !tile->polys)
return true; // empty slot — nothing to validate
unsigned int const maxLinks = static_cast<unsigned int>(std::max(tile->header->maxLinkCount, 0));
auto chainValid = [&](unsigned int first, int polyIndex, void const* firstAddr)
{
unsigned int j = first;
void const* addr = firstAddr;
unsigned int steps = 0;
while (j != DT_NULL_LINK)
{
if (j >= maxLinks || steps++ > maxLinks) // out-of-range index, or cycle
{
out = { polyIndex, j, addr };
return false;
}
addr = &tile->links[j].next;
j = tile->links[j].next;
}
return true;
};
for (int i = 0; i < tile->header->polyCount; ++i)
if (!chainValid(tile->polys[i].firstLink, i, &tile->polys[i].firstLink))
return false;
return chainValid(tile->linksFreeList, -1, &tile->linksFreeList);
}
// Validates the exact tile set dtNavMesh::removeTile will mutate:
// the removed tile itself, the 8 surrounding grid cells and any
// other layers in the same column (matches removeTile's
// getNeighbourTilesAt(side 0..7) + getTilesAt walk). Aborts with a
// precise diagnostic instead of letting unconnectLinks dereference
// a corrupt link index.
void ValidateRemovalNeighborhood(dtNavMesh const& navMesh, dtTileRef tileRef, uint32 mapId, uint32 instanceId)
{
dtMeshTile const* target = navMesh.getTileByRef(tileRef);
if (!target || !target->header)
return; // stale/invalid ref — removeTile will reject it and the existing error path handles it
auto validateOrAbort = [&](dtMeshTile const* tile)
{
TileLinkCorruption c;
if (ValidateTileLinkIntegrity(tile, c))
return;
TC_LOG_FATAL("maps", "MMAP: navmesh memory corruption detected on map {:04} instance {} while unloading tile [{:02},{:02}]: "
"tile [{:02},{:02}] {} has link index 0x{:08X} (valid: < {} or DT_NULL_LINK) at {}. "
"Foreign content in a live, lock-serialized navmesh tile indicates corruption from OUTSIDE the navmesh code "
"(bad RAM / lost pagefile writes — check System log for WHEA, Ntfs 50/140 and Resource-Exhaustion-Detector 2004 events). "
"Aborting before the corrupt link chain is dereferenced (ref: crash 2026-06-12, worldserver.exe.335304.dmp).",
mapId, instanceId, target->header->x, target->header->y,
tile->header->x, tile->header->y,
c.polyIndex >= 0 ? Trinity::StringFormat("poly {}", c.polyIndex) : "free-link list",
c.badValue, tile->header->maxLinkCount, c.fieldAddress);
ABORT_MSG("MMAP: navmesh tile link corruption (external memory corruption) on map %u tile [%d,%d] poly %d value 0x%08X",
mapId, tile->header->x, tile->header->y, c.polyIndex, c.badValue);
};
validateOrAbort(target);
static int const offsets[8][2] = { { -1, -1 }, { -1, 0 }, { -1, 1 }, { 0, -1 }, { 0, 1 }, { 1, -1 }, { 1, 0 }, { 1, 1 } };
dtMeshTile const* neis[32];
for (auto const& off : offsets)
{
int nneis = navMesh.getTilesAt(target->header->x + off[0], target->header->y + off[1], neis, 32);
for (int n = 0; n < nneis; ++n)
validateOrAbort(neis[n]);
}
// other layers in the same tile column (removeTile unconnects these too)
int nneis = navMesh.getTilesAt(target->header->x, target->header->y, neis, 32);
for (int n = 0; n < nneis; ++n)
if (neis[n] != target)
validateOrAbort(neis[n]);
}
}
void MMapManager::unloadMap(uint32 mapId, int32 x, int32 y)
{
// check if we have this map loaded
@@ -347,6 +508,11 @@ namespace MMAP
}
MMapData* mmap = itr->second.get();
// Serialize with loadMap on the same mapId — concurrent
// navMesh.removeTile during another thread's addTile would
// corrupt the tile/link list (same root cause as the load-load
// race fixed in loadMap above).
std::lock_guard<std::mutex> loadGuardMutex(mmap->loadLock);
uint32 packedGridPos = packTileID(x, y);
for (auto& [instanceId, meshData] : mmap->meshData)
{
@@ -355,6 +521,10 @@ namespace MMAP
if (!tileRef)
continue;
// fail fast (with attribution) on externally-corrupted tiles
// before removeTile walks their link chains
ValidateRemovalNeighborhood(meshData.navMesh, tileRef.mapped(), mapId, instanceId);
// unload, and mark as non loaded
if (dtStatusFailed(meshData.navMesh.removeTile(tileRef.mapped(), nullptr, nullptr)))
{
@@ -382,6 +552,9 @@ namespace MMAP
return;
}
// Serialize with loadMap / loadMapInstance on the same mapId.
std::lock_guard<std::mutex> loadGuardMutex(itr->second->loadLock);
if (!isRebuildingTilesEnabledOnMap(mapId))
{
if (MeshDataMap::node_type meshNode = itr->second->RemoveMeshData(mapId, 0))
@@ -390,6 +563,7 @@ namespace MMAP
{
uint32 x = (tileId >> 16);
uint32 y = (tileId & 0x0000FFFF);
ValidateRemovalNeighborhood(meshNode.mapped().navMesh, tileRef, mapId, 0);
if (dtStatusFailed(meshNode.mapped().navMesh.removeTile(tileRef, nullptr, nullptr)))
TC_LOG_ERROR("maps", "MMAP:unloadMap: Could not unload {:04}_{:02}_{:02}.mmtile from navmesh", mapId, x, y);
else
@@ -418,6 +592,9 @@ namespace MMAP
}
MMapData* mmap = itr->second.get();
// Serialize with loadMap / loadMapInstance / unloadMap on the
// same mapId.
std::lock_guard<std::mutex> loadGuardMutex(mmap->loadLock);
std::size_t erased = mmap->navMeshQueries.erase({ instanceMapId, instanceId });
if (!erased)
TC_LOG_DEBUG("maps", "MMAP:unloadMapInstance: Asked to unload not loaded dtNavMeshQuery mapId {:04} instanceId {}", instanceMapId, instanceId);
@@ -431,6 +608,7 @@ namespace MMAP
{
uint32 x = (tileId >> 16);
uint32 y = (tileId & 0x0000FFFF);
ValidateRemovalNeighborhood(meshNode.mapped().navMesh, tileRef, meshMapId, instanceId);
if (dtStatusFailed(meshNode.mapped().navMesh.removeTile(tileRef, nullptr, nullptr)))
TC_LOG_ERROR("maps", "MMAP:unloadMap: Could not unload {:04}_{:02}_{:02}.mmtile from navmesh", meshMapId, x, y);
else
+22
View File
@@ -0,0 +1,22 @@
# This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
#
# This file is free software; as a special exception the author gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# TrinityCore Optional Modules
# Always include Common module for shared infrastructure
add_subdirectory(Common)
# Test module to demonstrate shared API access
add_subdirectory(TestModule)
# Only include specific modules if they are enabled
if(BUILD_PLAYERBOT_V2)
add_subdirectory(PlayerbotV2)
endif(BUILD_PLAYERBOT_V2)
+41
View File
@@ -0,0 +1,41 @@
# Common Module - Shared Infrastructure for All TrinityCore Modules
#
# This module provides shared APIs and utilities that can be used by all
# other modules to ensure consistency and avoid code duplication.
add_library(modules-common STATIC)
# CollectAndAddSourceFiles automatically recurses into subdirectories
CollectAndAddSourceFiles(
modules-common
${CMAKE_CURRENT_SOURCE_DIR})
target_include_directories(modules-common
PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}
PRIVATE
${CMAKE_SOURCE_DIR}/src/server
${CMAKE_SOURCE_DIR}/src/server/shared
${CMAKE_SOURCE_DIR}/src/server/database
${CMAKE_SOURCE_DIR}/src/common
)
target_link_libraries(modules-common
PUBLIC
trinity-core-interface
PRIVATE
shared
common
)
set_target_properties(modules-common
PROPERTIES
FOLDER "src/modules"
)
# Install headers for other modules to use
install(
DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/
DESTINATION include/modules/Common
FILES_MATCHING PATTERN "*.h"
)
@@ -0,0 +1,294 @@
/*
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*/
#include "ModuleLogManager.h"
#include "Config.h"
#include "Log.h"
#include "StringFormat.h"
#include <mutex>
namespace Trinity
{
ModuleLogManager* ModuleLogManager::instance()
{
static ModuleLogManager instance;
return &instance;
}
bool ModuleLogManager::RegisterModule(std::string const& moduleName, uint8 defaultLevel, std::string const& logFileName)
{
printf("=== MODULE LOG DEBUG: RegisterModule() entered for '%s' ===\n", moduleName.c_str());
std::lock_guard<std::mutex> lock(_loggerMutex);
printf("=== MODULE LOG DEBUG: Got mutex lock ===\n");
if (_moduleLoggers.find(moduleName) != _moduleLoggers.end())
{
printf("=== MODULE LOG DEBUG: Module already registered ===\n");
TC_LOG_WARN("server.loading", "ModuleLogManager: Module '{}' already registered", moduleName);
return false;
}
printf("=== MODULE LOG DEBUG: Creating ModuleLogInfo ===\n");
auto info = std::make_unique<ModuleLogInfo>();
info->name = moduleName;
info->logLevel = defaultLevel;
info->logFileName = logFileName.empty() ? Trinity::StringFormat("{}.log", moduleName) : logFileName;
info->initialized = false;
printf("=== MODULE LOG DEBUG: ModuleLogInfo created, logFileName='%s' ===\n", info->logFileName.c_str());
// Generate standardized logger names
printf("=== MODULE LOG DEBUG: About to call GenerateLoggerNames ===\n");
auto names = GenerateLoggerNames(moduleName);
printf("=== MODULE LOG DEBUG: GenerateLoggerNames returned ===\n");
info->loggerName = names.first;
info->appenderName = names.second;
printf("=== MODULE LOG DEBUG: loggerName='%s', appenderName='%s' ===\n", info->loggerName.c_str(), info->appenderName.c_str());
// Store log file name before moving the unique_ptr
std::string logFileForDebug = info->logFileName;
_moduleLoggers[moduleName] = std::move(info);
TC_LOG_DEBUG("server.loading", "ModuleLogManager: Registered module '{}' with log file '{}'",
moduleName, logFileForDebug);
return true;
}
bool ModuleLogManager::InitializeModuleLogging(std::string const& moduleName)
{
std::lock_guard<std::mutex> lock(_loggerMutex);
auto it = _moduleLoggers.find(moduleName);
if (it == _moduleLoggers.end())
{
TC_LOG_ERROR("server.loading", "ModuleLogManager: Cannot initialize unregistered module '{}'", moduleName);
return false;
}
auto& info = *it->second;
if (info.initialized)
{
printf("=== MODULE LOG DEBUG: Module '%s' already initialized, re-initializing with updated config ===\n", moduleName.c_str());
// Mark as not initialized so we can recreate with new settings
info.initialized = false;
}
// Load configuration from worldserver.conf
LoadModuleConfig(moduleName, info);
// Create TrinityCore logger and appender
if (!CreateModuleLogger(info))
{
TC_LOG_ERROR("server.loading", "ModuleLogManager: Failed to create logger for module '{}'", moduleName);
return false;
}
info.initialized = true;
TC_LOG_INFO("server.loading", "ModuleLogManager: Successfully initialized logging for module '{}' - Level: {}, File: '{}'",
moduleName, info.logLevel, info.logFileName);
return true;
}
bool ModuleLogManager::IsModuleInitialized(std::string const& moduleName) const
{
std::lock_guard<std::mutex> lock(_loggerMutex);
auto it = _moduleLoggers.find(moduleName);
return it != _moduleLoggers.end() && it->second->initialized;
}
uint8 ModuleLogManager::GetModuleLogLevel(std::string const& moduleName) const
{
std::lock_guard<std::mutex> lock(_loggerMutex);
auto it = _moduleLoggers.find(moduleName);
if (it == _moduleLoggers.end())
return 255; // Invalid level
return it->second->logLevel;
}
void ModuleLogManager::LogModuleMessage(std::string const& moduleName, uint8 level, std::string const& message)
{
if (!IsModuleInitialized(moduleName))
return;
// Use TrinityCore's logging system with our unique file logger name
std::string loggerName = Trinity::StringFormat("module.{}.file", moduleName);
switch (level)
{
case 0: TC_LOG_FATAL(loggerName.c_str(), "{}", message); break;
case 1: TC_LOG_ERROR(loggerName.c_str(), "{}", message); break;
case 2: TC_LOG_WARN(loggerName.c_str(), "{}", message); break;
case 3: TC_LOG_INFO(loggerName.c_str(), "{}", message); break;
case 4: TC_LOG_DEBUG(loggerName.c_str(), "{}", message); break;
case 5: TC_LOG_TRACE(loggerName.c_str(), "{}", message); break;
default: TC_LOG_INFO(loggerName.c_str(), "{}", message); break;
}
}
bool ModuleLogManager::SetModuleConfig(std::string const& moduleName, uint8 logLevel, std::string const& logFileName)
{
std::lock_guard<std::mutex> lock(_loggerMutex);
auto it = _moduleLoggers.find(moduleName);
if (it == _moduleLoggers.end())
{
TC_LOG_ERROR("server.loading", "ModuleLogManager: Cannot set config for unregistered module '{}'", moduleName);
return false;
}
auto& info = *it->second;
info.logLevel = logLevel;
if (!logFileName.empty())
info.logFileName = logFileName;
TC_LOG_DEBUG("server.loading", "ModuleLogManager: Updated config for module '{}' - Level: {}, File: '{}'",
moduleName, info.logLevel, info.logFileName);
return true;
}
void ModuleLogManager::Shutdown()
{
std::lock_guard<std::mutex> lock(_loggerMutex);
TC_LOG_INFO("server.loading", "ModuleLogManager: Shutting down {} module loggers", _moduleLoggers.size());
for (auto& [moduleName, info] : _moduleLoggers)
{
if (info->initialized)
{
TC_LOG_DEBUG("server.loading", "ModuleLogManager: Shutting down logger for module '{}'", moduleName);
info->initialized = false;
}
}
_moduleLoggers.clear();
}
bool ModuleLogManager::CreateModuleLogger(ModuleLogInfo& info)
{
printf("=== MODULE LOG DEBUG: CreateModuleLogger() entered for '%s' ===\n", info.name.c_str());
try
{
// Check if ModulePlayerbot appender already exists from worldserver.conf
std::string preferredAppenderName = "ModulePlayerbot";
printf("=== MODULE LOG DEBUG: Checking if existing appender '%s' exists ===\n", preferredAppenderName.c_str());
// For playerbot module, create a NEW appender for the Playerbot.log file
// The existing ModulePlayerbot appender in worldserver.conf goes to Playerbot1.log
// We need our own appender for Playerbot.log (from playerbots.conf)
std::string appenderConfig = Trinity::StringFormat("2,0,1,{}", info.logFileName);
printf("=== MODULE LOG DEBUG: appenderConfig = '%s' ===\n", appenderConfig.c_str());
std::string fullAppenderName = "Appender." + info.appenderName;
printf("=== MODULE LOG DEBUG: About to call CreateAppenderFromConfigLine with '%s' ===\n", fullAppenderName.c_str());
sLog->CreateAppenderFromConfigLine(fullAppenderName, appenderConfig);
printf("=== MODULE LOG DEBUG: CreateAppenderFromConfigLine SUCCESS ===\n");
// Check if logger already exists from worldserver.conf
Logger const* existingLogger = sLog->GetEnabledLogger(info.loggerName, LOG_LEVEL_TRACE);
if (existingLogger) {
printf("=== MODULE LOG DEBUG: Found existing logger '%s', it already exists from worldserver.conf ===\n", info.loggerName.c_str());
printf("=== MODULE LOG DEBUG: Existing logger found - our TC_LOG calls should work with existing configuration ===\n");
} else {
printf("=== MODULE LOG DEBUG: No existing logger, creating new one ===\n");
// Create logger that routes to our appender
std::string loggerConfig = Trinity::StringFormat("4,{}", info.appenderName);
std::string fullLoggerName = "Logger." + info.loggerName;
printf("=== MODULE LOG DEBUG: loggerConfig = '%s' ===\n", loggerConfig.c_str());
printf("=== MODULE LOG DEBUG: About to call CreateLoggerFromConfigLine with '%s' ===\n", fullLoggerName.c_str());
sLog->CreateLoggerFromConfigLine(fullLoggerName, loggerConfig);
printf("=== MODULE LOG DEBUG: CreateLoggerFromConfigLine SUCCESS ===\n");
}
// Test the logger immediately - try both the specific logger and a direct appender test
printf("=== MODULE LOG DEBUG: About to test TC_LOG to our logger '%s' ===\n", info.loggerName.c_str());
TC_LOG_ERROR(info.loggerName.c_str(), "DIRECT TEST MESSAGE: ModuleLogManager successfully created logger!");
printf("=== MODULE LOG DEBUG: TC_LOG test call completed ===\n");
// Also test with the base module.playerbot logger that we know exists in worldserver.conf
if (info.name == "playerbot") {
printf("=== MODULE LOG DEBUG: Testing base module.playerbot logger from worldserver.conf ===\n");
TC_LOG_ERROR("module.playerbot", "BASE LOGGER TEST: Testing existing module.playerbot logger from worldserver.conf!");
printf("=== MODULE LOG DEBUG: Base logger test completed ===\n");
// The issue is that Logger.module.playerbot=4,Console Server doesn't include ModulePlayerbot appender
// Let's try to create a logger configuration that includes the ModulePlayerbot appender
printf("=== MODULE LOG DEBUG: Creating logger configuration that routes to ModulePlayerbot appender ===\n");
std::string enhancedLoggerConfig = Trinity::StringFormat("4,Console Server {}", info.appenderName);
std::string enhancedLoggerName = "Logger.module.playerbot.enhanced";
printf("=== MODULE LOG DEBUG: enhancedLoggerConfig = '%s' ===\n", enhancedLoggerConfig.c_str());
printf("=== MODULE LOG DEBUG: About to create enhanced logger '%s' ===\n", enhancedLoggerName.c_str());
sLog->CreateLoggerFromConfigLine(enhancedLoggerName, enhancedLoggerConfig);
// Test the enhanced logger
printf("=== MODULE LOG DEBUG: Testing enhanced logger ===\n");
TC_LOG_ERROR("module.playerbot.enhanced", "ENHANCED LOGGER TEST: This should appear in Playerbot.log!");
printf("=== MODULE LOG DEBUG: Enhanced logger test completed ===\n");
}
TC_LOG_DEBUG("server.loading", "ModuleLogManager: Created logger '{}' with appender '{}' for file '{}'",
info.loggerName, info.appenderName, info.logFileName);
return true;
}
catch (std::exception const& e)
{
TC_LOG_ERROR("server.loading", "ModuleLogManager: Exception creating logger for '{}': {}", info.name, e.what());
return false;
}
catch (...)
{
TC_LOG_ERROR("server.loading", "ModuleLogManager: Unknown exception creating logger for '{}'", info.name);
return false;
}
}
void ModuleLogManager::LoadModuleConfig(std::string const& moduleName, ModuleLogInfo& info)
{
printf("=== MODULE LOG DEBUG: LoadModuleConfig() entered for '%s' ===\n", moduleName.c_str());
// For playerbot module, try to get config from PlayerbotConfig if it's loaded
if (moduleName == "playerbot") {
printf("=== MODULE LOG DEBUG: This is playerbot module, trying to get config from PlayerbotConfig ===\n");
// Try to get PlayerbotConfig instance (may not be loaded yet)
// If PlayerbotConfig is loaded, it will call SetModuleConfig later
// For now, we use the default values passed during registration
printf("=== MODULE LOG DEBUG: Using registration defaults - Level: %d, File: '%s' ===\n",
(int)info.logLevel, info.logFileName.c_str());
}
TC_LOG_DEBUG("server.loading", "ModuleLogManager: Using config for module '{}' - Level: {}, File: '{}'",
moduleName, info.logLevel, info.logFileName);
}
std::pair<std::string, std::string> ModuleLogManager::GenerateLoggerNames(std::string const& moduleName)
{
// Generate unique names that won't conflict with worldserver.conf
// Use "module.playerbot.file" instead of "module.playerbot" to avoid conflicts
std::string loggerName = Trinity::StringFormat("module.{}.file", moduleName);
std::string appenderName = Trinity::StringFormat("Module{}File", moduleName);
// Capitalize first letter of module name in appender for consistency
if (appenderName.length() > 6)
appenderName[6] = std::toupper(appenderName[6]); // Position 6 is after "Module"
return std::make_pair(loggerName, appenderName);
}
} // namespace Trinity
@@ -0,0 +1,188 @@
/*
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*/
#pragma once
#include "Define.h"
#include "Log.h"
#include <string>
#include <unordered_map>
#include <memory>
#include <mutex>
namespace Trinity
{
/**
* @brief Centralized logging manager for TrinityCore modules
*
* This class provides a standardized logging API for modules, following TrinityCore
* patterns while maintaining module isolation. It integrates with TrinityCore's
* existing logging system and worldserver.conf configuration.
*
* Design Goals:
* - Consistent logging API across all modules
* - Integration with existing TrinityCore logging infrastructure
* - Configuration through worldserver.conf (no separate config files)
* - Automatic log file management
* - Module isolation (no core modifications)
*/
class TC_GAME_API ModuleLogManager
{
public:
ModuleLogManager(ModuleLogManager const&) = delete;
ModuleLogManager& operator=(ModuleLogManager const&) = delete;
static ModuleLogManager* instance();
/**
* @brief Register a module for logging
* @param moduleName Name of the module (e.g., "playerbot", "auction")
* @param defaultLevel Default log level if not configured
* @param logFileName Optional specific log file name (defaults to ModuleName.log)
*/
bool RegisterModule(std::string const& moduleName, uint8 defaultLevel = 3,
std::string const& logFileName = "");
/**
* @brief Initialize logging for a registered module
* @param moduleName Name of the module to initialize
* @return true if initialization succeeded
*/
bool InitializeModuleLogging(std::string const& moduleName);
/**
* @brief Check if a module is registered and initialized
* @param moduleName Name of the module to check
* @return true if module logging is ready
*/
bool IsModuleInitialized(std::string const& moduleName) const;
/**
* @brief Get the log level for a specific module
* @param moduleName Name of the module
* @return Log level (0-5), or 255 if module not found
*/
uint8 GetModuleLogLevel(std::string const& moduleName) const;
/**
* @brief Log a message for a specific module
* @param moduleName Name of the module
* @param level Log level
* @param message Message to log
*/
void LogModuleMessage(std::string const& moduleName, uint8 level, std::string const& message);
/**
* @brief Set module-specific configuration after registration
* @param moduleName Name of the module
* @param logLevel Log level override
* @param logFileName Log file name override
*/
bool SetModuleConfig(std::string const& moduleName, uint8 logLevel, std::string const& logFileName);
/**
* @brief Shutdown logging for all registered modules
*/
void Shutdown();
private:
ModuleLogManager() = default;
~ModuleLogManager() = default;
struct ModuleLogInfo
{
std::string name;
std::string logFileName;
std::string loggerName; // Logger name in TrinityCore format
std::string appenderName; // Appender name in TrinityCore format
uint8 logLevel;
bool initialized;
ModuleLogInfo() : logLevel(3), initialized(false) {}
};
std::unordered_map<std::string, std::unique_ptr<ModuleLogInfo>> _moduleLoggers;
mutable std::mutex _loggerMutex;
/**
* @brief Create TrinityCore logger and appender for a module
* @param info Module log information
* @return true if creation succeeded
*/
bool CreateModuleLogger(ModuleLogInfo& info);
/**
* @brief Get configuration from worldserver.conf for a module
* @param moduleName Name of the module
* @param info Module log information to populate
*/
void LoadModuleConfig(std::string const& moduleName, ModuleLogInfo& info);
/**
* @brief Generate standardized logger/appender names
* @param moduleName Name of the module
* @return pair of logger name and appender name
*/
std::pair<std::string, std::string> GenerateLoggerNames(std::string const& moduleName);
};
// Convenience macros for module logging
#define TC_LOG_MODULE_FATAL(module, format, ...) \
do { \
if (Trinity::ModuleLogManager::instance()->IsModuleInitialized(module)) { \
std::string loggerName = std::string("module.") + module; \
TC_LOG_FATAL(loggerName.c_str(), format, ##__VA_ARGS__); \
} \
} while (0)
#define TC_LOG_MODULE_ERROR(module, format, ...) \
do { \
if (Trinity::ModuleLogManager::instance()->IsModuleInitialized(module)) { \
std::string loggerName = std::string("module.") + module; \
TC_LOG_ERROR(loggerName.c_str(), format, ##__VA_ARGS__); \
} \
} while (0)
#define TC_LOG_MODULE_WARN(module, format, ...) \
do { \
if (Trinity::ModuleLogManager::instance()->IsModuleInitialized(module)) { \
std::string loggerName = std::string("module.") + module; \
TC_LOG_WARN(loggerName.c_str(), format, ##__VA_ARGS__); \
} \
} while (0)
#define TC_LOG_MODULE_INFO(module, format, ...) \
do { \
if (Trinity::ModuleLogManager::instance()->IsModuleInitialized(module)) { \
std::string loggerName = std::string("module.") + module; \
TC_LOG_INFO(loggerName.c_str(), format, ##__VA_ARGS__); \
} \
} while (0)
#define TC_LOG_MODULE_DEBUG(module, format, ...) \
do { \
if (Trinity::ModuleLogManager::instance()->IsModuleInitialized(module)) { \
std::string loggerName = std::string("module.") + module; \
TC_LOG_DEBUG(loggerName.c_str(), format, ##__VA_ARGS__); \
} \
} while (0)
#define TC_LOG_MODULE_TRACE(module, format, ...) \
do { \
if (Trinity::ModuleLogManager::instance()->IsModuleInitialized(module)) { \
std::string loggerName = std::string("module.") + module; \
TC_LOG_TRACE(loggerName.c_str(), format, ##__VA_ARGS__); \
} \
} while (0)
// Singleton access
#define sModuleLogManager Trinity::ModuleLogManager::instance()
} // namespace Trinity
@@ -0,0 +1,106 @@
#include "ModuleUpdateManager.h"
#include "Log.h"
#include "Timer.h"
#include <chrono>
namespace Trinity
{
ModuleUpdateManager* ModuleUpdateManager::instance()
{
static ModuleUpdateManager instance;
return &instance;
}
bool ModuleUpdateManager::RegisterModule(std::string const& moduleName, UpdateCallback callback)
{
if (moduleName.empty() || !callback)
{
TC_LOG_ERROR("server.loading", "ModuleUpdateManager: Cannot register module with empty name or invalid callback");
return false;
}
std::lock_guard<std::mutex> lock(_modulesMutex);
if (_registeredModules.find(moduleName) != _registeredModules.end())
{
TC_LOG_WARN("server.loading", "ModuleUpdateManager: Module '{}' is already registered for updates", moduleName);
return false;
}
ModuleUpdateInfo info;
info.moduleName = moduleName;
info.callback = std::move(callback);
info.updateCount = 0;
info.totalUpdateTime = 0;
_registeredModules[moduleName] = std::move(info);
TC_LOG_INFO("server.loading", "ModuleUpdateManager: Successfully registered module '{}' for world updates", moduleName);
return true;
}
void ModuleUpdateManager::UnregisterModule(std::string const& moduleName)
{
std::lock_guard<std::mutex> lock(_modulesMutex);
auto it = _registeredModules.find(moduleName);
if (it != _registeredModules.end())
{
TC_LOG_INFO("server.loading", "ModuleUpdateManager: Unregistered module '{}' (processed {} updates, avg time: {:.3f}ms)",
moduleName, it->second.updateCount,
it->second.updateCount > 0 ? (it->second.totalUpdateTime / static_cast<double>(it->second.updateCount) / 1000.0) : 0.0);
_registeredModules.erase(it);
}
}
void ModuleUpdateManager::Update(uint32 diff)
{
std::lock_guard<std::mutex> lock(_modulesMutex);
for (auto& [moduleName, info] : _registeredModules)
{
try
{
auto startTime = std::chrono::high_resolution_clock::now();
info.callback(diff);
auto endTime = std::chrono::high_resolution_clock::now();
auto duration = std::chrono::duration_cast<std::chrono::microseconds>(endTime - startTime);
info.updateCount++;
info.totalUpdateTime += static_cast<uint32>(duration.count());
// Log performance warning if update takes too long
if (duration.count() > 50000) // 50ms threshold
{
TC_LOG_WARN("server.loading", "ModuleUpdateManager: Module '{}' update took {}ms (threshold: 50ms)",
moduleName, duration.count() / 1000.0f);
}
}
catch (std::exception const& ex)
{
TC_LOG_ERROR("server.loading", "ModuleUpdateManager: Exception in module '{}' update: {}", moduleName, ex.what());
}
catch (...)
{
TC_LOG_ERROR("server.loading", "ModuleUpdateManager: Unknown exception in module '{}' update", moduleName);
}
}
}
bool ModuleUpdateManager::IsModuleRegistered(std::string const& moduleName) const
{
std::lock_guard<std::mutex> lock(_modulesMutex);
return _registeredModules.find(moduleName) != _registeredModules.end();
}
uint32 ModuleUpdateManager::GetRegisteredModuleCount() const
{
std::lock_guard<std::mutex> lock(_modulesMutex);
return static_cast<uint32>(_registeredModules.size());
}
}
@@ -0,0 +1,43 @@
#pragma once
#include "Define.h"
#include <string>
#include <unordered_map>
#include <functional>
#include <mutex>
namespace Trinity
{
class TC_GAME_API ModuleUpdateManager
{
public:
using UpdateCallback = std::function<void(uint32)>;
static ModuleUpdateManager* instance();
bool RegisterModule(std::string const& moduleName, UpdateCallback callback);
void UnregisterModule(std::string const& moduleName);
void Update(uint32 diff);
bool IsModuleRegistered(std::string const& moduleName) const;
uint32 GetRegisteredModuleCount() const;
private:
ModuleUpdateManager() = default;
~ModuleUpdateManager() = default;
ModuleUpdateManager(ModuleUpdateManager const&) = delete;
ModuleUpdateManager& operator=(ModuleUpdateManager const&) = delete;
struct ModuleUpdateInfo
{
std::string moduleName;
UpdateCallback callback;
uint32 updateCount = 0;
uint32 totalUpdateTime = 0;
};
mutable std::mutex _modulesMutex;
std::unordered_map<std::string, ModuleUpdateInfo> _registeredModules;
};
}
#define sModuleUpdateManager Trinity::ModuleUpdateManager::instance()
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,8 @@
## Interface: 16001
## Title: WoW Forever Bots
## Notes: One-click PlayerbotV2 companions: add a bot of any class and role, call, dismiss and command your bots.
## Author: Karrz
## Version: 0.2.0
## SavedVariables: ForeverBotsDB
ForeverBots.lua
@@ -0,0 +1,96 @@
# WoW Forever Bots (folder `ForeverBots`)
A small Classic 1.60 addon with buttons for the server's `.bot` commands. It only sends ordinary chat, so it
does not depend on the addon-message protocol PlayerbotControl uses.
Install: copy this folder to `<client>\_classic_beta_\Interface\AddOns\ForeverBots` (the folder name must stay
`ForeverBots`). If the character screen's AddOns list marks it out of date, tick "Load out of date AddOns".
In game: `/fb` opens the window. The window is grouped under headings: Orders to the group (move and fight, wipe and
regroup, formation and spacing, tanks and markers), Assign a bot to an icon, Your bots. Hover any button for what it does.
- "Add bots >" at the top opens a separate drop-down beside the window: "Select gear" (Match my gear, Best for their level,
Best in slot, Tier 1, 2, 3; remembered; sent to the group as `gear match|best|bis|t1|t2|t3` before an add) and one button per
class and role.
- Two switches beside it: AoE (whispers `aoe_all on|off` to one of your bots; it applies to the whole group) and CC (group
order `crowdcontrol on|off`). The icon shows the state last sent.
- One button per class and role: adds that bot (`.bot add <class> <role>`). It joins you at your level, geared,
in your group.
- Orders to the group: Follow, Stay, Attack (your target), Resume; Pull (your tank bots open on your target, the
rest join once it is engaged), Flee (break off and run to you), Come (teleport to you), Stop (stop attacking and
return to normal), Release (after a wipe: every dead bot releases its spirit, runs back to its corpse as a ghost,
into the instance through its portal if it died inside, revives there and rejoins you; living bots ignore it).
They go out in party/raid chat, so typing the word there does the same; `assist` = attack. Whispering `release`
to one bot releases only that bot.
- Follow holds until you hand the fight back: while it stands the bots follow you and only defend; they do not
advance or pull on their own (in a 5-man or a raid) until you say Attack, Pull or Resume, or attack something
yourself. A party that is not a raid group never runs the raid autopilot in a raid instance: it follows you and
defends.
- Pull back (`pull back`, `pullback` or `pull and back` in party/raid chat, the Pull back button, `/fb pullback`): your
main tank bot (a raid's Main Tank flag, else a tank bot) opens on your target (else the skull) from range with a
throw / shoot / Faerie Fire / Judgement, runs back to the rally point (Set rally) or, with none, to where it
stood, and tanks the mob there so nothing else aggros. Other bots ignore it. Gives up after 30 s.
- Fall back (`fallback`, `fall back` or `back` in party/raid chat): every bot drops its target and
runs to the rally point - the spot set with Set rally (`rally here`), else where you stand. Combat does not stop
the run; healers keep healing with instant spells on the way. There they re-form: tanks in front facing the way
they came, melee just behind, ranged and healers on an arc behind them. They fight only mobs that follow them
there (within about 15 yards of the rally, or hitting someone at it) and chase nobody past about 20 yards. They
stay there until Attack, Pull or Resume (Follow switches back to following you).
- Formation (Circle, Arrow, Line, No form.; `formation circle|arrow|wedge|line|none` in party/raid chat) and spacing
(Tight about 2.5 yards, Close about 4, the default, Spread about 8; `spacing tight|close|spread`, also `tight`,
`close`, `spread out`): out of combat the bots follow a slot round you (circle round you, arrow pointing the way you
face, line abreast behind you; tanks in front, healers at the back; slots are stable per bot and turn with you).
None is the plain follow. It stays until you change it. In combat and in raid mechanics the raid plan's positions
win; the spacing also scales the raid ranged / pre-pull spacing.
- Distance (the - / + stepper, 1 to 20 yards, one per click; `distance <n>` / `follow distance <n>` in party/raid chat, `/fb distance <n>`):
how far the bots follow you out of combat; it also sets the formation spacing to the same yards. Saved in the addon
(ForeverBotsDB.distance) and re-sent silently on login and when the group changes; the server keeps it per bot.
Raid combat positions are unaffected.
- Main tank (`set main tank <name>`, `main tank <name>`; no name = your current target): sets the raid's Main Tank
flag on that raid member, the same as the raid frame's right-click. Raid groups only.
- Tank markers (raids): the bot main tank marks the mob it pulls with skull and each off tank marks its own mob (or
the pack mob reserved for it) with the next markers (cross, star, circle, diamond, triangle, moon, square), and the
raid's DPS kills skull first, then the next markers in that order. The marks come off when the pack is dead. To
override, give a tank a marker yourself: the marker button cycles the marker, "Tank target" gives it to the bot
tank you have targeted (`tank <name> <marker>`; `tank <name> clear`, "Clear tanks" = `clear tanks`). That tank
then holds whichever mob carries the marker (mark it with the raid icons yourself), instead of the automatic split.
Switch off with `Playerbot.Behavior.TankMarkers = 0`.
- Assign a bot to a raid icon (the client cannot mark a friendly bot, so the panel does it): target a bot and click
one of the eight icons in the "Assign a bot to an icon" section (or type `assign <name|target> <marker> [tank|cc|kill]`
in party/raid chat, or `/fb assign <name> <marker> [role]`). Mark the mobs yourself with the normal raid target menu;
the bot follows its icon. Role auto: a tank bot tanks the mob carrying that icon, a crowd-control class (mage, warlock,
priest, hunter, rogue, druid, paladin) crowd-controls it until a skull goes on it, any other bot kills it first. The
Role button (auto, tank, cc, kill) overrides that for the next assignment only (skull cannot be crowd-controlled).
right-click an icon clears it (`assign clear <marker|name>`), Clear all clears everything (`assign clear`). A bot holds
one assignment; a tank icon belongs to one tank. The list under the icons shows what the server holds (icon, bot,
role); it asks the server (`assign list`) when the panel opens, after each click and every 5 seconds, and one bot
answers with hidden whispers `ASSIGN|<marker 0..7>|<name>|<role>` ... `ASSIGN|END|<count>`. `/fb assign list` also
prints it in chat. Assignments live in memory until cleared (not saved across a server restart). Needs
`Playerbot.Behavior.TankMarkers` (tank, kill) and `Playerbot.Behavior.MarkCc` (cc).
- Bots release on their own too: when you release (they run back with you and revive next to you), and after a
wipe with nobody left alive in the instance. While a group healer (or you, as a priest, paladin, shaman or druid)
is alive next to their bodies they wait for a rez instead. After reviving they rebuff and eat/drink; a bot main
tank does not start the next pull while anyone is dead or a healer is under 80% mana.
- Your bots: Call saved (`.summon saved`, same as `.bot call all` but open to normal players: the bots on your saved list and every bot in your group), Save group (`.bot save all`: every
bot with you goes on the list), Dismiss all, Unsave all (empties the list), Delete target (asks first, then
deletes the targeted bot's character for good), List (`saved` marks the ones on the list), Regear all (`.bot regear
all`: the same bots as Call saved, online ones only, get their gear re-rolled so they don't all wear the same
pieces; better pieces they already wear stay, replaced ones go to their bags).
Per-bot control (whisper or the floating panel): every order that works in party/raid chat also works as a whisper to ONE
bot (`/w Raveni follow`, `stay`, `attack`, `pull back`, `distance 8`, `range 8`, `rti skull`, `tank star`, `assign star tank`,
`assign clear`). A whisper acts on that bot only, that bot always answers with a confirming whisper such as `Raveni: tank
on Star`, `Raveni: attacking <target>`, `Raveni: following at 8 yards`. `assign <marker> [tank|cc|kill]` with no name is the
whispered bot itself. Only the bot's owner may whisper it orders. When your target is a friendly player of your group, the
small ForeverBotsBot panel appears next to the target frame (drag it; the position is saved): the eight icons (click assigns
the bot, right-click clears; the Role button picks tank/cc/kill for the next click, default auto), Follow, Stay, Attack
(your target), Pull back, Dist -/+ (this bot only), Dismiss, and a status line showing the bot's confirmation. The
confirmation whispers are hidden from chat. `/fb bot on|off` toggles the panel (default on). The client cannot tell a bot
from a human group member, so the panel shows for any friendly party/raid member (a `?` after the name until that player
has answered a whisper order); do not use it on real players. Unit right-click menu: an entry "ForeverBots" is added only
where the client offers `Menu.ModifyMenu` (untested here); the legacy UnitPopupMenus tables are deliberately not touched.
`/fb add <class> [tank|healer|dps]`, `/fb call|dismiss|save|unsave|regear [name|all]`, `/fb delete <name>`, `/fb list`,
The window stays where you put it and stays open (it is not closed by Escape, clicks, combat or target changes; its open state survives /reload and relog). `/fb` toggles it, or use the X button.
`/fb fallback`, `/fb pullback`, `/fb rally`, `/fb formation circle|arrow|line|none`, `/fb spacing tight|close|spread`, `/fb distance <1-20>` and `/fb maintank [name]` and `/fb tank <name> <marker>|clear` work without the window.
The `.bot` commands need a GM account (gm level 3 on the realm).
+403
View File
@@ -0,0 +1,403 @@
# WoW Forever Bots: calling, ordering and troubleshooting your bots
This is the player-facing guide to WoW Forever Bots companions (and the bots that live in the world). Everything
here was checked against the source of this branch; lines marked **(unverified)** or **(not implemented)** say
what could not be confirmed. Server operators: the config keys are in `conf/playerbot.conf.dist`.
## Contents
1. [The three ways to give an order](#1-the-three-ways-to-give-an-order)
2. [Getting bots: add, call, save, dismiss](#2-getting-bots-add-call-save-dismiss)
3. [The ForeverBots addon (`/fb`)](#3-the-foreverbots-addon-fb)
4. [Owner orders, with examples](#4-owner-orders-with-examples)
5. [Marks, crowd control and tank assignment](#5-marks-crowd-control-and-tank-assignment)
6. [Formations, spacing and distance](#6-formations-spacing-and-distance)
7. [Raid orders](#7-raid-orders)
8. [Instance rules](#8-instance-rules)
9. [Battlegrounds](#9-battlegrounds)
10. [Quests](#10-quests)
11. [World bots](#11-world-bots)
12. [Config keys](#12-config-keys)
13. [Log tags for troubleshooting](#13-log-tags-for-troubleshooting)
14. [Known gaps](#14-known-gaps)
---
## 1. The three ways to give an order
Only the **owner** of a bot (the account that added or adopted it; for an unowned bot, its group) can order it.
Orders are case-insensitive plain words.
| Channel | How | Who answers |
|---|---|---|
| **Whisper to one bot** | `/w Raveni follow` | That bot only. It always answers with a short confirming whisper (`Raveni: following at 5 yards`). |
| **Party or raid chat** | type the bare word, e.g. `follow` | Every bot of yours in the group acts. Questions (`who`, `help`) are answered by one bot, the lowest-guid one, so a raid does not answer forty times; per-bot questions (`stats`, `gear`) are answered by every bot while you have at most 8 in the group, otherwise by one. |
| **The panel** | `/fb` window and the per-bot panel next to a targeted group member | The buttons send the same words as chat or whispers. |
Rules worth knowing:
- Only words on the group allow-list are picked up from party/raid chat. Ordinary chatter is ignored. Words that
are not on the list (for example `inv`, `repair_all`) work by whisper only.
- A `;` in front of a party line (`;tank: attack`) sends it through the full whisper parser, including address
prefixes.
- **Address prefixes** (whisper or `;`): `all:`, `squad:`, `here:`, `tank:`, `healer:`, `dps:`, `<class>:` (for
example `mage:`), `<spec>:`, `<BotName>:` before the order. ike3-style selectors also work with
`Playerbot.Behavior.Ike3Commands`: `@skull`, `@star`, ... (bots holding that icon or targeting that mob),
`@tank`, `@healer`, `@dps`, `@ranged`, `@melee`, `@<class>`.
- The whisper command prefix `Playerbot.Interact.CommandPrefix` (default `!`) exists in the config. **(unverified:**
whether the parser still needs it; plain whispers work without it.)
- Anything not recognised is silently dropped (and logged, see `[owner_order]`).
## 2. Getting bots: add, call, save, dismiss
`.bot` commands need a GM account (level 3 on the realm). The addon buttons run the same commands.
| Command | What it does |
|---|---|
| `.bot add <class> [tank\|healer\|dps] [race] [male\|female]` | Creates a companion bound to you, levels it to you, teaches spells, sets role/talents/gear, brings it over and groups it. The role is kept across relog and `.bot call`. |
| `.bot call <name\|all>` | Brings back a companion (logs it in, joins your group). `all` = your saved roster plus every bot in your group. |
| `.summon <name\|all>` | Short form of `.bot call`: `.summon all` brings only the bots that are in your group right now (it never logs anyone in), `.summon saved` your saved roster plus the grouped bots (logging them in), `.summon <name>` one of your companions. Normal players can use it for their own bots only (any other name: "You can only summon your own bots"); game masters keep the normal summon of other players for any other name. Needs the auth update `2026_10_08_00_auth_player_summon.sql`. |
| `.bot save <name\|all>` | Puts a companion (or every bot with you) on your roster. |
| `.bot unsave <name\|all>` | Takes it off the roster; it stays yours and `.bot call <name>` still works. |
| `.bot dismiss <name\|all>` | Removes it from your group and logs it out. Gear is kept. |
| `.bot delete <name>` | Deletes the character for good (the addon asks first). |
| `.bot list` | Your companions, online or not (`saved` marks roster ones). |
| `.bot regear <name\|all>` | Re-rolls the equipment of online companions so they do not all wear the same pieces. Better pieces they wear stay; replaced ones go to the bags. |
| `.bot world` | Status of the world-bot spawner (Playerbot.World.*), console too. |
Group size is capped by the map you stand in, see [Instance rules](#8-instance-rules). In a group that is full,
`.bot add` and `.bot call` tell you why instead of silently failing.
## 3. The ForeverBots addon (`/fb`)
Install the `ForeverBots` folder into `Interface\AddOns` (the folder name must stay `ForeverBots`; tick "Load
out of date AddOns"). The addon only sends ordinary chat, so it needs nothing else on the client.
- `/fb` opens or closes the window (it stays open across relog). The window has:
- **Add buttons**: one per class and role (`.bot add <class> <role>`).
- **Orders**: Follow, Stay, Attack (your target), Resume, Pull, Flee, Come, Stop, Release, Pull back, Fall back,
Set rally. They go out in party/raid chat, so typing the word is identical.
- **Formation** (Circle, Arrow, Line, No form.) and **Spacing** (Tight, Close, Spread), and the **Distance**
stepper (1 to 20 yards).
- **Assign a bot to an icon**: eight raid icons, a Role button (auto, tank, cc, kill), a list of what the server
holds, Clear all.
- **Tank markers**: a marker button, Tank target, Clear tanks, and a Main tank entry.
- **Your bots**: Call saved, Save group, Dismiss all, Unsave all, Delete target, List, Regear all.
- **Per-bot panel**: when your target is a friendly party or raid member, a small panel appears next to the target
frame (drag it, position is saved): the eight icons (click assigns, right-click clears), Follow, Stay, Attack,
Pull back, Dist -/+, Dismiss and a status line with the bot's last confirmation. `/fb bot on|off` toggles it.
The client cannot tell a bot from a human, so do not use the panel on real players.
- Slash commands that work without the window: `/fb add <class> [role]`, `/fb call|dismiss|save|unsave|regear
[name|all]`, `/fb delete <name>`, `/fb list`, `/fb fallback`, `/fb pullback`, `/fb rally`, `/fb formation
circle|arrow|line|none`, `/fb spacing tight|close|spread`, `/fb distance <1-20>`, `/fb maintank [name]`, `/fb tank
<name> <marker>|clear`, `/fb assign <name> <marker> [role]`, `/fb assign list`.
- Confirmation whispers from bots are hidden from your chat frame by the addon (they feed the status line).
There is also an older `PlayerbotControl` addon (roster, stats, alts); this guide covers `ForeverBots`.
## 4. Owner orders, with examples
"Whisper" = `/w <bot> <order>`. "Group" = also accepted as a bare line in party/raid chat. Replies are whispers
from the bot.
### Movement and stance
| Order | Whisper | Group | Example and answer |
|---|---|---|---|
| `follow` | yes | yes | `follow` -> `Raveni: following at 5 yards`. Follow holds: while it stands, bots only defend and do not advance or pull until you say attack, pull or resume. `follow <name>`, `follow tank`, `follow healer`, `follow leader`, `follow stop` also work by whisper. |
| `stay` / `halt` | yes | yes (`stay`) | `stay` -> `Raveni: staying here`. |
| `hold` | yes | yes | Like stay but may fight what attacks it. `Hold: holding position.` |
| `defensive` | yes | yes | Same as hold: `Raveni: defensive, holding here and fighting only what attacks`. |
| `aggressive` | yes | yes | Back to autonomous: `Raveni: aggressive, engaging enemies on my own`. |
| `resume` | yes | yes | Autonomous again; `Resume: autonomous.` |
| `passive` / `stop` / `disengage` | yes | `passive`, `disengage` | Stop attacking: `Raveni: stopped`. |
| `come` | yes | yes | Teleports the bot to you and follows. `Raveni: coming to you`. |
| `summon` | yes | yes | Like `come`, with the summoning refusals: not while the bot is dead or in combat, not while you are in combat, not into a battleground, not into or out of an instance you are not both in. Answer on refusal: `Raveni: can't be summoned, I am in combat`. |
| `flee` / `retreat` | yes | `flee` | Break off and run to you: `Raveni: fleeing to you`. |
| `goto <x> <y>`, `goto <map> <x> <y>` | yes | no | Walk to a point (or travel cross-map by flight/portal/ship). |
| `unfollow` | yes | no | Stop following. |
| `invite` | yes | no | The bot invites you to its group: `Raveni: invite sent`. |
| `leave` | yes | no | The bot leaves the group. |
| `reset` | yes | no | Clears movement, attack and cast: `Reset: cleared movement / attack / cast.` |
| `release` | yes | yes | A dead bot releases and runs to its corpse (or back into the instance). Living bots ignore it. `release_all` by whisper. |
| `mount`, `dismount`, `sit`, `stand`, `hearth`, `bind` | yes | no | Single actions. `*_all` variants (`mount_all`, `hearth_all`, ...) act on every bot in the group. |
### Combat
| Order | Whisper | Group | Notes |
|---|---|---|---|
| `attack` / `kill` / `engage` | yes | `attack` | Attack your selected target: `Raveni: attacking Defias Thug`. In a raid the pull gate may hold DPS until the main tank opens (`not attacking yet (raid pull gate: the main tank opens)`). |
| `assist` | yes | yes | Group `assist` is turned into `attack`. |
| `pull [<sec>]` | yes | `pull` | Your tank bots open on your target, the rest join once it is engaged. With a raid Main Tank flag only that tank pulls. |
| `pull back` / `pullback` / `pull and back` | yes | yes | The main tank (or the assigned/closest tank) opens from range, runs to the rally point and tanks it there. Others hold. Gives up after 30 s. |
| `pull rti` | yes | yes | Opens on the mob carrying the bot's own rti symbol (Ike3Commands). |
| `max dps` / `save mana` / `normal` | yes | no | Burn mode (cooldowns on every fight), healers keep to efficient heals, clear both. Ike3Commands. |
| `focus <name\|clear>`, `target <entry>`, `mark <icon>`, `interrupt`, `cc`, `aoe [on\|off]` | yes | no | Finer combat control. |
### Questions and housekeeping (OwnerCommands)
| Order | Whisper | Group | What the bot answers |
|---|---|---|---|
| `help` / `?` | yes | yes (one bot) | Four lines: the orders, the questions, town and loot, raid words. `commands` prints the whole verb index. |
| `who` | yes | yes | `Raveni: level 60 Warrior (Protection), tank - following you`. |
| `stats` | yes | yes | `Raveni: health 3120/3120 (100%), item level 66, armor 2250, str 210 agi 110 sta 290 int 40, crit 4.1%`. Mana is added for mana users. `status` is the older diagnostic dump. |
| `gear` / `inventory` | yes | yes | `Raveni: 15 pieces worn, avg item level 66, best: Ironfoe, ...; 14 free bag slots; 12g 40s 5c`. `inv` lists bag items; `equipped` lists each worn slot. |
| `money`, `level`, `xp`, `dur`, `skills`, `recipes`, `rep`, `spec` | yes | no | One-line introspection verbs. |
| `sell grey` / `sell junk` / `s *` | yes | yes | Sells grey items to the vendor you have selected, else the nearest vendor the bot sees within 60 yards. In reach: `Raveni: selling 7 grey stack(s) to Dolanaar Vendor`. Farther away it walks over and asks you to say it again. No vendor: `no vendor within 60 yards`. Plain `sell` (selected vendor) and `sell <bag> <slot> [n]` also exist. |
| `repair` | yes | yes | Same pattern with a repair vendor: `Raveni: repairing at ...`. |
| `loot` | yes | yes | Need before greed with the usual etiquette (human gets first claim). `Raveni: need before greed, the usual rules`. |
| `loot all` | yes | yes | The bot rolls for itself on every drop and takes every corpse item, greys included. `Raveni: looting everything, greys included, and rolling for myself`. Memory only (resets on relog). |
### Gear and economy by whisper (selected NPC needed)
`buy <entry> [n]`, `buyfood`, `buypot`, `buybandage`, `buyall`, `use <entry>`, `equip <entry>`, `bank`, `auction`,
`mail`, `train`, `talents [apply]`, `upgrades [apply]`, `fly <node>` and the `*_all` broadcasts such as
`repair_all`, `sell_all`, `buyfood_all`. They need a selected vendor/auctioneer/flight master where the bot has
to interact. The full index is the `commands` whisper.
## 5. Marks, crowd control and tank assignment
All of these are group-allowed (party/raid chat) and whisperable.
- **Assign a bot to an icon**: `assign <name|target> <marker> [tank|cc|kill]`, `assign clear [marker|name]`,
`assign list`. Markers: `star circle diamond triangle moon square cross skull`. Mark the mobs yourself with the
raid target menu; the bot follows its icon. Role auto: a tank bot tanks the mob carrying the icon, a crowd-control
class (mage, warlock, priest, hunter, rogue, druid, paladin) crowd-controls it until a skull goes on it, anything
else kills it first. Whispered with no name (`assign star tank`) the whispered bot is the subject. Assignments are
memory only. Needs `TankMarkers` (tank, kill) and `MarkCc` (cc).
- **Tank markers**: `tank <name> <marker>`, `tank <name> clear`, `clear tanks`. A tank with a marker holds
whichever mob carries it. Whisper `tank star` to make that bot take Star (`Raveni: tank on Star`).
Without any, the raid plan splits mobs automatically: main tank marks skull, each off tank the next markers.
- **Kill and CC lists (ike3 rti)**: `rti <symbols>` sets the symbols a bot kills first, `rti cc <symbols>` the
ones it crowd-controls (skull never), `rti none`, `rti ?` reports, `rti raid` prints the roster and marks.
- **Main tank**: `set main tank <name>` or `main tank <name>` (no name = your target) sets the raid frame's Main Tank
flag. Raid groups only. With a main tank set, only that tank pulls.
- **Marks need an order** (`MarksNeedOrder`, default on): putting an icon on a mob never starts a fight by itself.
Bots engage after `attack`, `pull`, `pull back`, `pull rti` or `focus`.
- **Pull back vs fall back**: `pull back` is one tank pulling a mob home to the rally point. `fall back` (also
`fallback`, `back`) is the whole raid dropping its target and running to the rally point to re-form, see
[Raid orders](#7-raid-orders).
## 6. Formations, spacing and distance
| Order | Meaning |
|---|---|
| `formation circle\|arrow\|wedge\|line\|column\|none` | Out-of-combat slots round you (tanks in front, healers at the back). `none` is the plain follow. A bot also reports its slot with plain `formation`. |
| `spacing tight\|close\|spread` (also `tight`, `close`, `spread out`) | About 2.5 / 4 (default) / 8 yards. Also scales raid ranged spacing. |
| `distance <1-20>` / `follow distance <n>` | How far bots follow you; sets the spacing yards too. The addon re-sends it on login. Per bot by whisper. |
| `range <yards>` | Picks the nearest spacing preset. Ike3Commands. |
| `slot <n>`, `regroup` | Pin a formation slot; re-snap to the slot. |
In combat and in raid mechanics the raid plan's positions win over the formation.
## 7. Raid orders
| Order | Effect |
|---|---|
| `pull` | The main tank (else every tank bot) pulls your target; the rest follow once it is engaged. |
| `pull back` | See section 5. Exact phrase only, so it never reaches `pull`. |
| `fall back` / `fallback` / `back` | Every bot drops its target and runs to the rally point; tanks form in front, melee just behind, ranged and healers on an arc. They fight only what follows them there and stay until `attack`, `pull` or `resume` (`follow` returns to following you). |
| `rally here` / `rally` | Sets the rally point to where you stand. Without one, fall back uses your position. |
| `release` | After a wipe: dead bots release and run back (into the instance through its portal when they died inside). Bots also release on their own when you do, or after a full wipe. With `WipeReleaseWait` they wait 10-40 s for a rez when a healer lives. |
| `readycheck` / `rc` (whisper) | A bot starts a ready check. Bots answer a ready check on their own; with `ReadyCheckInfo` a low-health/mana or broken-gear bot answers not ready and says why. `ready_all` forces every bot's ack. |
A group chat order reaches every bot of yours; to address only some, whisper them or use a prefix such as
`tank:` or `@skull`.
## 8. Instance rules
- **Open world**: you have at most `Playerbot.Behavior.OpenWorldGroupCap` (default 5) of your own companions out at
once (`.bot add`, `.bot call`, saved roster, buttons). For more, find world bots and invite them: invited world
bots are not counted. Companions above the cap (called inside an instance) are dismissed 10 s after you walk out;
the ones grouped with you stay. Needs `InstanceGroupCap = 1`.
- **Inside an instance**: the cap is what the map holds (5 dungeon; 10, 20 or 40 raid, from the map data; fallback
5 / 40), for your companions and for the group. `.bot add`, `.bot call` and the buttons stop at it with `<map> is full: n/cap`. Walking into a smaller
instance with a bigger group warns you once.
- **Battlegrounds and arenas** are not capped by this rule.
- **Solo raid entry**: stock Trinity requires a raid group to enter a raid. Set `Instance.IgnoreRaid = 1` in
`worldserver.conf` to let a player enter without one. A party (non-raid) group of companions in a raid map
follows you and defends and does not run the raid autopilot (`OwnerFollowHold`).
- `follow` suspends the dungeon autopilot until you say `attack`, `pull` or `resume`.
## 9. Battleground behaviour
- Bots do **not** queue or fight bot-versus-bot on their own by default (`Playerbot.Bg.AutoSeed.Matches = 0`,
`Playerbot.Bg.AutoJoin = 0`). When a real player queues, the queue filler supplies both sides, tops up while the
player is in, and returns the bots to the pool afterwards. It needs `Playerbot.Population.TotalTarget > 0` or
`Playerbot.World.Enable = 1`.
- Humans have priority: with `Bg.MakeRoomForPlayers` the lowest-scoring bot of a full team leaves to make room
(never a flag carrier or a bot in combat) (`[bg_queue] MakeRoom`).
- In the match the BG coordinator (`Playerbot.Bg.Coordinator.Enable`) assigns objectives (caps, defence, escort)
and the Warsong, Arathi and Alterac scripts drive play.
- Owner verbs by whisper: `bg <type>` / `unbg` (queue and leave with a selected battlemaster), `bg_all`,
`unbg_all`, `bgrun [pause\|stop]`, `pvp`. `summon` is refused into a battleground you stand in.
## 10. Quests
The quest words call `QuestOrders` (`Bot/Quest/QuestOrders.h`). Each answers by whisper; group lines are accepted
for all of them.
| Order | Whisper | Group | What it does |
|---|---|---|---|
| `quests` / `quest list` / `ql` | yes | `quests`, `quest list` | Lists the bot's quest log. |
| `accept` / `accept all` | yes | `accept`, `accept all` | Accepts the offered quests of the quest giver in reach. |
| `drop <quest>` | yes | `drop quest <name>` | Abandons the named quest. Group form needs the word `quest` so ordinary chat ("drop it") never abandons anything. |
| `turn in` | yes | `turn in` | Hands in finished quests. |
| `share` | yes | `share` | Shares the bot's quests with the party. (`qshare <quest_id>` shares one.) |
**Status: these verbs are wired in the parser against `QuestOrders::{List,AcceptAll,Drop,TurnIn,Share}`.** They are
compiled in only when `Bot/Quest/QuestOrders.h` exists in the tree; without it `accept`, `drop`, `turn in` and
`share` answer `quest orders are not available in this build`, and `quests` falls back to the older
`Q<id> L<level>` list. Older helper verbs that always exist: `quest`, `wq`, `abandon <id>`, `abandonall`, `qshare`.
## 11. World bots
World bots are ambient characters with no owner (`Playerbot.World.Enable = 1` spawns them around real players;
`Playerbot.Population.TotalTarget > 0` fills the world). See `WORLD_BOTS.md` for the spawner.
- **Say and yell**: a world bot sometimes answers a real player's greeting, short question or its own name within
25 yards (60 s per bot, 8 s global, 1-4 s delay). `WorldBotSayReply`, log `[say_reply]`. A bot waves back at
`hi`/`hello` within 12 yards (`SocialEmotes`).
- **Whispers**: bots answer a whisper from any player (`BotWhisperable`). Only the owner's orders are obeyed.
- **Politeness** (`PoliteWorldBots`): a trade request is cancelled with "sorry, nothing to trade"; a group
invite is declined with a short whisper unless the bot is free to group; a duel from a stranger is accepted about
one time in three when the levels are within 5 and nothing is fighting, otherwise declined with a whisper.
Invites: `Playerbot.Interact.AutoAcceptInvites` (`none`, `friends_or_higher`, `guild_or_higher`, `anyone`).
- Companion banter (`PartyBanter`): a short lowercase line now and then on ready check, wipe, rez, death, boss
kill; never in a group over 15 or with `Playerbot.Chatter.Enabled = 0`.
- Hostile-faction world bots can be placed near you (`Playerbot.World.FriendlyPct`, default 80); set it to 100 to
avoid fights on a PvP realm.
## 12. Config keys
Defaults are those of `conf/playerbot.conf.dist`. Behaviour switches are read when the config loads; `1` is on.
**Owner command surface**
| Key | Default | Effect |
|---|---|---|
| `Playerbot.Behavior.OwnerCommands` | 1 | The plain-language words of section 4 (quests, accept, drop, turn in, share, loot, help, who, stats, gear, sell grey, repair, summon, invite, aggressive, defensive) |
| `Playerbot.Behavior.Ike3Commands` | 1 | `@selector` addressing, `pull rti`, `max dps`/`save mana`/`normal`, `rti raid`, `range` |
| `Playerbot.Behavior.OwnerFollowHold` | 1 | `follow` suspends the dungeon autopilot |
| `Playerbot.Behavior.Fallback` | 1 | `fall back`, `rally here` |
| `Playerbot.Behavior.PullBack` | 1 | `pull back` |
| `Playerbot.Behavior.Formation` | 1 | formation and spacing orders |
| `Playerbot.Behavior.DistanceOrder` | 1 | `distance <n>` |
| `Playerbot.Behavior.OwnerMainTank` | 1 | `set main tank` |
| `Playerbot.Behavior.TankMarkers` | 1 | `tank <name> <marker>`, `assign`, auto marking |
| `Playerbot.Behavior.MarkCc` | 1 | icon-driven crowd control, `rti cc` |
| `Playerbot.Behavior.MarksNeedOrder` | 1 | marks only plan; an order starts the fight |
| `Playerbot.Behavior.LootPolicy` | 1 | human-first loot etiquette (`loot all` bypasses it per bot) |
**Group size and instances**
| Key | Default |
|---|---|
| `Playerbot.Behavior.InstanceGroupCap` | 0 (off; 1 limits the companions to what the map holds) |
| `Playerbot.Behavior.OpenWorldGroupCap` | 5 |
| `Playerbot.Pve.Coordinator.Enable` | 1 |
| `Playerbot.Raid.Enable` | 1 |
| `Playerbot.Raid.BossWarnings` | 1 |
| `Playerbot.Behavior.DungeonFlow` / `DungeonAutopilot` / `DungeonLoot` | 1 / 1 / 1 |
| `Playerbot.Behavior.PullRecover` / `WipeReleaseWait` / `ReadyCheckInfo` | 1 / 1 / 1 |
| `Playerbot.TankThreatMultiplier` | 3.0 |
**Raid combat behaviour (all default 1)**: `RaidGear`, `AmmoSupply`, `TankRangedWeapon`, `HealClaims`, `CastFacing`,
`GroundSnap`, `ReFace`, `AvoidCircles`, `PackStop`, `RaidSpacing`, `SpreadOut`, `LooseMobHold`, `RaidBuffHold`,
`WarriorStanceDance`, `PurgeDuty`, `RangedSlow`, `SoloFlee`, `DruidHealForm`, `PullDiscipline`. Gear:
`Playerbot.Gear.MaxTier` (1), `Playerbot.Gear.RaidIlvlCap` (0).
**Social and world (default)**: `BotWhisperable` 1, `WorldBotSayReply` 1, `PoliteWorldBots` 1, `PartyBanter` 1,
`SocialEmotes` 1, `Fidget` 1, `Playerbot.Chatter.Enabled` 1, `Playerbot.Interact.AutoAcceptInvites` friends_or_higher,
`Playerbot.Interact.AutoLeaderHandover` 1, `Playerbot.World.Enable` 0 (`MaxBots` 100, `BotsPerPlayer` 25,
`ActivityRadius` 300, `FriendlyPct` 80), `Playerbot.Population.TotalTarget` 0.
**Battlegrounds**: `Playerbot.Bg.AutoSeed.Matches` 0, `Playerbot.Bg.AutoJoin` 0, `Playerbot.Bg.MakeRoomForPlayers` 1,
`Playerbot.Bg.Coordinator.Enable` 1.
**Realm**: `Instance.IgnoreRaid` (worldserver.conf, default 0) for solo raid entry.
## 13. Log tags for troubleshooting
The module logs nothing unless `Logger.playerbot.v2=3` is set. Grep the server log for the tag.
| Tag | What it tells you |
|---|---|
| `[owner_order]` | Every order a bot receives: source (whisper, party), raw text, resulting order state; unrecognised or refused (not the owner) lines are throttled per bot. Start here when a bot "ignores" you. |
| `[pull_back]` | Which tank was chosen for a pull back and why; every other bot holds. |
| `[fallback]` | A bot's rally slot and rank when it falls back, and its arrival. |
| `[assign]` | Icon assignments: the raw order, the stored result. |
| `[formation]` | Slot, owner position and distance, action taken (rate limited). |
| `[mark_gate]` | A marked mob held back awaiting your order (`MarksNeedOrder`). |
| `[mark_cc]` | Crowd-control assigned, cast, broken or released. |
| `[spread]` | Melee spreading round a victim (every 5 s, one bot). |
| `[role]` | The role a companion has and where it came from (declared, spec, fallback). |
| `[gear]` | Gear pass result: average item level, upgraded slots. |
| `[quest]` | A quest order the parser handed to `QuestOrders` (`[owner_order] [quest] ...`). |
| `[InstanceCap]` | Group larger than the map holds. |
| `[say_reply]` | A world bot's answer to a player's /say. |
| `[world]` | Spawner status line every 60 s. |
| `[death-recovery]`, `[raid_pull]`, `[raid_tank]`, `[solo_flee]`, `[bg_queue]`, `[cast_speed]`, `[GroupRelogin]` | Corpse runs, raid pulls and tanking, fleeing, battleground queues, cast pacing, bots re-joining after your login. |
`/whyidle` (whisper `whyidle`) explains the idle rule a bot chose; `diag` and `state` dump a bot's state.
## 14. Known gaps
- `trade`, and the ike3 strategy toggles `co`/`nc`/`ss` (+/- strategy lists), are **not implemented**. The
nearest equivalents are `max dps` / `save mana` / `normal`, `aoe`, `hold`/`defensive`/`aggressive`.
- `sell grey` and `repair` act at once only when the vendor is within interaction reach; from up to 60 yards the
bot walks over and you repeat the order. There is no standing "go and sell, then come back" order; the bots'
own vendor upkeep (idle vendor visit, bag-full recovery) still runs when they are not in a group.
- `loot all` is held in memory per bot and resets on relog.
- `aggressive` / `defensive` / `passive` map onto the existing manual modes (resume, hold, stop); there is no
separate attack-stance engine.
- Quest words depend on `Bot/Quest/QuestOrders.h` (section 10).
- Right-click unit-menu entry of the addon and the whisper `!` prefix are **(unverified)**.
## Auction house bot (GM)
GM commands (GM level 3) for the auction house bot (`AuctionHouseBot.*` in the world config):
| Command | What it does |
|---|---|
| `.ahbot status [all]` | Item counts of the AH bot per auction house and quality. |
| `.ahbot stats` | What the buyer spent today and its limits. |
| `.ahbot reload` | Re-reads the AH config. |
| `.ahbot refresh` | Expires the bot's unbid listings and restocks. |
| `.ahbot add [n]` | Adds `n` extra items per quality target (default 500) until the next reload. |
| `.ahbot rebuild [all]` | Stock command. `all` also expires bot listings that have bids. |
The buyer buys players' auctions up to 1.5x the fair price, after a 30-600 s delay, with a 5000 gold daily budget and 60 buys per hour (config keys `AuctionHouseBot.Buyer.*`). Put items up for sale as a player and the bots buy them in their own time.
## Gear
Level-60 (level-cap) companions are geared for raiding by role (`Playerbot.Behavior.RaidGear`): rare and epic pieces of required level 50+ picked by role stat weights, never PvP items, varied per bot among the best few. `.bot regear` (and the periodic gear pass) fill empty slots and swap a worn piece only when the new one scores at least 10% higher.
| Key | Default | What it does |
|---|---|---|
| `Playerbot.Gear.MaxTier` | 1 | Best raid tier the gear may come from, as an approximate item level ceiling: 0 = pre-raid / dungeon (63), 1 = Molten Core / Onyxia (76), 2 = Blackwing Lair (83), 2.5 = AQ40 (88), 3 = Naxxramas (92). Not read from item data. |
| `Playerbot.World.Gear.MaxTier` | 1 | The same scale for world / ambient / BG-fill bots (bots nobody owns); a world bot above it is re-geared down. |
| `Playerbot.World.Gear.EpicPercent` | 15 | Share of a world bot's slots that may hold an epic (0-100); the rest is blue or lower. |
| `Playerbot.Gear.RaidIlvlCap` | 0 | Explicit item level ceiling; above 0 it overrides `MaxTier`. |
| `Playerbot.Behavior.AcceptOwnerTrade` | 1 | A companion accepts a trade its owner opens, once the owner has accepted (gear and money gifts). The bot never offers anything, so nothing can be taken back through the window. Anyone else's trade is declined. Mail is not read by bots, so gifts go by trade. |
Gifts by trade: open a trade with the bot, put the items in, accept. The bot accepts, then its auto-equip rules wear what is an upgrade for its role (within a few minutes in the open world, at once in a dungeon, or say `equip upgrades`); the rest stays in its bags.
| Say or whisper | What the bot does |
|---|---|
| `equip upgrades` / `equip best` / `use your best gear` | Wears every bag item that is an upgrade (raid role score, +10%, at the level cap; the older stat rule below it) and whispers `Raveni: equipped [item] (+ilvl 8), [item] (+ilvl 3)` or `Raveni: nothing better in my bags`. |
| `equip <item link or name>` | Wears that bag item if it can use it, whatever its score. PvP items are refused (`I don't wear those`). `equip <item id>` still works. |
In party or raid chat every addressed bot answers (`all:`, `tank:`, `<Name>:` prefixes select which). Not done: `unequip`.
## Battleground queue (GM)
`.playerbot bgjoin wsg|ab|av|<id>` queues you, plus your group's in-bracket bots, for a battleground without the battlemaster window (`wsg` Warsong Gulch, `ab` Arathi Basin, `av` Alterac Valley, or a battleground type id). The battlemaster's Join button now also works on client 70205. A real player who queues joins a running battleground (the weakest bot leaves to make room) instead of opening a new one.
`.playerbot bgenter` accepts the pending battleground invite (use it if the Enter button does nothing). `.playerbot bgleave` leaves every battleground queue you are in.
## Craft orders (owner and group)
Whisper a bot of your group `craft <item link or name> [x5]` (or `craft list`). The bot makes it with the recipes and reagents it carries
(one craft at a time, up to 20 items) and mails the result to you; missing reagents are whispered back, trade them to the bot and ask again.
A bare `craft <spell id>` is the older owner command and still casts that recipe once. Idea and parser from Trixx34/ForeverBots (GPL-2.0).
@@ -0,0 +1,41 @@
// BagSizeTable - curated table of "universally available" general-purpose
// bag entries by capacity. Used by the vendor-visit FSM's bag-upgrade phase.
//
// All entries here are class ITEM_CLASS_CONTAINER, subclass 0 (generic bag).
// Profession-specific bags (Herb / Mining / Engineering / etc) are handled
// separately and depend on the bot's professions.
//
// Prices are vendor-buy approximations; actual cost depends on faction-
// reputation discount and vendor markup. The bag-upgrade rule applies a
// 20% safety margin on bot.gold so a slight under-estimate doesn't trip
// the buy.
#pragma once
#include "Define.h"
#include <array>
namespace Playerbot {
struct BagSizeRow
{
uint8 capacity; // Slot count
uint32 item_entry; // ItemTemplate.entry; vendor-buyable in starter zones
uint32 approx_price; // Vendor copper, no discount
};
// Sorted ascending by capacity. The buy logic walks the array picking the
// largest entry whose price ≤ gold * 0.5 (keep half gold for other needs).
// Entries beyond level-30ish content require crafting / AH; not stocked
// at NPC vendors. The lookup gracefully degrades to the largest entry
// whose price the bot can afford.
inline constexpr std::array<BagSizeRow, 6> kBagSizeTable = {{
{ 6, 4496, 500 }, // Linen Bag — ~5s
{ 8, 5572, 1500 }, // Wool Bag — ~15s
{ 10, 10050, 5000 }, // Mageweave Bag — ~50s
{ 14, 14046, 30000 }, // Runecloth Bag — ~3g
{ 16, 21841, 50000 }, // Netherweave Bag — ~5g
{ 20, 41599, 100000 }, // Frostweave Bag — ~10g
}};
} // namespace Playerbot
@@ -0,0 +1,175 @@
#include "BattlegroundScript.h"
#include "../BotSnapshotView.h"
#include "../BotSnapshot.h"
#include "Log.h"
#include <shared_mutex>
#include <unordered_map>
#include <unordered_set>
namespace Playerbot {
namespace {
// Cross-bot callout-claim state. Process-global (one BG fleet per
// worldserver). Hash key combines callout-kind in high 32 bits with
// the per-callout key (node entry / FC guid bucket / etc) in low.
std::shared_mutex g_callout_mtx;
std::unordered_map<uint64_t, uint32_t> g_callout_until_ms;
inline uint64_t MakeCalloutKey(uint32_t kind, uint64_t key)
{
return (uint64_t(kind) << 32) | (key & 0x00000000FFFFFFFFull);
}
} // anonymous
bool BgCalloutCoordinator::TryClaim(uint32_t kind, uint64_t key,
uint32_t now_ms, uint32_t lockout_ms)
{
const uint64_t k = MakeCalloutKey(kind, key);
{
std::shared_lock<std::shared_mutex> lk(g_callout_mtx);
auto it = g_callout_until_ms.find(k);
if (it != g_callout_until_ms.end() && now_ms < it->second)
return false; // somebody else already shouted within window
}
std::unique_lock<std::shared_mutex> lk(g_callout_mtx);
// Re-check under write lock (TOCTOU guard — another worker may have
// claimed in the gap between our shared-read and write-acquire).
auto it = g_callout_until_ms.find(k);
if (it != g_callout_until_ms.end() && now_ms < it->second)
return false;
g_callout_until_ms[k] = now_ms + lockout_ms;
// Opportunistic GC: when the table grows past ~256 entries (way
// more than realistic callout-types × nodes), purge expired keys.
if (g_callout_until_ms.size() > 256)
{
for (auto eit = g_callout_until_ms.begin(); eit != g_callout_until_ms.end(); )
{
if (eit->second <= now_ms) eit = g_callout_until_ms.erase(eit);
else ++eit;
}
}
return true;
}
void BattlegroundScriptMgr::Register(std::unique_ptr<BattlegroundScript> script)
{
if (!script) return;
scripts_.emplace(script->bg_type_id(), std::move(script));
}
// Modern WoW exposes the same BG map under many BattlemasterList IDs:
// Domination / Comp Stomp / Brawl / CTF variants all reuse the original
// map but bind a different DBC entry. Without aliasing, GetScriptFor
// returns nullptr for the variant id and bots get no role/node advice
// — they stand in the start area doing nothing. Map each variant back
// to the base BG we already wrote a script for. IDs sourced from
// `BATTLEGROUND_*` constants in SharedDefines.h.
//
// Only listing variants that map cleanly to a base BG present in our
// 14 scripts (AV=1, WS=2, AB=3, EY=7, SA=9, IC=30, TP=108, BFG=120,
// TK=699, SM=708, DG=754, SS=894, EB_A=1020, plus catch-all 1018-style
// modern variants). Unmapped variants (Arenas / Epic BG modes / brand-
// new BGs) keep returning nullptr and the bots fall back to generic
// arena formation / no-advice behavior as before.
static uint16_t AliasToBaseBg(uint16_t variant_id)
{
switch (variant_id)
{
// Warsong Gulch family
case 1014: // BATTLEGROUND_WG_CTF
case 861: // BATTLEGROUND_BRAWL_WS
case 886: // BATTLEGROUND_BRAWL_WG
return 2; // BATTLEGROUND_WS
// Arathi Basin family
case 1018: // BATTLEGROUND_DOM_AB
case 1019: // BATTLEGROUND_AB_CS
case 847: // BATTLEGROUND_BRAWL_ABW
case 880: // BATTLEGROUND_BRAWL_AB
case 1022: // BATTLEGROUND_BRAWL_AB2
return 3; // BATTLEGROUND_AB
// Eye of the Storm family
case 859: // BATTLEGROUND_BRAWL_GL (Gravity Lapse — low-grav EotS variant)
case 862: // BATTLEGROUND_BRAWL_EH (Eye of the Horn — Outland EotS reskin)
case 882: // BATTLEGROUND_BRAWL_ES
return 7; // BATTLEGROUND_EY
// Battle for Gilneas family
case 846: // BATTLEGROUND_BRAWL_TBG (old)
case 885: // BATTLEGROUND_BRAWL_TBG2
return 120; // BATTLEGROUND_BFG
// Temple of Kotmogu family
case 858: // BATTLEGROUND_BRAWL_TH
case 884: // BATTLEGROUND_BRAWL_TK
return 699; // BATTLEGROUND_TK
// Silvershard Mines family
case 883: // BATTLEGROUND_BRAWL_SM
return 708; // BATTLEGROUND_SM
// Deepwind Gorge (754) + Ashran (1020/1021) aliases REMOVED (BG audit
// dead-code cleanup): their base scripts are no longer registered (no
// battleground_template row, never queued, never dispatched). An
// unmapped id simply falls through to GetScriptFor → no-op, same as
// before. Re-add with the registration if they become real BGs.
// Seething Shore family
case 890: // BATTLEGROUND_DOM_SS (Seething Strand variant)
return 894; // BATTLEGROUND_SS
// Alterac Valley family — Korrak's Revenge is AV-classic with extra
// questables (Black Lotus, Korrak world boss). Map + node layout
// is the live AV map; AV advice serves it correctly.
case 1033: // BATTLEGROUND_KR (Korrak's Revenge)
return 1; // BATTLEGROUND_AV
// Warfront Arathi (PvP epic mode) — same map as AB plus extra
// workshops/mercenaries. Treat as AB until a dedicated script
// models the vehicle/mercenary mechanics.
case 1036: // BATTLEGROUND_EPIC_BG_WF
return 3; // BATTLEGROUND_AB
default:
return 0; // no alias
}
}
BattlegroundScript const* BattlegroundScriptMgr::TryGetScriptFor(uint16_t bg_type_id) const
{
if (auto it = scripts_.find(bg_type_id); it != scripts_.end())
return it->second.get();
if (uint16_t base = AliasToBaseBg(bg_type_id); base != 0)
if (auto it = scripts_.find(base); it != scripts_.end())
return it->second.get();
return nullptr;
}
BattlegroundScript const* BattlegroundScriptMgr::GetScriptFor(uint16_t bg_type_id) const
{
if (BattlegroundScript const* script = TryGetScriptFor(bg_type_id))
return script;
// Surface unmapped variants once per process — if a future client patch
// introduces a new BG ID we don't handle, bots will fall back to no-advice
// (idle in start area). The warning makes that visible at the WARN level
// so a /reload-config or grep over Server.log pinpoints which alias entry
// to add.
static std::shared_mutex warned_mtx;
static std::unordered_set<uint16_t> warned;
{
std::shared_lock<std::shared_mutex> lk(warned_mtx);
if (warned.contains(bg_type_id)) return nullptr;
}
{
std::unique_lock<std::shared_mutex> lk(warned_mtx);
if (warned.insert(bg_type_id).second)
TC_LOG_WARN("playerbot.v2",
"[BgScriptMgr] no script registered for bg_type_id={}; bots will "
"have no role/node advice. Add to AliasToBaseBg() if this is a "
"variant of an existing BG.", uint32(bg_type_id));
}
return nullptr;
}
BattlegroundAdvice BattlegroundScriptMgr::GetAdvice(BotSnapshotView const& s) const
{
BattlegroundScript const* script = GetScriptFor(s.raw().bg.current_type_id);
if (!script) return {};
return script->get_advice(s);
}
} // namespace Playerbot
@@ -0,0 +1,322 @@
// BattlegroundScript — per-battleground override hooks for the
// autonomous BG-run system. Mirrors the DungeonScript pattern;
// each registered script is keyed by `bg_type_id` (BattlemasterList.dbc).
//
// Generic BG logic (fight nearest enemy, heal lowest-HP teammate)
// works for combat positioning but doesn't know objectives. Scripts
// fill in: which objective to push, who carries the flag, when to
// chase enemy carrier, role assignments per bot index.
#pragma once
#include <cstdint>
#include <memory>
#include <unordered_map>
#include <vector>
namespace Playerbot {
class BotSnapshotView;
// Role assigned to a bot for the duration of the BG. Determined by
// script + bot's class/spec/index. Drives objective-aware actions.
enum class BgRole : uint8_t
{
Free = 0, // No role — fall back to generic combat.
FlagCarrier= 1, // Pick up + carry the flag (CTF).
FCEscort = 2, // Stay with FC; intercept enemies.
Defender = 3, // Stay at home objective.
Attacker = 4, // Push enemy objective.
Roamer = 5, // Mid-map roving (interrupt enemy moves).
Healer = 6, // Healer-spec — focus FC if applicable.
// OrbCarrier — Kotmogu orb mechanic. Like FlagCarrier, picks up an
// enemy_flag-tagged GO; UNLIKE FlagCarrier, does NOT return home to
// cap. After pickup, holds at home_base (map center) to accumulate
// the SmallAura distance-from-center score multiplier. Multiple
// OrbCarrier slots are expected (ToK has up to 4 carriers per side).
OrbCarrier = 7,
};
struct BattlegroundAdvice
{
// Per-bot role assignment indexed by formation_slot.
// Empty = no role; bot uses generic logic.
std::vector<BgRole> role_by_slot;
// Should the bot chase the enemy flag carrier (CTF only)?
// Honored only when bg_enemy_flag_carrier is non-empty.
bool chase_enemy_carrier = false;
// Should the bot escort the friendly flag carrier?
bool escort_friendly_carrier = false;
// CTF-specific: the bot's own-flag pickup position (where the
// friendly faction flag spawns) and the enemy flag pickup position
// (where to go grab the cap target). {0,0,0} sentinel = no advice.
// Populated by WSG/TP/BfG scripts. Faction selection (which one is
// "friendly" vs "enemy") is the script's responsibility — it reads
// the snapshot's faction context inside get_advice.
float own_flag_x = 0.f, own_flag_y = 0.f, own_flag_z = 0.f;
float enemy_flag_x = 0.f, enemy_flag_y = 0.f, enemy_flag_z = 0.f;
// Default home-base hold position for Defender role. Same {0,0,0}
// sentinel meaning. Set by node-race scripts (AB, BfG, AV, EotS).
float home_base_x = 0.f, home_base_y = 0.f, home_base_z = 0.f;
// Fixed defender posts around home_base (WSG: two beside the flag stand). When set, defenders hold a post (chosen by team rank)
// instead of a hashed spot at 9..14 y.
struct DefendPost { float x, y, z; };
std::vector<DefendPost> defend_posts;
// CTF: where a flag carrier waits while its own flag is held by the enemy (it cannot capture until the flag is back), out of sight
// of the stand. Empty = the carrier waits at the pedestal as before.
std::vector<DefendPost> carrier_hide_spots;
// Score lead/deficit (my_score - enemy_score) at which the tactical
// bias flips to Turtle (>= +threshold) / AllIn (<= -threshold).
// Units are whatever the BG's score worldstates count: resource
// points for AB/BfG/EotS/Kotmogu (max 1500-2000 -- default 200 is a
// "noticeable lead"), but FLAG CAPS for WSG/TP (max 3) where 200
// could never trigger (BG audit N55/N65) -- CTF scripts set 2.
int32_t score_bias_threshold = 200;
// Endgame target — used by Attacker / Roamer roles when match is
// in "all-in" tactical state (score-bias = AllIn or BG-specific
// late-phase trigger). For AV it points at the enemy keep / boss;
// for IoC the enemy fortress door. {0,0,0} = no endgame override
// (Attackers continue with normal node-push logic).
float endgame_target_x = 0.f, endgame_target_y = 0.f, endgame_target_z = 0.f;
// Optional open-field fight zone (AV: the valley between the two armies). A
// share of the team's free attackers is sent here to brawl for honour/kills
// like old Classic AV instead of all racing the bases (BgTeamCoordinator::
// PlanNodeRace). {0,0,0} = none (every other BG).
float fight_zone_x = 0.f, fight_zone_y = 0.f, fight_zone_z = 0.f;
// AV: where the squad for the enemy captain gathers before it goes in ({0,0,0} = none). The captain is engaged once enough of
// the team stands there (BgTeamCoordinator::PlanNodeRace), not as a trickle of single bots.
float captain_stage_x = 0.f, captain_stage_y = 0.f, captain_stage_z = 0.f;
// AV: when true the enemy GENERAL is only pushed once no enemy tower / bunker (priority-2 node) is standing; the general keeps
// the tower buffs until then. Captains are not gated.
bool endgame_needs_towers = false;
// Creatures to be killed for an objective that is not a node (AV mine bosses: kill the boss of a mine the team does not own to
// take it). The script lists only the ones worth sending a squad for; the coordinator sends a few bots per entry.
struct KillTarget { float x = 0.f, y = 0.f, z = 0.f; uint32_t entry = 0; char const* name = ""; };
std::vector<KillTarget> kill_targets;
// When true, the Attacker endgame redirect to endgame_target fires
// UNCONDITIONALLY (not only under the Bias_AllIn score state). Used by
// round-based objective BGs whose score worldstates stay 0/0 all match
// so the score-derived bias never leaves Normal (SoTA: AddPoint is never
// called, so attackers were never driven to the breach / relic and the
// match could not end — BG audit SoTA blocker). Default false keeps the
// score-gated behavior for point-race BGs (AV/IoC).
bool endgame_unconditional = false;
// Optional NPC entry of the boss/general whose kill ends the match
// (AV Drek'thar/Vandar, IoC Halford/Agmar, Ashran Volrath/Tremblade).
// When set AND a NearbyUnit with this entry is visible to the bot,
// the Attacker endgame rule chases the live unit position instead of
// the static endgame_target coord. Handles bosses that walk around /
// path into adjacent rooms; the static coord is the fallback used
// until the bot is close enough to acquire the unit.
uint32_t endgame_creature_entry = 0;
// CTF enemy-flag-carrier chase gate. When true AND chase_enemy_carrier
// is true, only melee classes (Warrior, Rogue, DK, Monk, Feral Druid,
// Ret Pala, Enh Sham, DH, Hunter) chase — clothie casters stay on
// their objective. Without this, mages/priests sprint into a moving
// FC at 1v1 range and feed honor across the map. Default false keeps
// pre-existing chase behavior (everyone chases).
bool chase_melee_only = false;
// Preferred classes for the FlagCarrier role. When non-empty, the
// BG dispatcher applies a deterministic, per-bot role override:
// * Bots whose class IS in this list get my_role = FlagCarrier
// regardless of their hashed slot (so stealth classes always
// take the FC job in WSG/TP).
// * Bots whose class is NOT in this list AND whose hashed slot
// WOULD have given them FlagCarrier get demoted to Roamer
// (so the FC role is never wasted on a clothie that can't
// survive the kite). The acts_as_fc dynamic-handoff path
// handles the case where no preferred-class bot is present.
// Class ids match SharedDefines::CLASSMASK_* (Warrior=1 ... Evoker=13).
// Empty = no override (default behavior — slot 0 is whichever class
// happens to hash there).
std::vector<uint8_t> fc_class_preference;
// Per-node positions for node-race BGs (AB/BfG/EotS/Gorge/IoC/AV).
// When non-empty, takes precedence over `home_base_*` for Defender
// role: each Defender slot is assigned a node (round-robin over
// node count) and moves to that node's coords. Attackers and
// Roamers iterate through these positions to push undefended /
// contested nodes.
//
// `priority`: 0 = default; >0 = high-value target. The Attacker rule
// applies it as a tie-breaker when two nodes have the same
// ownership-priority bucket (neutral / contested / enemy-held).
// Used by AV to bias toward towers/bunkers (which drain more
// reinforcements per cap than graveyards). 0 for all script's
// current nodes leaves behavior unchanged.
struct Node {
float x = 0.f, y = 0.f, z = 0.f;
char const* name = "";
uint8_t priority = 0;
// When non-zero, consumer should resolve the node's LIVE position
// by scanning nearby_friends + nearby_enemies for the closest Unit
// with this creature entry and using its m_position. Falls back
// to the static x/y/z when no live unit visible. Used for moving
// objectives (Silvershard cart entry 60140) — the static coord is
// the cart's spawn point but the cart moves on rails over 30s+.
uint32_t follow_creature_entry = 0;
};
std::vector<Node> nodes;
// Auto-use any GO of these types when within ~5 yards. Lets the
// bot hit AB/EotS/BfG flagstands and AV banners on contact without
// per-script coords. Empty = generic logic only. Common values:
// * GAMEOBJECT_TYPE_FLAGSTAND (24) — capturable nodes.
// * GAMEOBJECT_TYPE_FLAGDROP (26) — dropped flags (return).
std::vector<uint32_t> auto_use_go_types;
// Auto-use any GO with one of these ENTRIES when within ~5 yards
// (audit B26): AV / IoC / SotA banners are GO type 1 (BUTTON) and
// type 10 (GOOBER) — blanket-auto-using those TYPES is unsafe (doors,
// levers, quest props share them), so these maps enumerate the exact
// DB-verified banner / relic entries instead. Without this, bots on
// the epic BGs could never assault/defend a node or cap the SotA
// Titan Relic (the literal win condition). Empty = type matching only.
std::vector<uint32_t> auto_use_go_entries;
// Creature entries the bot should mount when within range (8y).
// Lets SoTA bots hop into demolishers, IoC bots into siege engines /
// glaives / catapults. The bot picks the closest matching nearby
// friendly Creature with an empty driver seat. Empty = no auto-mount.
std::vector<uint32_t> vehicle_creature_entries;
// Default spell ID the bot fires from its current vehicle seat once
// mounted and an enemy is in range/LoS. Typically the seat 0 driver
// ability (boulder hurl, glaive throw etc). 0 = no automatic seat
// fire — the bot mounts but waits for owner direction. Used as
// fallback when no entry-specific override is registered.
uint32_t vehicle_seat_spell = 0;
// Per-vehicle-entry spell override. Looked up by the bot's current
// vehicle creature entry; falls back to vehicle_seat_spell on miss.
// Used by IoC where Demolisher / Siege Engine / Glaive Thrower /
// Catapult / Keep Cannon each fire a different primary ability.
std::unordered_map<uint32_t, uint32_t> vehicle_seat_spell_by_entry;
// DESTRUCTIBLE_BUILDING GameObject entries a SIEGE VEHICLE should fire
// its seat spell AT (cast_vehicle_at the gate's live position). These are
// the ENEMY gates the bot's team must breach — IoC enemy keep gates,
// SoTA defense-line gates on the attacker round. When non-empty and the
// bot is in a vehicle with a seat spell, the bg_vehicle_fire_gate rule
// targets the closest standing (is_destroyed==false) matching gate before
// it looks for unit targets. Empty = no gate-fire (unit fire only).
// Without this, the seat-fire rule only saw Units (nearby_enemies) and
// never the gate GOs, so gates never fell and the General was never
// reached (BG audit IoC / SoTA siege blockers).
std::vector<uint32_t> siege_target_go_entries;
// Arena tactical positions — pillars / cubbies for LoS breaks +
// hazard zones to avoid. Distinct from `nodes[]` (which feeds the
// Attacker/Defender objective-push pipeline) — arena pillars/hazards
// ONLY drive the `idle:arena_position` rule. Empty for all non-arena
// BGs (no behavioural change there).
struct ArenaPillar {
float x = 0.f, y = 0.f, z = 0.f;
char const* name = "";
// 0 = LoS pillar (ranged hides behind, healer LoS-breaks melee)
// 1 = cubby (corner cover, also a fallback when in hazard)
// 2 = high-ground (perch — preferred starting position for ranged)
uint8_t kind = 0;
};
std::vector<ArenaPillar> arena_pillars;
struct ArenaHazard {
float x = 0.f, y = 0.f, z = 0.f;
float radius = 5.f;
char const* name = "";
// Time-gated activation (ms since match start). 0 = always
// active. Ring of Valor pillar elevators: active_after_ms=60000.
uint32_t active_after_ms = 0;
uint32_t active_until_ms = 0; // 0 = forever
};
std::vector<ArenaHazard> arena_hazards;
// Where to advance when the starting gate drops. {0,0,0} sentinel =
// don't override (default arena-center movement applies).
float opening_rally_x = 0.f, opening_rally_y = 0.f, opening_rally_z = 0.f;
};
class BattlegroundScript
{
public:
virtual ~BattlegroundScript() = default;
virtual uint16_t bg_type_id() const = 0;
virtual char const* name() const = 0;
// Per-tick advice. Snapshot view is read-only.
virtual BattlegroundAdvice get_advice(BotSnapshotView const& s) const = 0;
};
class BattlegroundScriptMgr
{
public:
BattlegroundScriptMgr() = default;
void Register(std::unique_ptr<BattlegroundScript> script);
BattlegroundScript const* GetScriptFor(uint16_t bg_type_id) const;
BattlegroundAdvice GetAdvice(BotSnapshotView const& s) const;
size_t size() const { return scripts_.size(); }
// Iterate every registered base script (variants registered via
// AliasToBaseBg are not in the map). Used by the static
// `.playerbot smoketest bg` validator that walks the registry
// to verify each script's coords / GO types / vehicle entries
// resolve through ObjectMgr + a sane data range.
template <class Fn>
void for_each_script(Fn fn) const
{
for (auto const& [key, script] : scripts_)
if (script) fn(*script);
}
// Resolve a bg_type_id to its base script WITHOUT emitting the
// "no script registered" WARN. Used by alias-coverage assertions
// that intentionally probe IDs which may legitimately have no
// base (queue meta-IDs like RB/RATED/RANDOM).
BattlegroundScript const* TryGetScriptFor(uint16_t bg_type_id) const;
private:
std::unordered_map<uint16_t, std::unique_ptr<BattlegroundScript>> scripts_;
};
// Cross-bot callout coordinator. When 40 AV bots all simultaneously
// detect "FC down", a per-bot 20s lockout doesn't dedup the chat — 30
// "FC down" lines hit raid-chat in the same tick. This shared registry
// lets the FIRST bot per (callout_kind, key) claim the slot for a
// configurable window; everyone else suppresses their emit. The key
// space is callouts identified by a stable 64-bit packed value (kind
// in high bits, target/node identifier in low bits) so two distinct
// nodes can each have an active callout but the same node can't be
// re-shouted by 40 bots.
//
// Threading: callout claims happen on the AI worker thread (one bot
// per worker per tick); the registry uses a shared_mutex for read-
// dominant lookups + an upgrade write when claiming/expiring entries.
//
// Cardinality: bounded by callout-types × distinct keys (~6 × ~16
// nodes-per-BG) = O(100) entries; trivial cost.
class BgCalloutCoordinator
{
public:
// Returns true if THIS bot wins the claim for (kind, key) with the
// given lockout window. False = another bot already shouted within
// the window; suppress this emit.
static bool TryClaim(uint32_t kind, uint64_t key, uint32_t now_ms,
uint32_t lockout_ms);
};
} // namespace Playerbot
@@ -0,0 +1,192 @@
// Alterac Valley objective rules imported from ike3's bots (the ike3-based playerbot code,
// BattleGroundTacticsAV.cpp): the mine-boss objective and the captain gathering threshold. Pure functions, no game state, so they can be
// tested offline (tests/game/BgAvPlan.cpp). The mid-field fighting tactics are ours and do not live here.
#pragma once
#include <cstdint>
#include <vector>
namespace Playerbot::BgAvPlan
{
// The captain squad goes in once this many of the team stand at the waiting spot (ike3: attackers near the waiting spot >= 5).
constexpr int kCaptainGatherCount = 5;
// Time cap (Karrz, AV 2026-10-11: a pile of bots waited at the Stonehearth staging spot for a quorum): after kCaptainGatherMaxMs of waiting the squad
// goes with whoever is there (at least one), so bots arriving one at a time never park for good.
constexpr uint32_t kCaptainGatherMaxMs = 75000;
constexpr bool CaptainGather(int at_stage, bool latched, uint32_t waited_ms = 0)
{
return latched || at_stage >= kCaptainGatherCount || (at_stage >= 1 && waited_ms >= kCaptainGatherMaxMs);
}
struct MineTarget { float x, y, z; uint32_t entry; char const* name; };
// Mine owner world states (801 Irondeep = north, 804 Coldtooth = south): 0 neutral, 1 Alliance, 2 Horde, 255 unread.
// `team` is 1 = Alliance, 2 = Horde. Killing the boss of a mine the team does not own takes it: a neutral mine is held by its trogg /
// kobold boss (Morloch / Taskmaster Snivvle), an enemy-held one by that team's boss (Alliance Umi Thorson / Agi Rumblestomp, Horde
// Keetar / Masha Swiftcut). Positions are world.creature spawns; both sides' bosses of a mine spawn at the same spot.
inline std::vector<MineTarget> MineTargets(uint8_t team, uint8_t north, uint8_t south)
{
std::vector<MineTarget> out;
if (team != 1 && team != 2) return out;
if (north != 255 && north != team && north <= 2)
out.push_back({ 863.838f, -445.468f, 50.846f, north == 0 ? 11657u : (team == 1 ? 13079u : 13078u), "Irondeep Mine boss" });
if (south != 255 && south != team && south <= 2)
out.push_back({ -848.902f, -92.931f, 68.633f, south == 0 ? 11677u : (team == 1 ? 13088u : 13086u), "Coldtooth Mine boss" });
return out;
}
// ---- AV quests (ike3 BattleGroundTacticsAV.cpp: the AV quester role; quest data from the VMaNGOS import, NPC spawns from
// world.creature) ----
// A small share of the team (IsQuester) works the Armor Scraps quest and the two mine-supply quests instead of walking the front the
// whole match. Turn in what is complete, accept what can be done, fetch mine supplies from a mine the team owns. Armor scraps drop
// from kills (the quest collects them while the bot fights); riders, wing commanders, beacons and the world-boss turn-in are not
// here.
constexpr uint32_t kScrapsItem = 17422, kIrondeepSupplies = 17522, kColdtoothSupplies = 17542;
constexpr uint32_t kSuppliesNeeded = 10;
constexpr uint32_t kMineGoNorth = 178785, kMineGoSouth = 178784;
// One bot in eight is a quester (ike3: guid % 5 for the 51-59 bracket).
constexpr bool IsQuester(uint64_t guid_low) { return guid_low % 8u == 0; }
struct AvPlace { uint32_t entry; float x, y, z; };
struct TeamQuests
{
uint32_t scraps_first, scraps_repeat, mine_north, mine_south; // quest ids
AvPlace armorer, quartermaster; // quest NPCs (give and take every quest above)
AvPlace go_north, go_south; // the mine supply objects (Irondeep N, Coldtooth S)
};
// Alliance: scraps 7223 then 6781 (Murgot Deepforge), Irondeep 5892 / Coldtooth 6982 (Stormpike Quartermaster). Horde: scraps 7224
// then 6741 (Smith Regzar), Coldtooth 5893 / Irondeep 6985 (Frostwolf Quartermaster).
inline TeamQuests const& QuestsFor(uint8_t team)
{
static TeamQuests const alliance = { 7223, 6781, 5892, 6982, { 13257, 647.61f, -61.1548f, 41.7405f }, { 12096, 587.633f, -45.9816f, 37.5438f },
{ kMineGoNorth, 881.273f, -442.002f, 54.664f }, { kMineGoSouth, -853.671f, -91.427f, 68.569f } };
static TeamQuests const horde = { 7224, 6741, 6985, 5893, { 13176, -1251.5f, -316.327f, 62.6565f }, { 12097, -1293.79f, -194.407f, 72.4398f },
{ kMineGoNorth, 881.273f, -442.002f, 54.664f }, { kMineGoSouth, -853.671f, -91.427f, 68.569f } };
return team == 2 ? horde : alliance;
}
// Every quest id the planner looks at, for the snapshot's rewarded mask (bit i = kQuestIds[i] was handed in once).
constexpr uint32_t kQuestIds[8] = { 7223, 6781, 5892, 6982, 7224, 6741, 5893, 6985 };
constexpr uint32_t QuestBit(uint32_t quest_id)
{
for (uint32_t i = 0; i < 8; ++i) if (kQuestIds[i] == quest_id) return 1u << i;
return 0;
}
enum class AvQStatus : uint8_t { None, Incomplete, Complete, Rewarded };
struct QuestInput
{
uint8_t team = 1; // 1 Alliance, 2 Horde
uint8_t mine_owner_north = 255, mine_owner_south = 255;
AvQStatus scraps_first = AvQStatus::None, scraps_repeat = AvQStatus::None, mine_north = AvQStatus::None, mine_south = AvQStatus::None;
uint32_t supplies_north = 0, supplies_south = 0; // Irondeep / Coldtooth supply items in the bags
};
enum class StepKind : uint8_t { None, TurnIn, Accept, UseMineGo };
struct AvStep { StepKind kind = StepKind::None; uint32_t quest_id = 0; AvPlace place{0, 0, 0, 0}; };
// The next thing the quester does; None = back to the fight. Mine quests are only taken and worked while the team owns that mine
// (a mine the enemy holds gives no supplies); the scraps quest is kept running all match (first quest once, then the repeat one).
inline AvStep NextStep(QuestInput const& in)
{
TeamQuests const& q = QuestsFor(in.team);
// turn in
if (in.scraps_first == AvQStatus::Complete) return { StepKind::TurnIn, q.scraps_first, q.armorer };
if (in.scraps_repeat == AvQStatus::Complete) return { StepKind::TurnIn, q.scraps_repeat, q.armorer };
if (in.mine_north == AvQStatus::Complete) return { StepKind::TurnIn, q.mine_north, q.quartermaster };
if (in.mine_south == AvQStatus::Complete) return { StepKind::TurnIn, q.mine_south, q.quartermaster };
// accept
if (in.scraps_first == AvQStatus::None)
return { StepKind::Accept, q.scraps_first, q.armorer };
if (in.scraps_first == AvQStatus::Rewarded && in.scraps_repeat == AvQStatus::None)
return { StepKind::Accept, q.scraps_repeat, q.armorer };
bool const own_n = in.mine_owner_north == in.team, own_s = in.mine_owner_south == in.team;
if (own_n && in.mine_north == AvQStatus::None) return { StepKind::Accept, q.mine_north, q.quartermaster };
if (own_s && in.mine_south == AvQStatus::None) return { StepKind::Accept, q.mine_south, q.quartermaster };
// fetch supplies: the quest is open, the bags are short, the mine is ours
if (own_n && in.mine_north == AvQStatus::Incomplete && in.supplies_north < kSuppliesNeeded)
return { StepKind::UseMineGo, q.mine_north, q.go_north };
if (own_s && in.mine_south == AvQStatus::Incomplete && in.supplies_south < kSuppliesNeeded)
return { StepKind::UseMineGo, q.mine_south, q.go_south };
return {};
}
// ---- Attack order (ike3 BattleGroundTacticsAV.cpp attack lists; mod-playerbots AV_AttackObjectives_*: "first N non-owned, non-destroyed
// entries", N = 2 balanced) ----
// Both reference bots walk an ordered list of the enemy's nodes, graveyards INCLUDED: a graveyard held by the enemy sends every dead
// bot of the team back to the far end of the valley, so taking it early matters as much as a tower. We had only towers and bunkers.
struct AvListNode { float x, y; char const* name; };
// Horde: Stonehearth GY, Stonehearth Bunker, Icewing Bunker, Stormpike GY, Dun Baldar South, Dun Baldar North, Stormpike Aid Station.
inline std::vector<AvListNode> const& AttackList(uint8_t team)
{
static std::vector<AvListNode> const horde = {
{ 73.7f, -426.0f, "Stonehearth GY" }, { -154.0f, -446.0f, "Stonehearth Bunker" }, { 203.0f, -361.0f, "Icewing Bunker" },
{ 669.0f, -294.0f, "Stormpike GY" }, { 556.0f, -84.0f, "Dun Baldar South Bunker" }, { 678.0f, -139.0f, "Dun Baldar North Bunker" },
{ 638.5f, -31.5f, "Stormpike Aid Station" } };
// Alliance: Iceblood GY, Iceblood Tower, Tower Point, Frostwolf GY, East / West Frostwolf Tower, Frostwolf Relief Hut.
static std::vector<AvListNode> const alliance = {
{ -612.5f, -397.0f, "Iceblood GY" }, { -572.0f, -263.0f, "Iceblood Tower" }, { -768.0f, -363.0f, "Tower Point" },
{ -1082.5f, -347.0f, "Frostwolf GY" }, { -1303.0f, -317.0f, "East Frostwolf Tower" }, { -1298.0f, -267.0f, "West Frostwolf Tower" },
{ -1402.0f, -307.0f, "Frostwolf Relief Hut" } };
return team == 2 ? horde : alliance;
}
struct AvNodeView { float x, y; bool ours; bool destroyed; bool enemy_flipping; };
// Indices into `nodes` of the first `window` list entries that are still worth attacking: present, not razed, not ours, and not
// being flipped by the enemy (the defence pass owns those). Matches a list entry to a live node by position (30 yd).
inline std::vector<int> PickAttackNodes(uint8_t team, std::vector<AvNodeView> const& nodes, int window)
{
std::vector<int> out;
for (AvListNode const& e : AttackList(team))
{
if (int(out.size()) >= window) break;
for (int i = 0; i < int(nodes.size()); ++i)
{
float const dx = nodes[i].x - e.x, dy = nodes[i].y - e.y;
if (dx * dx + dy * dy > 30.0f * 30.0f) continue;
if (nodes[i].destroyed || nodes[i].ours || nodes[i].enemy_flipping) break;
out.push_back(i);
break;
}
}
return out;
}
// Snowfall Graveyard (the neutral one in the middle of the valley, -202.5,-113): ike3 sends its "supporters" there while it is not
// ours, 40 % of the team in the first ten minutes ("strife") and 20 % afterwards; mod-playerbots sends roles under 6 (Alliance) / 5
// (Horde) of 10. Returns how many of `free_bots` go.
constexpr float kSnowfallX = -202.5f, kSnowfallY = -113.0f;
inline int SnowfallDetail(int free_bots, uint32_t in_progress_ms)
{
if (free_bots < 3) return 0;
int const share = in_progress_ms < 10u * 60u * 1000u ? 40 : 20;
int const n = (free_bots * share) / 100;
return n < 1 ? 1 : n;
}
// ---- Rules from ike3 / mod-playerbots AV that the planner uses (the ike3-based playerbot code raid10-revamp BattleGroundTacticsAV.cpp, mod-playerbots
// BattleGroundTactics.cpp selectObjective) ----
// A defender already deep in the enemy half becomes an attacker: x >= -62 for the Horde, x <= -462 for the Alliance (AV runs from the
// Frostwolf end at x -1400 to Dun Baldar at x +700); with chance 20 + 15 per own node razed (mod-playerbots BGT 1919-1931).
constexpr bool DefenderPastLine(uint8_t team, float x) { return team == 2 ? x >= -62.0f : x <= -462.0f; }
constexpr int DefenderFlipChance(int own_razed) { return 20 + 15 * own_razed; }
// The general (Drek'Thar / Vanndar). ike3: only once every enemy tower and bunker is down. mod-playerbots: two or more down, and either
// the team holds its last graveyard (Frostwolf Relief Hut / Stormpike Aid Station) or 20 or more of its players stand within 200 yd of
// the boss. Either one opens the push.
constexpr int kBossFriendsNeeded = 20;
constexpr bool GeneralPushOk(int enemy_towers_up, int enemy_towers_razed, bool own_final_gy, int friends_near_boss)
{
return enemy_towers_up == 0 || (enemy_towers_razed >= 2 && (own_final_gy || friends_near_boss >= kBossFriendsNeeded));
}
// Our last graveyard (the one an AV team keeps until the end).
struct AvPoint { float x, y, z; };
constexpr AvPoint FinalGraveyard(uint8_t team) { return team == 2 ? AvPoint{ -1402.0f, -307.0f, 89.0f } : AvPoint{ 638.5f, -31.5f, 46.0f }; }
// Nothing left to attack: wait next to the enemy general (mod-playerbots AV_BOSS_WAIT_H / AV_BOSS_WAIT_A).
constexpr AvPoint BossWait(uint8_t team) { return team == 2 ? AvPoint{ 689.21f, -20.173f, 50.62f } : AvPoint{ -1361.773f, -248.977f, 99.369f }; }
// How far an AV bot looks for a fight (ike3 EnemyPlayerValue::GetMaxAttackDistance): 40 yd during the first 20 minutes, 10 yd after, so
// late in the match the bots keep running to the objective instead of chasing every enemy in sight.
constexpr float AggroRange(uint32_t in_progress_ms) { return in_progress_ms < 20u * 60u * 1000u ? 40.0f : 10.0f; }
}
@@ -0,0 +1,116 @@
// Battleground tactics rules as pure functions (no Player / Battleground), so tests/game/BgTactics.cpp can run them.
//
// Ideas ported from the two reference bot families, rewritten for our team planner (credit: ike3 playerbots for the
// capture-skip / role split ideas, liyunfan1223/mod-playerbots BattleGroundTactics.cpp for the capture abort, the 60 s
// objective reset and the camp-the-enemy-graveyard rule). Values are vanilla 1.12 behaviour (AB capture 60 s, AV tower 5 min).
// Written for Karrz (Karrz).
#pragma once
#include <cmath>
#include <cstdint>
namespace Playerbot::BgTactics
{
// A bot that is channeling a banner capture stops and fights when an enemy player is this close to the banner (mod-playerbots:
// 11 yd). Past that range it keeps clicking: an enemy at the other end of the node cannot undo the channel.
constexpr float kCaptureAbortEnemyRange = 11.0f;
enum class CaptureAbort : uint8_t
{
None, // keep capturing
EnemyNear, // an enemy player is within kCaptureAbortEnemyRange of the banner: turn and fight
BannerGone, // the banner is no longer capturable (someone else finished it): re-roll the objective
};
inline CaptureAbort ShouldAbortCapture(bool banner_capturable, bool have_enemy, float nearest_enemy_dist_to_banner)
{
if (!banner_capturable)
return CaptureAbort::BannerGone;
if (have_enemy && nearest_enemy_dist_to_banner <= kCaptureAbortEnemyRange)
return CaptureAbort::EnemyNear;
return CaptureAbort::None;
}
// How long an assault on a node takes before it flips (vanilla): AB/EotS/Deephaul 60 s, AV towers and graveyards 5 min.
// type ids: 1 = AV, 2 = WSG, 3 = AB.
inline uint32_t CaptureWindowMs(uint16_t bg_type_id)
{
return bg_type_id == 1 ? 300000u : 60000u;
}
// Fastest a bot covers ground in a battleground (mounted, straight line): a defender that cannot arrive before the flip even at
// this speed is not sent (it would run to a node that is already lost; the next plan sends the attack squad to retake it).
constexpr float kBgFastSpeed = 14.0f; // yd/s
inline bool CanArriveBeforeFlip(float dist, uint32_t window_ms, uint32_t contested_for_ms)
{
uint32_t const left = contested_for_ms >= window_ms ? 0u : window_ms - contested_for_ms;
return dist <= kBgFastSpeed * (float(left) / 1000.0f);
}
// Escorts for the lone pickup runner on a CTF map. The soak (WSG 2026-10-11) lost ~9 of 12 bots on the way to the enemy flag with a
// single escort; the carrier gets 3. Two once the team can spare them.
inline int RunnerEscortCount(int team_size)
{
return team_size >= 8 ? 2 : 1;
}
// Stand-still watchdog (mod-playerbots resets a bot's objective every 60 s in WSG/AV): a bot that has not moved kStallRadius in
// kStallMs while idle (not in combat, not casting, not holding an ordered post) is stalled and should re-pick its objective.
constexpr uint32_t kStallMs = 60000;
constexpr float kStallRadius = 3.0f;
struct StallWatch
{
float x = 0.f, y = 0.f;
uint32_t since_ms = 0;
bool init = false;
// `busy` = in combat, casting, mounted-travelling on an order, dead, or waiting at the gate: resets the timer.
bool Update(uint32_t now_ms, float nx, float ny, bool busy)
{
float const dx = nx - x, dy = ny - y;
if (!init || busy || dx * dx + dy * dy > kStallRadius * kStallRadius)
{
x = nx; y = ny; since_ms = now_ms; init = true;
return false;
}
if (now_ms - since_ms >= kStallMs)
{
since_ms = now_ms; // fire once per window
return true;
}
return false;
}
};
// AB: a team that owns every node and is not capping anything camps the enemy graveyard instead of standing on the banners
// (mod-playerbots does this at fixed coordinates).
inline bool CampEnemyGraveyard(int owned_nodes, int total_nodes, int contested_nodes)
{
return total_nodes > 0 && owned_nodes >= total_nodes && contested_nodes == 0;
}
// The lone pickup runner. A flag room is defended; the soak (WSG 2026-10-11, 8428be7c) shows pickup -> die -> drop loops, the same
// runner lifting the flag four times and dying with it each time. The runner may rush the stand past enemies only with company:
// at least kRunnerMinCompany friends within kRunnerCompanyRange. Without them it fights what is near (the escorts catch up, and the
// next plan hands the pickup to whoever is there) instead of running in alone.
constexpr int kRunnerMinCompany = 2;
constexpr float kRunnerCompanyRange = 25.0f;
constexpr float kRunnerEnemyRange = 30.0f;
inline bool RunnerMayRush(int friends_near, int enemies_near)
{
return enemies_near == 0 || friends_near >= kRunnerMinCompany;
}
// An escort follows the runner from the moment the order is given, not only once the flag is lifted: before the pickup there is
// no carrier, and the in-combat return rule (which keeps escorts within 40 yd) used to need one. `focus_dist` < 0 = the focus is
// not among the units around the bot (far away).
constexpr float kEscortLeashYards = 40.0f;
inline bool EscortMustReturn(float focus_dist, bool enemy_close)
{
return !enemy_close && (focus_dist < 0.f || focus_dist > kEscortLeashYards);
}
}
@@ -0,0 +1,81 @@
// BG victim validity: a battleground bot never keeps a target it cannot hurt, and re-picks when an enemy player is close.
//
// Karrz, WSG 2026-10-09: a Horde priest stood next to him swinging at nothing and ignored him. The idle engage rule only ran with an empty
// victim, and the in-combat BG switches only react to a carrier, a peel or a healer, so a victim that was gone, dead, untargetable or
// not fighting back held the bot for good. Pure function over the snapshot's unit lists (templated, so tests/game/BgTargetPick.cpp can
// run it on plain structs). Used by State_Idle and State_InCombat; both log the result as [bg_target].
#pragma once
#include <cstdint>
#include <vector>
namespace Playerbot::BgTargetPick
{
enum class Why : uint8_t
{
None, // keep the victim
Missing, // the victim is not among the units around the bot (gone, out of range, not visible)
Unfightable, // dead, untargetable, pacified, or unreachable
IdleMob, // a creature that does not fight us while an enemy player is close
};
inline char const* WhyName(Why w)
{
switch (w)
{
case Why::Missing: return "missing";
case Why::Unfightable: return "unfightable";
case Why::IdleMob: return "idle_mob";
default: return "keep";
}
}
// How far a battleground bot looks for an enemy to fight (Karrz, WSG 2026-10-09: "make the radius where they attack people bigger").
// The snapshot scans this far in a battleground (BotSnapshotBuilder), the engage and re-pick rules read it.
constexpr float kBgEngageRange = 55.0f;
constexpr float kIdleMobPlayerRange = 15.0f; // an enemy player this close beats a creature that is not attacking us
// `me` is this bot's guid. `enemies` / `attackers` are the snapshot's lists (victim lookup uses both, as victim_info() does).
// Returns the guid to switch to (default-constructed guid when none) and why the victim was dropped.
template <class Unit, class Guid>
Guid Pick(Guid const& me, Guid const& victim, float bx, float by, bool ranged, float range,
std::vector<Unit> const& enemies, std::vector<Unit> const& attackers, Why& why)
{
why = Why::None;
Guid const none{};
if (victim == none)
return none;
Unit const* v = nullptr;
for (Unit const& u : attackers)
if (u.guid == victim) { v = &u; break; }
if (!v)
for (Unit const& u : enemies)
if (u.guid == victim) { v = &u; break; }
auto dist2 = [&](Unit const& u) { float const dx = u.x - bx, dy = u.y - by; return dx * dx + dy * dy; };
auto fightable = [](Unit const& u) { return u.hp > 0 && !u.untargetable && !u.is_pacified && !u.cannot_reach; };
if (!v) why = Why::Missing;
else if (!fightable(*v)) why = Why::Unfightable;
// The nearest live enemy player, in line of sight for ranged bots and not locked down by a friendly CC.
Unit const* best = nullptr;
float best_d = range * range;
for (Unit const& u : enemies)
{
if (!u.is_player || !fightable(u) || u.is_cc_locked || u.guid == victim) continue;
if (ranged && !u.in_los) continue;
float const d = dist2(u);
if (d < best_d) { best_d = d; best = &u; }
}
if (why == Why::None && v && !v->is_player && !(v->victim == me) && best &&
best_d <= kIdleMobPlayerRange * kIdleMobPlayerRange)
why = Why::IdleMob;
if (why == Why::None || !best)
return none;
return best->guid;
}
}
File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More