Core/Movement: use helpers for validation
(cherry picked from commit 71188062314ee94402d9d3e228fd5b46e8865b18)
This commit is contained in:
@@ -920,7 +920,7 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e)
|
||||
}
|
||||
case SMART_EVENT_MOVEMENTINFORM:
|
||||
{
|
||||
if (e.event.movementInform.type >= MAX_MOTION_TYPE)
|
||||
if (IsInvalidMovementGeneratorType(e.event.movementInform.type))
|
||||
{
|
||||
TC_LOG_ERROR("sql.sql", "SmartAIMgr: Entry " SI64FMTD " SourceType %u Event %u Action %u uses invalid Motion type %u, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.event.movementInform.type);
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user