summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
diff options
context:
space:
mode:
authorEugenio Favalli <elvenprogrammer@gmail.com>2006-07-19 15:12:06 +0000
committerEugenio Favalli <elvenprogrammer@gmail.com>2006-07-19 15:12:06 +0000
commit4050f8c0bced625a95d542d30647c3f8bbf2267b (patch)
tree420d65a5ed6a2155762b4e13a4c90ab2df9f888e /src/localplayer.cpp
parentda3a1fd114dd7b8e5e8c880bd987506acc16ac42 (diff)
downloadmana-4050f8c0bced625a95d542d30647c3f8bbf2267b.tar.gz
mana-4050f8c0bced625a95d542d30647c3f8bbf2267b.tar.bz2
mana-4050f8c0bced625a95d542d30647c3f8bbf2267b.tar.xz
mana-4050f8c0bced625a95d542d30647c3f8bbf2267b.zip
Merged new_animation branch until r2415 into trunk.
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r--src/localplayer.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 0313fe81..339435a5 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -210,7 +210,7 @@ void LocalPlayer::walk(unsigned char dir)
{
// Update the player direction to where he wants to walk
// Warning: Not communicated to the server yet
- mDirection = dir;
+ setDirection(dir);
}
}
@@ -344,22 +344,22 @@ void LocalPlayer::attack(Being *target, bool keep)
if (abs(dist_y) >= abs(dist_x))
{
if (dist_y > 0)
- mDirection = DOWN;
+ setDirection(DOWN);
else
- mDirection = UP;
+ setDirection(UP);
}
else
{
if (dist_x > 0)
- mDirection = RIGHT;
+ setDirection(RIGHT);
else
- mDirection = LEFT;
+ setDirection(LEFT);
}
// Implement charging attacks here
mLastAttackTime = 0;
- mAction = ATTACK;
+ setAction(ATTACK);
mWalkTime = tick_time;
if (getWeapon() == 2)
sound.playSfx("sfx/bow_shoot_1.ogg");