summaryrefslogtreecommitdiff
path: root/src/localplayer.h
diff options
context:
space:
mode:
authorYohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer>2012-02-03 13:06:21 +0100
committerYohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer>2012-02-03 14:44:43 +0100
commit024088d76569ef07be7f166f22f3f5e22592a586 (patch)
treed72732228963c969f86ec0d5f4f96fc703bb71f5 /src/localplayer.h
parente2f9e7cf25d3dd2b239496945a83a0d7c6c4e86e (diff)
downloadMana-024088d76569ef07be7f166f22f3f5e22592a586.tar.gz
Mana-024088d76569ef07be7f166f22f3f5e22592a586.tar.bz2
Mana-024088d76569ef07be7f166f22f3f5e22592a586.tar.xz
Mana-024088d76569ef07be7f166f22f3f5e22592a586.zip
Fixed the go and attack mouse click
I first removed the keep attacking and pickup targetting unset statements in the setdestination() function since it was messing with all the rest of the logic, and put those targetting logic where they belonged more. I also changed the gotoTarget function to properly call the setTarget function which permitted to properly unset the previous target in that case. I also finished the logic built around the mGoingToTarget member (until then actually unused) to make it all work again. At last, I also removed a now false comment in the startWalking() function. Reviewed-by: Erik Schilling
Diffstat (limited to 'src/localplayer.h')
-rw-r--r--src/localplayer.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/localplayer.h b/src/localplayer.h
index 8e5795c3..64e37fee 100644
--- a/src/localplayer.h
+++ b/src/localplayer.h
@@ -128,6 +128,8 @@ class LocalPlayer : public Being
* Sets a new destination for this being to walk to.
*/
virtual void setDestination(int x, int y);
+ virtual void setDestination(const Vector &dest)
+ { setDestination((int)dest.x, (int)dest.y); }
/**
* Sets a new direction to keep walking in, when using the keyboard