diff options
| author | Shauren <shauren.trinity@gmail.com> | 2022-03-26 18:59:44 +0100 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2022-03-26 18:59:44 +0100 |
| commit | 4eba9786708dd3b22d9053c1a14eac7e6d03242e (patch) | |
| tree | f68dcd89c7b41d3b403facb0a0fa7fd1fdb1eedf /src/server/game/AI/SmartScripts | |
| parent | ad30c22902a23996f805f74851aef58935c56a6e (diff) | |
Core/Misc: Rename SetXXXFlags updatefield functions to ReplaceAllXXXFlags
Diffstat (limited to 'src/server/game/AI/SmartScripts')
| -rw-r--r-- | src/server/game/AI/SmartScripts/SmartAI.cpp | 4 | ||||
| -rw-r--r-- | src/server/game/AI/SmartScripts/SmartScript.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/server/game/AI/SmartScripts/SmartAI.cpp b/src/server/game/AI/SmartScripts/SmartAI.cpp index 61d546ef17d..2c7e93cb0af 100644 --- a/src/server/game/AI/SmartScripts/SmartAI.cpp +++ b/src/server/game/AI/SmartScripts/SmartAI.cpp @@ -70,7 +70,7 @@ void SmartAI::StartPath(bool run/* = false*/, uint32 pathId/* = 0*/, bool repeat if (invoker && invoker->GetTypeId() == TYPEID_PLAYER) { _escortNPCFlags = me->m_unitData->NpcFlags[0]; - me->SetNpcFlags((NPCFlags)0); + me->ReplaceAllNpcFlags((NPCFlags)0); } me->GetMotionMaster()->MovePath(_path, _repeatWaypointPath); @@ -194,7 +194,7 @@ void SmartAI::EndPath(bool fail) if (_escortNPCFlags) { - me->SetNpcFlags((NPCFlags)_escortNPCFlags); + me->ReplaceAllNpcFlags((NPCFlags)_escortNPCFlags); _escortNPCFlags = 0; } diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index b7e78371973..b28edb29ef0 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -1645,7 +1645,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u { for (WorldObject* target : targets) if (IsCreature(target)) - target->ToUnit()->SetNpcFlags(NPCFlags(e.action.flag.flag)); + target->ToUnit()->ReplaceAllNpcFlags(NPCFlags(e.action.flag.flag)); break; } case SMART_ACTION_ADD_NPC_FLAG: |
