summaryrefslogtreecommitdiff
path: root/src/being
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-11-05 01:09:30 +0300
committerAndrei Karas <akaras@inbox.ru>2018-11-05 01:09:30 +0300
commit485e9bb12bf5dda318ac0ccbf1d2a1cd86cf8c70 (patch)
treece74f5a2fb646439cb58c2d85bc67ff29b70dbb7 /src/being
parent33f4a30373c8978d4e4f29422a5b0132fd14a0ec (diff)
downloadplus-485e9bb12bf5dda318ac0ccbf1d2a1cd86cf8c70.tar.gz
plus-485e9bb12bf5dda318ac0ccbf1d2a1cd86cf8c70.tar.bz2
plus-485e9bb12bf5dda318ac0ccbf1d2a1cd86cf8c70.tar.xz
plus-485e9bb12bf5dda318ac0ccbf1d2a1cd86cf8c70.zip
Fix code style.
Diffstat (limited to 'src/being')
-rw-r--r--src/being/localplayer.cpp11
-rw-r--r--src/being/playerinfo.cpp3
2 files changed, 10 insertions, 4 deletions
diff --git a/src/being/localplayer.cpp b/src/being/localplayer.cpp
index 54c95bd85..d344926fa 100644
--- a/src/being/localplayer.cpp
+++ b/src/being/localplayer.cpp
@@ -667,7 +667,8 @@ void LocalPlayer::startWalking(const unsigned char dir)
return;
}
- int dx = 0, dy = 0;
+ int dx = 0;
+ int dy = 0;
if ((dir & BeingDirection::UP) != 0)
dy--;
if ((dir & BeingDirection::DOWN) != 0)
@@ -1579,7 +1580,10 @@ bool LocalPlayer::pickUpItems(int pickUpType)
if (pickUpType == 0)
return status;
- int x1, y1, x2, y2;
+ int x1;
+ int y1;
+ int x2;
+ int y2;
switch (pickUpType)
{
case 1:
@@ -1662,7 +1666,8 @@ bool LocalPlayer::pickUpItems(int pickUpType)
void LocalPlayer::moveByDirection(const unsigned char dir)
{
- int dx = 0, dy = 0;
+ int dx = 0;
+ int dy = 0;
if ((dir & BeingDirection::UP) != 0)
dy--;
if ((dir & BeingDirection::DOWN) != 0)
diff --git a/src/being/playerinfo.cpp b/src/being/playerinfo.cpp
index 15c2eb939..32a39e0c7 100644
--- a/src/being/playerinfo.cpp
+++ b/src/being/playerinfo.cpp
@@ -173,7 +173,8 @@ int getStatEffective(const AttributesT id)
const std::pair<int, int> getStatExperience(const AttributesT id)
{
const StatMap::const_iterator it = mData.mStats.find(id);
- int a, b;
+ int a;
+ int b;
if (it != mData.mStats.end())
{
a = it->second.exp;