summaryrefslogtreecommitdiff
path: root/src/being
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-06-11 01:00:01 +0300
committerAndrei Karas <akaras@inbox.ru>2017-06-11 01:00:01 +0300
commit2f768a34f72560ee8b2934228f548a4909533887 (patch)
tree0849395dea15a851fcec1a6236c29648cb41add7 /src/being
parent05edba87ab0dae7ac4480c86655afe59cd1dd3bd (diff)
downloadplus-2f768a34f72560ee8b2934228f548a4909533887.tar.gz
plus-2f768a34f72560ee8b2934228f548a4909533887.tar.bz2
plus-2f768a34f72560ee8b2934228f548a4909533887.tar.xz
plus-2f768a34f72560ee8b2934228f548a4909533887.zip
Rename player_relations into playerRelations.
Diffstat (limited to 'src/being')
-rw-r--r--src/being/being.cpp18
-rw-r--r--src/being/localplayer.cpp4
-rw-r--r--src/being/playerrelations.cpp4
-rw-r--r--src/being/playerrelations.h4
4 files changed, 15 insertions, 15 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index deac96e2c..97492d431 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -2461,7 +2461,7 @@ void Being::showName() restrict2
delete2(mDispName);
- if (mHideErased && player_relations.getRelation(mName) == Relation::ERASED)
+ if (mHideErased && playerRelations.getRelation(mName) == Relation::ERASED)
return;
std::string displayName(mName);
@@ -2488,7 +2488,7 @@ void Being::showName() restrict2
font = boldFont;
}
else if (mType == ActorType::Player
- && !player_relations.isGoodName(this) && (gui != nullptr))
+ && !playerRelations.isGoodName(this) && (gui != nullptr))
{
font = gui->getSecureFont();
}
@@ -2573,7 +2573,7 @@ void Being::updateColors()
{
mTextColor = &theme->getColor(ThemeColorId::PLAYER, 255);
- if (player_relations.getRelation(mName) != Relation::ERASED)
+ if (playerRelations.getRelation(mName) != Relation::ERASED)
mErased = false;
else
mErased = true;
@@ -2597,24 +2597,24 @@ void Being::updateColors()
{
mNameColor = &userPalette->getColor(UserColorId::GUILD);
}
- else if (player_relations.getRelation(mName) == Relation::FRIEND)
+ else if (playerRelations.getRelation(mName) == Relation::FRIEND)
{
mNameColor = &userPalette->getColor(UserColorId::FRIEND);
}
- else if (player_relations.getRelation(mName) ==
+ else if (playerRelations.getRelation(mName) ==
Relation::DISREGARDED
- || player_relations.getRelation(mName) ==
+ || playerRelations.getRelation(mName) ==
Relation::BLACKLISTED)
{
mNameColor = &userPalette->getColor(UserColorId::DISREGARDED);
}
- else if (player_relations.getRelation(mName)
+ else if (playerRelations.getRelation(mName)
== Relation::IGNORED ||
- player_relations.getRelation(mName) == Relation::ENEMY2)
+ playerRelations.getRelation(mName) == Relation::ENEMY2)
{
mNameColor = &userPalette->getColor(UserColorId::IGNORED);
}
- else if (player_relations.getRelation(mName) == Relation::ERASED)
+ else if (playerRelations.getRelation(mName) == Relation::ERASED)
{
mNameColor = &userPalette->getColor(UserColorId::ERASED);
}
diff --git a/src/being/localplayer.cpp b/src/being/localplayer.cpp
index 5c275b3f6..e2b126065 100644
--- a/src/being/localplayer.cpp
+++ b/src/being/localplayer.cpp
@@ -2742,10 +2742,10 @@ bool LocalPlayer::checAttackPermissions(const Being *const target)
case 0:
return true;
case 1:
- return !(player_relations.getRelation(target->mName)
+ return !(playerRelations.getRelation(target->mName)
== Relation::FRIEND);
case 2:
- return player_relations.checkBadRelation(target->mName);
+ return playerRelations.checkBadRelation(target->mName);
default:
case 3:
return false;
diff --git a/src/being/playerrelations.cpp b/src/being/playerrelations.cpp
index e45376137..690665b15 100644
--- a/src/being/playerrelations.cpp
+++ b/src/being/playerrelations.cpp
@@ -455,7 +455,7 @@ void PlayerRelationsManager::ignoreTrade(const std::string &name) const
}
else
{
- player_relations.setRelation(name, Relation::BLACKLISTED);
+ playerRelations.setRelation(name, Relation::BLACKLISTED);
}
}
@@ -661,4 +661,4 @@ bool PlayerRelationsManager::checkName(const std::string &name)
}
}
-PlayerRelationsManager player_relations;
+PlayerRelationsManager playerRelations;
diff --git a/src/being/playerrelations.h b/src/being/playerrelations.h
index ae2e08dae..c9e5952f2 100644
--- a/src/being/playerrelations.h
+++ b/src/being/playerrelations.h
@@ -206,8 +206,8 @@ class PlayerRelationsManager final
};
-extern PlayerRelationsManager player_relations; // singleton representation
- // of player relations
+extern PlayerRelationsManager playerRelations; // singleton representation
+ // of player relations
#endif // BEING_PLAYERRELATIONS_H