mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-27 22:49:25 +02:00
Use toEntity/toXXX methods in Identifier instead VLC objects access
This commit is contained in:
@@ -775,7 +775,7 @@ std::string CGKeys::getHoverText(PlayerColor player) const
|
||||
|
||||
std::string CGKeys::getObjectName() const
|
||||
{
|
||||
return VLC->generaltexth->tentColors[subID] + " " + CGObjectInstance::getObjectName();
|
||||
return VLC->generaltexth->tentColors[subID.getNum()] + " " + CGObjectInstance::getObjectName();
|
||||
}
|
||||
|
||||
bool CGKeymasterTent::wasVisited (PlayerColor player) const
|
||||
@@ -810,7 +810,7 @@ void CGBorderGuard::getRolloverText(MetaString &text, bool onHover) const
|
||||
{
|
||||
if (!onHover)
|
||||
{
|
||||
text.appendRawString(VLC->generaltexth->tentColors[subID]);
|
||||
text.appendRawString(VLC->generaltexth->tentColors[subID.getNum()]);
|
||||
text.appendRawString(" ");
|
||||
text.appendRawString(VLC->objtypeh->getObjectName(Obj::KEYMASTER, subID));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user