From 88ff97c1f96381565c47f8ca1993bdc7fce19fd6 Mon Sep 17 00:00:00 2001 From: Teleqraph Date: Thu, 20 Jul 2023 19:09:27 +0200 Subject: Core/Units: Added helper functions to modify UNIT_FLAG_UNINTERACTIBLE (#29159) Co-authored-by: Shauren --- src/server/game/AI/SmartScripts/SmartScript.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/server/game/AI/SmartScripts') diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index b27e0847c3f..561ec21655f 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -2438,10 +2438,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u { if (IsUnit(target)) { - if (e.action.setUninteractible.uninteractible) - target->ToUnit()->SetUnitFlag(UNIT_FLAG_UNINTERACTIBLE); - else - target->ToUnit()->RemoveUnitFlag(UNIT_FLAG_UNINTERACTIBLE); + target->ToUnit()->SetUninteractible(e.action.setUninteractible.uninteractible != 0); } } break; -- cgit v1.2.3