diff options
| author | offl <offl@users.noreply.github.com> | 2021-10-21 00:58:32 +0300 |
|---|---|---|
| committer | offl <offl@users.noreply.github.com> | 2021-10-21 00:58:32 +0300 |
| commit | ab3bb36a46d5419cd0ac95ab367e68252ec88044 (patch) | |
| tree | 0b10e81f4ff4e4322b88a94d81d6ca4680d7f56b | |
| parent | d81d181bc14932310df8450f1ca1ac977ede2bf9 (diff) | |
Core/SAI: Make 'no, thanks' actions deprecated
Deprecated events and actions will be removed after 2 weeks
| -rw-r--r-- | src/server/game/AI/SmartScripts/SmartScriptMgr.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp index 4b64a5b3089..6f8299c22da 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp @@ -2193,6 +2193,24 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e) return false; } + // Additional check for deprecated + switch (e.GetActionType()) + { + // Deprecated + case SMART_ACTION_SET_SWIM: + case SMART_ACTION_OVERRIDE_SCRIPT_BASE_OBJECT: + case SMART_ACTION_RESET_SCRIPT_BASE_OBJECT: + case SMART_ACTION_SET_CAN_FLY: + case SMART_ACTION_REMOVE_AURAS_BY_TYPE: + case SMART_ACTION_SET_SIGHT_DIST: + case SMART_ACTION_FLEE: + case SMART_ACTION_REMOVE_ALL_GAMEOBJECTS: + TC_LOG_WARN("sql.sql.deprecation", "SmartAIMgr: Deprecated action_type(%u), Entry %d SourceType %u Event %u, it might be removed in the future, loaded for now.", e.GetActionType(), e.entryOrGuid, e.GetScriptType(), e.event_id); + break; + default: + break; + } + if (!CheckUnusedActionParams(e)) return false; |
