summaryrefslogtreecommitdiff
path: root/src/actions/commands.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-03-22 22:09:02 +0300
committerAndrei Karas <akaras@inbox.ru>2016-03-22 22:09:02 +0300
commit51c9a63a660fe88cfa44d93028e6ae2448fb889d (patch)
tree8c4b1db548208737a43d52fbe28b99cb5060f017 /src/actions/commands.cpp
parentbce511aaf8b9d2b5d447f67ba0c05e2f9a92b7ca (diff)
downloadmv-51c9a63a660fe88cfa44d93028e6ae2448fb889d.tar.gz
mv-51c9a63a660fe88cfa44d93028e6ae2448fb889d.tar.bz2
mv-51c9a63a660fe88cfa44d93028e6ae2448fb889d.tar.xz
mv-51c9a63a660fe88cfa44d93028e6ae2448fb889d.zip
Not allow moving from sit state if server not support it.
Diffstat (limited to 'src/actions/commands.cpp')
-rw-r--r--src/actions/commands.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/actions/commands.cpp b/src/actions/commands.cpp
index 1c57bd677..529025481 100644
--- a/src/actions/commands.cpp
+++ b/src/actions/commands.cpp
@@ -459,8 +459,11 @@ impHandler(follow)
impHandler(navigate)
{
- if (!localPlayer)
+ if (!localPlayer ||
+ !localPlayer->canMove())
+ {
return false;
+ }
int x = 0;
int y = 0;
@@ -474,8 +477,11 @@ impHandler(navigate)
impHandler(navigateTo)
{
- if (!localPlayer)
+ if (!localPlayer ||
+ !localPlayer->canMove())
+ {
return false;
+ }
const std::string args = event.args;
if (args.empty())