feat(Core/Commands): Gear (#7717)

This commit is contained in:
IntelligentQuantum
2021-09-12 14:49:14 +04:30
committed by GitHub
parent 1465a659ec
commit e6143a1efd
6 changed files with 83 additions and 2 deletions

View File

@@ -15207,3 +15207,25 @@ float Player::GetSightRange(const WorldObject* target) const
return sightRange;
}
std::string Player::GetPlayerName()
{
std::string name = GetName();
std::string color = "";
switch (getClass())
{
case CLASS_DEATH_KNIGHT: color = "|cffC41F3B"; break;
case CLASS_DRUID: color = "|cffFF7D0A"; break;
case CLASS_HUNTER: color = "|cffABD473"; break;
case CLASS_MAGE: color = "|cff69CCF0"; break;
case CLASS_PALADIN: color = "|cffF58CBA"; break;
case CLASS_PRIEST: color = "|cffFFFFFF"; break;
case CLASS_ROGUE: color = "|cffFFF569"; break;
case CLASS_SHAMAN: color = "|cff0070DE"; break;
case CLASS_WARLOCK: color = "|cff9482C9"; break;
case CLASS_WARRIOR: color = "|cffC79C6E"; break;
}
return "|Hplayer:" + name + "|h" + color + name + "|h|r";
}