From 6c19094aae490d4c7a784a463d9bcf08d1525eed Mon Sep 17 00:00:00 2001 From: Karrz1 <127596890+Karrz1@users.noreply.github.com> Date: Tue, 20 Oct 2026 02:06:14 +0100 Subject: [PATCH] Trainer kit: bots do not learn riding from the trainer (#84) A retail trainer opens the riding tiers by level; vanilla gives 75 at level 40 and 150 at level 60, which the bot module sets directly. The trainer kit now skips riding skills and counts them as skill-line rejects. --- src/server/game/Entities/Creature/Trainer.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/server/game/Entities/Creature/Trainer.cpp b/src/server/game/Entities/Creature/Trainer.cpp index a8471f90ab..b2bb5cd333 100644 --- a/src/server/game/Entities/Creature/Trainer.cpp +++ b/src/server/game/Entities/Creature/Trainer.cpp @@ -190,6 +190,15 @@ namespace Trainer if (tally) ++tally->battle_pet; continue; } + // Riding is not the trainer's to give here: a retail trainer opens the tiers by level (Journeyman at 40), vanilla gives 75 at 40 + // and 150 at 60, and API::learn_riding_free sets exactly that. + if (SpellInfo const* info = sSpellMgr->GetSpellInfo(trainerSpell.SpellId, DIFFICULTY_NONE)) + if (std::any_of(info->GetEffects().begin(), info->GetEffects().end(), [](SpellEffectInfo const& eff) + { return eff.IsEffect(SPELL_EFFECT_SKILL) && eff.MiscValue == SKILL_RIDING; })) + { + if (tally) ++tally->skill_line; + continue; + } if (!CanTeachSpell(player, &trainerSpell)) { if (tally)