Core/Spells: Corrected summon category SUMMON_CATEGORY_VEHICLE
Port TrinityCore Commit: https://github.com/TrinityCore/TrinityCore/commit/68cc366d88fd9cb4c759dc991568d994a29ba23e
This commit is contained in:
@@ -1843,12 +1843,19 @@ namespace Game.Spells
|
|||||||
|
|
||||||
// The spell that this effect will trigger. It has SPELL_AURA_CONTROL_VEHICLE
|
// The spell that this effect will trigger. It has SPELL_AURA_CONTROL_VEHICLE
|
||||||
uint spellId = SharedConst.VehicleSpellRideHardcoded;
|
uint spellId = SharedConst.VehicleSpellRideHardcoded;
|
||||||
SpellInfo spellInfo = Global.SpellMgr.GetSpellInfo((uint)effectInfo.CalcValue());
|
int basePoints = effectInfo.CalcValue();
|
||||||
if (spellInfo != null && spellInfo.HasAura(m_originalCaster.GetMap().GetDifficultyID(), AuraType.ControlVehicle))
|
if (basePoints > SharedConst.MaxVehicleSeats)
|
||||||
spellId = spellInfo.Id;
|
{
|
||||||
|
SpellInfo spellInfo = Global.SpellMgr.GetSpellInfo((uint)basePoints);
|
||||||
|
if (spellInfo != null && spellInfo.HasAura(m_originalCaster.GetMap().GetDifficultyID(), AuraType.ControlVehicle))
|
||||||
|
spellId = spellInfo.Id;
|
||||||
|
}
|
||||||
|
|
||||||
// Hard coded enter vehicle spell
|
// if we have small value, it indicates seat position
|
||||||
m_originalCaster.CastSpell(summon, spellId, true);
|
if (basePoints > 0 && basePoints < SharedConst.MaxVehicleSeats)
|
||||||
|
m_originalCaster.CastCustomSpell(spellId, SpellValueMod.BasePoint0, basePoints, summon, true);
|
||||||
|
else
|
||||||
|
m_originalCaster.CastSpell(summon, spellId, true);
|
||||||
|
|
||||||
uint faction = properties.Faction;
|
uint faction = properties.Faction;
|
||||||
if (faction == 0)
|
if (faction == 0)
|
||||||
|
|||||||
Reference in New Issue
Block a user