diff options
author | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2011-03-15 23:09:17 +0100 |
---|---|---|
committer | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2011-03-15 23:09:17 +0100 |
commit | 29259f72663e0eb1820b4d4a0f018acef61bfb2c (patch) | |
tree | ec5b5874e2860200b1330c9cb7ca6675f4430170 /src/being.cpp | |
parent | 2f48ff6c56db96fb2c0a51d9e4a6522e07ab1339 (diff) | |
download | mana-29259f72663e0eb1820b4d4a0f018acef61bfb2c.tar.gz mana-29259f72663e0eb1820b4d4a0f018acef61bfb2c.tar.bz2 mana-29259f72663e0eb1820b4d4a0f018acef61bfb2c.tar.xz mana-29259f72663e0eb1820b4d4a0f018acef61bfb2c.zip |
Made the tA Beinghandler avoid dealing with flawed coordinates.
Also fixed again a condition in Being::logic().
I'll beautify the code in tmwAthena:Beinghandler once everything
will be working better.
Note: I also suspect current clients to flood the server with
keyboard messages, hence blocking the animation when they are remote.
I'll need to test that with someone having the same client than here..
Diffstat (limited to 'src/being.cpp')
-rw-r--r-- | src/being.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/being.cpp b/src/being.cpp index 8c7f45bb..b79b65b3 100644 --- a/src/being.cpp +++ b/src/being.cpp @@ -673,6 +673,8 @@ void Being::logic() mText = 0; } + ActorSprite::logic(); + if ((mAction != DEAD) && !mSpeedPixelsPerTick.isNull()) { const Vector dest = (mPath.empty()) ? @@ -680,7 +682,7 @@ void Being::logic() mPath.front().y); // Avoid going to flawed destinations - if (mDest.x <= 0 || mDest.y <= 0) + if (dest.x <= 0 || dest.y <= 0) { // We make the being stop move in that case. mDest = mPos; @@ -768,8 +770,6 @@ void Being::logic() } } - ActorSprite::logic(); - // Remove it after 3 secs. TODO: Just play the dead animation before removing if (!isAlive() && Net::getGameHandler()->removeDeadBeings() && get_elapsed_time(mActionTime) > 3000) |