diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-02-07 01:53:51 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-02-07 01:53:51 +0300 |
commit | 2492b561385859b7ef76fe816a8dc845f0b9bd09 (patch) | |
tree | 62633f8cd7c027c2a8e1bae61264a79394aeb751 /src/being | |
parent | ce14a018a6f66aa1309ebe71a8217082d83cd0da (diff) | |
download | manaplus-2492b561385859b7ef76fe816a8dc845f0b9bd09.tar.gz manaplus-2492b561385859b7ef76fe816a8dc845f0b9bd09.tar.bz2 manaplus-2492b561385859b7ef76fe816a8dc845f0b9bd09.tar.xz manaplus-2492b561385859b7ef76fe816a8dc845f0b9bd09.zip |
Fix some casts between signed and unsigned in some files.
Diffstat (limited to 'src/being')
-rw-r--r-- | src/being/being.h | 20 | ||||
-rw-r--r-- | src/being/compoundsprite.cpp | 2 | ||||
-rw-r--r-- | src/being/compoundsprite.h | 4 |
3 files changed, 13 insertions, 13 deletions
diff --git a/src/being/being.h b/src/being/being.h index a689e961a..c91cac5b9 100644 --- a/src/being/being.h +++ b/src/being/being.h @@ -664,19 +664,19 @@ class Being notfinal : public ActorSprite, void setOtherTime() restrict2 noexcept { mOtherTime = cur_time; } - unsigned int getMoveTime() const restrict2 noexcept + int getMoveTime() const restrict2 noexcept { return mMoveTime; } - unsigned int getAttackTime() const restrict2 noexcept + int getAttackTime() const restrict2 noexcept { return mAttackTime; } - unsigned int getTalkTime() const restrict2 noexcept + int getTalkTime() const restrict2 noexcept { return mTalkTime; } - unsigned int getTestTime() const restrict2 noexcept + int getTestTime() const restrict2 noexcept { return mTestTime; } - unsigned int getOtherTime() const restrict2 noexcept + int getOtherTime() const restrict2 noexcept { return mOtherTime; } void resetCounters() restrict2; @@ -1168,11 +1168,11 @@ class Being notfinal : public ActorSprite, static uint8_t mShowBadges; static int mAwayEffect; - unsigned int mMoveTime; - unsigned int mAttackTime; - unsigned int mTalkTime; - unsigned int mOtherTime; - unsigned int mTestTime; + int mMoveTime; + int mAttackTime; + int mTalkTime; + int mOtherTime; + int mTestTime; int mAttackDelay; int mMinHit; int mMaxHit; diff --git a/src/being/compoundsprite.cpp b/src/being/compoundsprite.cpp index 08376e748..df3cfcec0 100644 --- a/src/being/compoundsprite.cpp +++ b/src/being/compoundsprite.cpp @@ -261,7 +261,7 @@ void CompoundSprite::addSprite(Sprite *const sprite) mNeedsRedraw = true; } -void CompoundSprite::setSprite(const int layer, Sprite *const sprite) +void CompoundSprite::setSprite(const size_t layer, Sprite *const sprite) { // Skip if it won't change anything if (mSprites.at(layer) == sprite) diff --git a/src/being/compoundsprite.h b/src/being/compoundsprite.h index 3f5bd55de..88e8486df 100644 --- a/src/being/compoundsprite.h +++ b/src/being/compoundsprite.h @@ -83,9 +83,9 @@ class CompoundSprite notfinal : public Sprite void addSprite(Sprite *const sprite); - void setSprite(const int layer, Sprite *const sprite); + void setSprite(const size_t layer, Sprite *const sprite); - Sprite *getSprite(int layer) const A_WARN_UNUSED + Sprite *getSprite(const size_t layer) const A_WARN_UNUSED { return mSprites.at(layer); } void removeSprite(const int layer); |