Return item name by reference instead of value.
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
cc46cd46a7
commit
15523a18a5
@ -19,7 +19,7 @@ namespace CreatureLib::Library {
|
|||||||
Item(std::string name, ItemCategory category, BattleItemCategory battleCategory, int32_t price,
|
Item(std::string name, ItemCategory category, BattleItemCategory battleCategory, int32_t price,
|
||||||
std::unordered_set<std::string> flags);
|
std::unordered_set<std::string> flags);
|
||||||
|
|
||||||
inline const std::string GetName() const { return _name; }
|
inline const std::string& GetName() const { return _name; }
|
||||||
inline ItemCategory GetCategory() const { return _category; }
|
inline ItemCategory GetCategory() const { return _category; }
|
||||||
inline BattleItemCategory GetBattleCategory() const { return _battleCategory; }
|
inline BattleItemCategory GetBattleCategory() const { return _battleCategory; }
|
||||||
inline const int32_t GetPrice() const { return _price; }
|
inline const int32_t GetPrice() const { return _price; }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user