diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-07-17 23:26:59 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-07-17 23:26:59 +0300 |
commit | 7e0a97d2521b9ce57003176e82a0b5564aa003c2 (patch) | |
tree | 5b2cfe1afe09bea1063f783050c1fb549daee76d /src/being.cpp | |
parent | f68cbf700a99f2f184715a5b8025bcb4b6525391 (diff) | |
download | manaplus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.tar.gz manaplus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.tar.bz2 manaplus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.tar.xz manaplus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.zip |
Fix more code style and additional warnings.
Diffstat (limited to 'src/being.cpp')
-rw-r--r-- | src/being.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/being.cpp b/src/being.cpp index 2d276a72c..6f0ac307b 100644 --- a/src/being.cpp +++ b/src/being.cpp @@ -434,7 +434,7 @@ void Being::setDestination(int dstX, int dstY) Path thisPath = mMap->findPixelPath(static_cast<int>(mPos.x), static_cast<int>(mPos.y), dest.x, dest.y, static_cast<int>(getCollisionRadius()), - static_cast<int>(getWalkMask())); + static_cast<unsigned char>(getWalkMask())); if (thisPath.empty()) { @@ -1166,7 +1166,7 @@ void Being::setDirection(uint8_t direction) { dir = DIRECTION_LEFT; } - mSpriteDirection = dir; + mSpriteDirection = static_cast<uint8_t>(dir); CompoundSprite::setSpriteDirection(dir); recalcSpritesOrder(); @@ -2648,7 +2648,7 @@ void Being::updatePercentHP() } } -int Being::genderToInt(Gender sex) +uint8_t Being::genderToInt(Gender sex) { switch (sex) { @@ -2663,7 +2663,7 @@ int Being::genderToInt(Gender sex) } } -Gender Being::intToGender(int sex) +Gender Being::intToGender(uint8_t sex) { switch (sex) { |