aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKaelima <kaelima@live.se>2012-07-23 01:19:16 -0700
committerKaelima <kaelima@live.se>2012-07-23 01:19:16 -0700
commit63d5a90394f5fc441772f4c90ad5a2e5e4aedbea (patch)
tree2a0408f2928284e8eeaa2df6f51272d77bcb6b83 /src
parent47054e6bc1b58ea1a553c550bd302e74016a2467 (diff)
parentc7a0378a826b11c6f15cf523ca639b97ccdf7c65 (diff)
Merge pull request #7134 from acrathos/master
SmartScripts: added new parameter to actions 90 & 91
Diffstat (limited to 'src')
-rw-r--r--src/server/game/AI/SmartScripts/SmartScript.cpp4
-rw-r--r--src/server/game/AI/SmartScripts/SmartScriptMgr.h2
2 files changed, 4 insertions, 2 deletions
diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp
index 103cde80f43..82d0945874c 100644
--- a/src/server/game/AI/SmartScripts/SmartScript.cpp
+++ b/src/server/game/AI/SmartScripts/SmartScript.cpp
@@ -1782,7 +1782,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
break;
for (ObjectList::const_iterator itr = targets->begin(); itr != targets->end(); ++itr)
if (IsUnit(*itr))
- (*itr)->ToUnit()->SetByteFlag(UNIT_FIELD_BYTES_1, 0, e.action.setunitByte.byte1);
+ (*itr)->ToUnit()->SetByteFlag(UNIT_FIELD_BYTES_1, e.action.setunitByte.type, e.action.setunitByte.byte1);
delete targets;
break;
@@ -1795,7 +1795,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
for (ObjectList::const_iterator itr = targets->begin(); itr != targets->end(); ++itr)
if (IsUnit(*itr))
- (*itr)->ToUnit()->RemoveByteFlag(UNIT_FIELD_BYTES_1, 0, e.action.delunitByte.byte1);
+ (*itr)->ToUnit()->RemoveByteFlag(UNIT_FIELD_BYTES_1, e.action.delunitByte.type, e.action.delunitByte.byte1);
delete targets;
break;
diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.h b/src/server/game/AI/SmartScripts/SmartScriptMgr.h
index cdb662edbaf..bc390441e04 100644
--- a/src/server/game/AI/SmartScripts/SmartScriptMgr.h
+++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.h
@@ -827,11 +827,13 @@ struct SmartAction
struct
{
uint32 byte1;
+ uint32 type;
} setunitByte;
struct
{
uint32 byte1;
+ uint32 type;
} delunitByte;
struct