mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-13 17:19:07 +00:00
feat(Core/SmartScripts): SMART_ACTION_SET_MOVEMENT_SPEED (#10018)
This commit is contained in:
committed by
GitHub
parent
5f9235a62d
commit
2bc373b4f6
@@ -1182,6 +1182,21 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e)
|
||||
}
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_SET_MOVEMENT_SPEED:
|
||||
{
|
||||
if (e.action.movementSpeed.movementType >= MAX_MOVE_TYPE)
|
||||
{
|
||||
LOG_ERROR("sql.sql", "SmartAIMgr: Entry %u SourceType %u Event %u Action %u uses invalid movementType %u, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.action.movementSpeed.movementType);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!e.action.movementSpeed.speedInteger && !e.action.movementSpeed.speedFraction)
|
||||
{
|
||||
LOG_ERROR("sql.sql", "SmartAIMgr: Entry %u SourceType %u Event %u Action %u uses speed 0, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType());
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_START_CLOSEST_WAYPOINT:
|
||||
case SMART_ACTION_FOLLOW:
|
||||
case SMART_ACTION_SET_ORIENTATION:
|
||||
|
||||
Reference in New Issue
Block a user