Support for getting natures by index for iterating purposes.
This commit is contained in:
@@ -42,6 +42,11 @@ namespace PkmnLib::Library {
|
||||
}
|
||||
throw CreatureException("Nature not found.");
|
||||
}
|
||||
|
||||
size_t GetNatureCount() const noexcept { return _items.size(); }
|
||||
inline const ArbUt::StringView& GetNatureFromIndex(size_t index) const {
|
||||
return std::next(std::begin(_items), index)->first;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user