mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-13 19:53:02 -04:00
Core/SAI: Add SAI action to create a conversation (#26169)
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
#include "SmartScriptMgr.h"
|
||||
#include "AreaTriggerDataStore.h"
|
||||
#include "AreaTriggerTemplate.h"
|
||||
#include "ConversationDataStore.h"
|
||||
#include "CreatureTextMgr.h"
|
||||
#include "DB2Stores.h"
|
||||
#include "DatabaseEnv.h"
|
||||
@@ -1571,6 +1572,16 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e)
|
||||
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_TALK_CONVERSATION:
|
||||
{
|
||||
if (!sConversationDataStore->GetConversationTemplate(e.action.conversation.id))
|
||||
{
|
||||
TC_LOG_ERROR("sql.sql", "SmartAIMgr: SMART_ACTION_TALK_CONVERSATION Entry " SI64FMTD " SourceType %u Event %u Action %u uses invalid entry %u, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.action.conversation.id);
|
||||
return false;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_FOLLOW:
|
||||
case SMART_ACTION_SET_ORIENTATION:
|
||||
case SMART_ACTION_STORE_TARGET_LIST:
|
||||
|
||||
Reference in New Issue
Block a user