Core/ConditionMgr: added CONDITION_SOURCE_TYPE_VEHICLE_SPELL, sourceGroup=creatureTemplate.entry, sourceEntry=spellEntry

--HG--
branch : trunk
This commit is contained in:
Rat
2010-10-22 22:45:11 +02:00
parent 3ee05b26ce
commit e67f04d362
3 changed files with 79 additions and 5 deletions
@@ -19028,6 +19028,12 @@ void Player::VehicleSpellInitialize()
if (!spellInfo)
continue;
ConditionList conditions = sConditionMgr.GetConditionsForVehicleSpell(veh->ToCreature()->GetEntry(), spellId);
if (!sConditionMgr.IsPlayerMeetToConditions(this, conditions))
{
sLog.outDebug("VehicleSpellInitialize: conditions not met for Vehicle entry %u spell %u", veh->ToCreature()->GetEntry(), spellId);
continue;
}
if (IsPassiveSpell(spellId))
{
veh->CastSpell(veh, spellId, true);