mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-14 20:22:23 -04:00
Merge branch 'master' of github.com:TrinityCore/TrinityCore into 4.3.4
This commit is contained in:
@@ -1220,7 +1220,26 @@ bool SmartAIMgr::IsTextValid(SmartScriptHolder const& e, uint32 id) // unused
|
||||
uint32 entry = 0;
|
||||
|
||||
if (e.entryOrGuid >= 0)
|
||||
entry = uint32(e.entryOrGuid);
|
||||
{
|
||||
if (e.GetEventType() == SMART_EVENT_TEXT_OVER)
|
||||
{
|
||||
entry = e.event.textOver.creatureEntry;
|
||||
id = e.event.textOver.textGroupID;
|
||||
}
|
||||
else
|
||||
{
|
||||
switch (e.GetTargetType())
|
||||
{
|
||||
case SMART_TARGET_CREATURE_DISTANCE:
|
||||
case SMART_TARGET_CREATURE_RANGE:
|
||||
case SMART_TARGET_CLOSEST_CREATURE:
|
||||
return true; // ignore
|
||||
default:
|
||||
entry = uint32(e.entryOrGuid);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
entry = uint32(abs(e.entryOrGuid));
|
||||
@@ -1239,7 +1258,7 @@ bool SmartAIMgr::IsTextValid(SmartScriptHolder const& e, uint32 id) // unused
|
||||
|
||||
if (error)
|
||||
{
|
||||
TC_LOG_ERROR("sql.sql", "SmartAIMgr: Entry %d SourceType %u Event %u Action %u using non-existent Text id %d, skipped.", e.entryOrGuid, e.GetScriptType(), e.source_type, e.GetActionType(), id);
|
||||
TC_LOG_ERROR("sql.sql", "SmartAIMgr: Entry %d SourceType %u Event %u Action %u using non-existent Text id %d, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), id);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user