From e85c6227064c905945a4d49a5e11a0078243a1ac Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 18 Sep 2013 18:56:46 +0300 Subject: add missing const in being classes. --- src/being/being.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/being/being.cpp') diff --git a/src/being/being.cpp b/src/being/being.cpp index 2e7f6d67b..3f40398a0 100644 --- a/src/being/being.cpp +++ b/src/being/being.cpp @@ -648,7 +648,8 @@ int Being::getHitEffect(const Being *const attacker, { if (attacker) { - const ItemInfo *attackerWeapon = attacker->getEquippedWeapon(); + const ItemInfo *const attackerWeapon + = attacker->getEquippedWeapon(); if (attackerWeapon && attacker->getType() == PLAYER) { if (type == MISS) @@ -663,7 +664,7 @@ int Being::getHitEffect(const Being *const attacker, const BeingInfo *const info = attacker->getInfo(); if (info) { - const Attack *atk = info->getAttack(attackId); + const Attack *const atk = info->getAttack(attackId); if (atk) { if (type == MISS) @@ -768,7 +769,7 @@ void Being::handleSkill(Being *const victim, const int damage, if (this != player_node) setAction(Being::ATTACK, 1); - SkillInfo *const skill = skillDialog->getSkill(skillId); + const SkillInfo *const skill = skillDialog->getSkill(skillId); const SkillData *const data = skill ? skill->getData1(skillLevel) : nullptr; if (data) @@ -1584,7 +1585,7 @@ void Being::logic() } void Being::drawEmotion(Graphics *const graphics, const int offsetX, - const int offsetY) + const int offsetY) const { const int px = getPixelX() - offsetX - 16; const int py = getPixelY() - offsetY - 64 - 32; @@ -3028,7 +3029,7 @@ void Being::updatePets() } void Being::playSfx(const SoundInfo &sound, Being *const being, - const bool main, const int x, const int y) + const bool main, const int x, const int y) const { if (being) { -- cgit v1.2.3-60-g2f50