summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2009-03-26 00:27:05 +0100
committerBjørn Lindeijer <bjorn@lindeijer.nl>2009-03-26 00:32:19 +0100
commitdfcc6397848d4597b386b688f689352de6c19ae2 (patch)
treea6e8c9afd6a49ea96e4498080a96d3e06ecaebd7 /src/localplayer.cpp
parentcd20fb3432498b8871401bdd65a143197e2a6538 (diff)
downloadmana-dfcc6397848d4597b386b688f689352de6c19ae2.tar.gz
mana-dfcc6397848d4597b386b688f689352de6c19ae2.tar.bz2
mana-dfcc6397848d4597b386b688f689352de6c19ae2.tar.xz
mana-dfcc6397848d4597b386b688f689352de6c19ae2.zip
Remove redundancy, fix variable names and other code cleanups
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r--src/localplayer.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 2233942d..08c778d2 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -645,12 +645,12 @@ void LocalPlayer::setTarget(Being *target)
mTarget->untarget();
if (mTarget && mTarget->getType() == Being::MONSTER)
- static_cast<Monster *>(mTarget)->showName(false);
+ static_cast<Monster *>(mTarget)->setShowName(false);
mTarget = target;
if (target && target->getType() == Being::MONSTER)
- static_cast<Monster *>(target)->showName(true);
+ static_cast<Monster *>(target)->setShowName(true);
}
#ifdef TMWSERV_SUPPORT
@@ -943,9 +943,6 @@ void LocalPlayer::attack(Being *target, bool keep)
setDirection(LEFT);
}
- // Implement charging attacks here
- mLastAttackTime = 0;
-
mWalkTime = tick_time;
mTargetTime = tick_time;
@@ -1079,7 +1076,7 @@ void LocalPlayer::setXp(int xp)
#endif
-void LocalPlayer::pickedUp(std::string item)
+void LocalPlayer::pickedUp(const std::string &item)
{
if (mMap)
{