本文整理汇总了C++中aurora::LocString::empty方法的典型用法代码示例。如果您正苦于以下问题:C++ LocString::empty方法的具体用法?C++ LocString::empty怎么用?C++ LocString::empty使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类aurora::LocString
的用法示例。
在下文中一共展示了LocString::empty方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: loadProperties
void Creature::loadProperties(const Aurora::GFF3Struct &gff) {
// Tag
_tag = gff.getString("Tag", _tag);
// Name
Aurora::LocString firstName;
gff.getLocString("FirstName", firstName);
Aurora::LocString lastName;
gff.getLocString("LastName", lastName);
if (!firstName.empty()) {
_name = firstName.getString();
if (!lastName.empty())
_name += " " + lastName.getString();
}
// Description
_description = gff.getString("Description", _description);
// Portrait
loadPortrait(gff);
// Equipment
loadEquipment(gff);
// Appearance
_appearance = gff.getUint("Appearance_Type", _appearance);
// Static
_static = gff.getBool("Static", _static);
// Usable
_usable = gff.getBool("Useable", _usable);
// PC
_isPC = gff.getBool("IsPC", _isPC);
// Gender
_gender = Gender(gff.getUint("Gender"));
// Race
_race = Race(gff.getSint("Race", _race));
_subRace = SubRace(gff.getSint("SubraceIndex", _subRace));
// Hit Points
_currentHitPoints = gff.getSint("CurrentHitPoints", _maxHitPoints);
_maxHitPoints = gff.getSint("MaxHitPoints", _currentHitPoints);
_minOneHitPoint = gff.getBool("Min1HP", _minOneHitPoint);
// Faction
_faction = Faction(gff.getUint("FactionID"));
// Scripts
readScripts(gff);
_conversation = gff.getString("Conversation", _conversation);
}
示例2:
GTEST_TEST_F(LocString, empty) {
const Aurora::LocString locString;
EXPECT_TRUE(locString.empty());
}