Core/SmartAI: added ACTION_ACTIVATE_TAXI

--HG--
branch : trunk
This commit is contained in:
Rat
2010-11-19 20:23:08 +01:00
parent 5cd3904059
commit 67fa59fb68
3 changed files with 20 additions and 2 deletions

View File

@@ -541,6 +541,15 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder &e)
case SMART_ACTION_ADD_QUEST:
if (e.action.quest.quest && !IsQuestValid(e, e.action.quest.quest)) return false;
break;
case SMART_ACTION_ACTIVATE_TAXI:
{
if (!sTaxiPathStore.LookupEntry(e.action.taxi.id))
{
sLog.outErrorDb("SmartAIMgr: Entry %d SourceType %u Event %u Action %u uses invalid Taxi path ID %u, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.action.taxi.id);
return false;
}
break;
}
case SMART_ACTION_RANDOM_EMOTE:
if (e.action.randomEmote.emote1 && !IsEmoteValid(e, e.action.randomEmote.emote1)) return false;
if (e.action.randomEmote.emote2 && !IsEmoteValid(e, e.action.randomEmote.emote2)) return false;