summaryrefslogtreecommitdiff
path: root/src/actions/commands.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-08-26 21:43:19 +0300
committerAndrei Karas <akaras@inbox.ru>2014-08-26 21:43:19 +0300
commit0888773fc1de5cc2aa1d92564e8d05231189e6f9 (patch)
tree001209ae09a69d15d29007d8a1762de56c94e362 /src/actions/commands.cpp
parentac2cda962d5fc3e23858527be45a8ae7b9856b84 (diff)
downloadmv-0888773fc1de5cc2aa1d92564e8d05231189e6f9.tar.gz
mv-0888773fc1de5cc2aa1d92564e8d05231189e6f9.tar.bz2
mv-0888773fc1de5cc2aa1d92564e8d05231189e6f9.tar.xz
mv-0888773fc1de5cc2aa1d92564e8d05231189e6f9.zip
Move chat command /addattack into actions.
Diffstat (limited to 'src/actions/commands.cpp')
-rw-r--r--src/actions/commands.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/actions/commands.cpp b/src/actions/commands.cpp
index ab45786e1..78a2fc0e5 100644
--- a/src/actions/commands.cpp
+++ b/src/actions/commands.cpp
@@ -483,4 +483,17 @@ impHandler(addPriorityAttack)
return true;
}
+impHandler(addAttack)
+{
+ if (!actorManager || actorManager->isInAttackList(event.args))
+ return false;
+
+ actorManager->removeAttackMob(event.args);
+ actorManager->addAttackMob(event.args);
+
+ if (socialWindow)
+ socialWindow->updateAttackFilter();
+ return true;
+}
+
} // namespace Actions