diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-07-23 12:45:57 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-07-23 12:45:57 +0300 |
commit | 6576d46a7f420edfc53226811a3158d6e509a7bc (patch) | |
tree | ffd0e61bd56bb11f76cd27cdfbaaa6b10b9ec14d | |
parent | 833ee2d763001667f5818a1922f5e96d60890cd9 (diff) | |
download | manaplus-6576d46a7f420edfc53226811a3158d6e509a7bc.tar.gz manaplus-6576d46a7f420edfc53226811a3158d6e509a7bc.tar.bz2 manaplus-6576d46a7f420edfc53226811a3158d6e509a7bc.tar.xz manaplus-6576d46a7f420edfc53226811a3158d6e509a7bc.zip |
Fix compilation warnings and fix issue introduced in last commits.
-rw-r--r-- | src/being/localplayer.cpp | 2 | ||||
-rw-r--r-- | src/gui/windows/npcdialog.cpp | 4 | ||||
-rw-r--r-- | src/gui/windows/npcdialog.h | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/src/being/localplayer.cpp b/src/being/localplayer.cpp index 07447601e..c3937badc 100644 --- a/src/being/localplayer.cpp +++ b/src/being/localplayer.cpp @@ -2160,7 +2160,7 @@ void LocalPlayer::specialMove(const unsigned char direction) if (mAction == BeingAction::MOVE) return; - int max; + unsigned int max; if (settings.moveType == 2) max = 5; diff --git a/src/gui/windows/npcdialog.cpp b/src/gui/windows/npcdialog.cpp index 0ccae687b..aab395a85 100644 --- a/src/gui/windows/npcdialog.cpp +++ b/src/gui/windows/npcdialog.cpp @@ -824,7 +824,7 @@ void NpcDialog::saveCamera() if (!viewport || mCameraMode >= 0) return; - mCameraMode = settings.cameraMode; + mCameraMode = static_cast<int>(settings.cameraMode); mCameraX = viewport->getCameraRelativeX(); mCameraY = viewport->getCameraRelativeY(); } @@ -834,7 +834,7 @@ void NpcDialog::restoreCamera() if (!viewport || mCameraMode == -1) return; - if (settings.cameraMode != mCameraMode) + if (static_cast<int>(settings.cameraMode) != mCameraMode) viewport->toggleCameraMode(); if (mCameraMode) { diff --git a/src/gui/windows/npcdialog.h b/src/gui/windows/npcdialog.h index 7c72550c9..bd9c21678 100644 --- a/src/gui/windows/npcdialog.h +++ b/src/gui/windows/npcdialog.h @@ -296,7 +296,7 @@ class NpcDialog final : public Window, PlayerBox *mPlayerBox; Being *mAvatarBeing; int mLastNextTime; - unsigned int mCameraMode; + int mCameraMode; int mCameraX; int mCameraY; bool mShowAvatar; |