diff --git a/src/ui/game_screen.cpp b/src/ui/game_screen.cpp index f61d03cd..f66e6749 100644 --- a/src/ui/game_screen.cpp +++ b/src/ui/game_screen.cpp @@ -2068,7 +2068,8 @@ void GameScreen::renderPetFrame(game::GameHandler& gameHandler) { if (slotVal == 0) continue; uint32_t actionId = slotVal & 0x00FFFFFFu; - bool autocastOn = (slotVal & 0xFF000000u) == 0x80000000u; + // Use the authoritative autocast set from SMSG_PET_SPELLS spell list flags. + bool autocastOn = gameHandler.isPetSpellAutocast(actionId); ImGui::PushID(i); if (rendered > 0) ImGui::SameLine(0.0f, spacing); @@ -2117,7 +2118,7 @@ void GameScreen::renderPetFrame(game::GameHandler& gameHandler) { // Tooltip: show spell name or built-in command name. if (ImGui::IsItemHovered()) { const char* tip = builtinLabel - ? (actionId == 5 ? "Attack" : actionId == 4 ? "Follow" : actionId == 2 ? "Follow" : "Stay") + ? (actionId == 5 ? "Attack" : actionId == 2 ? "Follow" : "Stay") : nullptr; std::string spellNm; if (!tip && actionId > 5) { diff --git a/src/ui/spellbook_screen.cpp b/src/ui/spellbook_screen.cpp index 99af8c1f..08cdf0a0 100644 --- a/src/ui/spellbook_screen.cpp +++ b/src/ui/spellbook_screen.cpp @@ -45,7 +45,7 @@ void SpellbookScreen::loadSpellDBC(pipeline::AssetManager* assetManager) { } uint32_t fieldCount = dbc->getFieldCount(); - // Classic 1.12 Spell.dbc has 148 fields (Tooltip at index 147), TBC has ~167, WotLK has 234. + // Classic 1.12 Spell.dbc has 148 fields (Tooltip at index 147), TBC has ~220+ (SchoolMask at 215), WotLK has 234. // Require at least 148 fields so all expansions can load spell names/icons via the DBC layout. if (fieldCount < 148) { LOG_WARNING("Spellbook: Spell.dbc has ", fieldCount, " fields, too few to load");