summaryrefslogtreecommitdiff
path: root/src/being/being.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-05-30 17:45:27 +0300
committerAndrei Karas <akaras@inbox.ru>2015-05-30 17:45:27 +0300
commitaadf40739c45c3396ace5766dd9c60db0c3b1ccc (patch)
treea6d2ca5fb86849ae18586b728bfcd9e716f5635f /src/being/being.cpp
parent2a33b736dc93251bf7a72364c5f818142362a3ce (diff)
downloadmv-aadf40739c45c3396ace5766dd9c60db0c3b1ccc.tar.gz
mv-aadf40739c45c3396ace5766dd9c60db0c3b1ccc.tar.bz2
mv-aadf40739c45c3396ace5766dd9c60db0c3b1ccc.tar.xz
mv-aadf40739c45c3396ace5766dd9c60db0c3b1ccc.zip
Move relation enum into separate file.
Diffstat (limited to 'src/being/being.cpp')
-rw-r--r--src/being/being.cpp23
1 files changed, 8 insertions, 15 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index ddd0e7473..e30a1e477 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -2005,11 +2005,8 @@ void Being::showName()
delete2(mDispName);
- if (mHideErased && player_relations.getRelation(mName) ==
- PlayerRelation::ERASED)
- {
+ if (mHideErased && player_relations.getRelation(mName) == Relation::ERASED)
return;
- }
std::string displayName(mName);
@@ -2079,7 +2076,7 @@ void Being::updateColors()
{
mTextColor = &theme->getColor(ThemeColorId::PLAYER, 255);
- if (player_relations.getRelation(mName) != PlayerRelation::ERASED)
+ if (player_relations.getRelation(mName) != Relation::ERASED)
mErased = false;
else
mErased = true;
@@ -2103,27 +2100,23 @@ void Being::updateColors()
{
mNameColor = &userPalette->getColor(UserColorId::GUILD);
}
- else if (player_relations.getRelation(mName) ==
- PlayerRelation::FRIEND)
+ else if (player_relations.getRelation(mName) == Relation::FRIEND)
{
mNameColor = &userPalette->getColor(UserColorId::FRIEND);
}
else if (player_relations.getRelation(mName) ==
- PlayerRelation::DISREGARDED
+ Relation::DISREGARDED
|| player_relations.getRelation(mName) ==
- PlayerRelation::BLACKLISTED)
+ Relation::BLACKLISTED)
{
mNameColor = &userPalette->getColor(UserColorId::DISREGARDED);
}
- else if (player_relations.getRelation(mName) ==
- PlayerRelation::IGNORED
- || player_relations.getRelation(mName) ==
- PlayerRelation::ENEMY2)
+ else if (player_relations.getRelation(mName) == Relation::IGNORED
+ || player_relations.getRelation(mName) == Relation::ENEMY2)
{
mNameColor = &userPalette->getColor(UserColorId::IGNORED);
}
- else if (player_relations.getRelation(mName) ==
- PlayerRelation::ERASED)
+ else if (player_relations.getRelation(mName) == Relation::ERASED)
{
mNameColor = &userPalette->getColor(UserColorId::ERASED);
}