MCPcopy Create free account
hub / github.com/diasurgical/DevilutionX / GetObjectStr

Function GetObjectStr

Source/objects.cpp:4995–5008  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4993}
4994
4995void GetObjectStr(const Object &object)
4996{
4997 InfoString = object.name();
4998 if (MyPlayer->_pClass == HeroClass::Rogue) {
4999 if (object._oTrapFlag) {
5000 InfoString = fmt::format(fmt::runtime(_(/* TRANSLATORS: {:s} will either be a chest or a door */ "Trapped {:s}")), InfoString.str());
5001 InfoColor = UiFlags::ColorRed;
5002 }
5003 }
5004 if (object.IsDisabled()) {
5005 InfoString = fmt::format(fmt::runtime(_(/* TRANSLATORS: If user enabled diablo.ini setting "Disable Crippling Shrines" is set to 1; also used for Na-Kruls lever */ "{:s} (disabled)")), InfoString.str());
5006 InfoColor = UiFlags::ColorRed;
5007 }
5008}
5009
5010void SyncNakrulRoom()
5011{

Callers 1

DrawInfoBoxFunction · 0.85

Calls 4

formatFunction · 0.85
strMethod · 0.80
IsDisabledMethod · 0.80
nameMethod · 0.45

Tested by

no test coverage detected