*Auto enter vehicle for summon vehicle spells.
--HG-- branch : trunk
This commit is contained in:
@@ -6541,8 +6541,8 @@ void Aura::HandleAuraControlVehicle(bool apply, bool Real)
|
|||||||
if(Pet *pet = m_target->GetPet())
|
if(Pet *pet = m_target->GetPet())
|
||||||
pet->Remove(PET_SAVE_AS_CURRENT);
|
pet->Remove(PET_SAVE_AS_CURRENT);
|
||||||
|
|
||||||
WorldPacket data(SMSG_ON_CANCEL_EXPECTED_RIDE_VEHICLE_AURA, 0);
|
//WorldPacket data(SMSG_ON_CANCEL_EXPECTED_RIDE_VEHICLE_AURA, 0);
|
||||||
((Player*)m_target)->GetSession()->SendPacket(&data);
|
//((Player*)m_target)->GetSession()->SendPacket(&data);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Aura::HandleAuraConvertRune(bool apply, bool Real)
|
void Aura::HandleAuraConvertRune(bool apply, bool Real)
|
||||||
|
|||||||
@@ -6657,6 +6657,13 @@ void Spell::SummonVehicle(uint32 entry, SummonPropertiesEntry const *properties)
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
vehicle->SetUInt32Value(UNIT_CREATED_BY_SPELL, m_spellInfo->Id);
|
vehicle->SetUInt32Value(UNIT_CREATED_BY_SPELL, m_spellInfo->Id);
|
||||||
|
|
||||||
|
if(damage)
|
||||||
|
{
|
||||||
|
m_caster->CastSpell(vehicle, damage, true);
|
||||||
|
if(m_caster->GetTypeId() == TYPEID_PLAYER)
|
||||||
|
((Player*)m_caster)->EnterVehicle(vehicle);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Spell::GetSummonPosition(float &x, float &y, float &z, float radius, uint32 count)
|
void Spell::GetSummonPosition(float &x, float &y, float &z, float radius, uint32 count)
|
||||||
|
|||||||
Reference in New Issue
Block a user