summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-09-05 00:35:59 +0300
committerAndrei Karas <akaras@inbox.ru>2013-09-05 01:25:36 +0300
commit9ac1ca5aa120263a1d19735eef6c9614306e45e0 (patch)
treeaba5691b052ad938ddd6166faab72c12c6d2439f
parent0eafefa3d40cf730749cd7fdfb94f73313e1a159 (diff)
downloadmanaverse-9ac1ca5aa120263a1d19735eef6c9614306e45e0.tar.gz
manaverse-9ac1ca5aa120263a1d19735eef6c9614306e45e0.tar.bz2
manaverse-9ac1ca5aa120263a1d19735eef6c9614306e45e0.tar.xz
manaverse-9ac1ca5aa120263a1d19735eef6c9614306e45e0.zip
simplify next draw frame calculation in being.
-rw-r--r--src/being/being.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index 7dfe9d9b6..252de4c3b 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -1481,10 +1481,8 @@ void Being::logic()
case MOVE:
{
- if (getWalkSpeed().x && static_cast<int> ((static_cast<float>(
- get_elapsed_time(mActionTime)) * static_cast<float>(
- frameCount)) / getWalkSpeed().x)
- >= frameCount)
+ if (static_cast<float>(get_elapsed_time(mActionTime)
+ >= getWalkSpeed().x))
{
nextTile();
}
@@ -1493,8 +1491,6 @@ void Being::logic()
case ATTACK:
{
-// std::string particleEffect("");
-
if (!mActionTime)
break;