summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-09-26 18:49:55 +0300
committerAndrei Karas <akaras@inbox.ru>2015-09-26 18:49:55 +0300
commitfaa629fe190cded836416c3e7d461b7f74b4ff25 (patch)
treef2110505df3f8e9a5c9eca9df2212391c18d80c6 /src
parentbdac554898702846d2fa6f1aaf94fbb4d2e05425 (diff)
downloadmv-faa629fe190cded836416c3e7d461b7f74b4ff25.tar.gz
mv-faa629fe190cded836416c3e7d461b7f74b4ff25.tar.bz2
mv-faa629fe190cded836416c3e7d461b7f74b4ff25.tar.xz
mv-faa629fe190cded836416c3e7d461b7f74b4ff25.zip
Disable differnt heal or magic action on non tmwa servers.
Diffstat (limited to 'src')
-rw-r--r--src/actions/actions.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/actions/actions.cpp b/src/actions/actions.cpp
index f77b22ddf..4655c9833 100644
--- a/src/actions/actions.cpp
+++ b/src/actions/actions.cpp
@@ -82,6 +82,7 @@
#include "net/ipc.h"
#ifdef EATHENA_SUPPORT
#include "net/mercenaryhandler.h"
+#include "net/net.h"
#include "net/vendinghandler.h"
#endif
#include "net/npchandler.h"
@@ -486,6 +487,10 @@ impHandler(dropItemInvAll)
impHandler(heal)
{
+#ifdef EATHENA_SUPPORT
+ if (Net::getNetworkType() != ServerType::TMWATHENA)
+ return false;
+#endif
if (actorManager && localPlayer)
{
std::string args = event.args;
@@ -535,6 +540,10 @@ impHandler(heal)
impHandler0(healmd)
{
+#ifdef EATHENA_SUPPORT
+ if (Net::getNetworkType() != ServerType::TMWATHENA)
+ return false;
+#endif
if (actorManager)
{
const int matk = PlayerInfo::getStatEffective(Attributes::MATK);
@@ -564,6 +573,10 @@ impHandler0(healmd)
impHandler0(itenplz)
{
+#ifdef EATHENA_SUPPORT
+ if (Net::getNetworkType() != ServerType::TMWATHENA)
+ return false;
+#endif
if (actorManager)
{
if (playerHandler &&
@@ -589,6 +602,10 @@ impHandler0(setHome)
impHandler0(magicAttack)
{
+#ifdef EATHENA_SUPPORT
+ if (Net::getNetworkType() != ServerType::TMWATHENA)
+ return false;
+#endif
if (localPlayer)
{
localPlayer->magicAttack();