Inline nature functions.
continuous-integration/drone/push Build is failing
Details
continuous-integration/drone/push Build is failing
Details
This commit is contained in:
parent
6b704224d0
commit
c5df576dde
|
@ -11,23 +11,23 @@ namespace PkmnLib::Library {
|
|||
float _decreaseModifier;
|
||||
|
||||
public:
|
||||
Nature()
|
||||
Nature() noexcept
|
||||
: _increaseStat(CreatureLib::Library::Statistic::Health),
|
||||
_decreaseStat(CreatureLib::Library::Statistic::Health), _increaseModifier(1.0f), _decreaseModifier(1.0f) {
|
||||
}
|
||||
|
||||
Nature(CreatureLib::Library::Statistic increasedStat, CreatureLib::Library::Statistic decreasedStat,
|
||||
float increasedModifier = 1.1f, float decreasedModifier = 0.9f)
|
||||
float increasedModifier = 1.1f, float decreasedModifier = 0.9f) noexcept
|
||||
: _increaseStat(increasedStat), _decreaseStat(decreasedStat), _increaseModifier(increasedModifier),
|
||||
_decreaseModifier(decreasedModifier) {}
|
||||
|
||||
[[nodiscard]] float GetIncreaseModifier() const { return _increaseModifier; }
|
||||
[[nodiscard]] float GetDecreaseModifier() const { return _decreaseModifier; }
|
||||
[[nodiscard]] inline float GetIncreaseModifier() const noexcept { return _increaseModifier; }
|
||||
[[nodiscard]] inline float GetDecreaseModifier() const noexcept { return _decreaseModifier; }
|
||||
|
||||
[[nodiscard]] CreatureLib::Library::Statistic GetIncreasedStat() const { return _increaseStat; }
|
||||
[[nodiscard]] CreatureLib::Library::Statistic GetDecreasedStat() const { return _decreaseStat; }
|
||||
[[nodiscard]] inline CreatureLib::Library::Statistic GetIncreasedStat() const noexcept { return _increaseStat; }
|
||||
[[nodiscard]] inline CreatureLib::Library::Statistic GetDecreasedStat() const noexcept { return _decreaseStat; }
|
||||
|
||||
[[nodiscard]] float GetStatModifier(CreatureLib::Library::Statistic stat) const {
|
||||
[[nodiscard]] inline float GetStatModifier(CreatureLib::Library::Statistic stat) const noexcept {
|
||||
if (stat == _increaseStat)
|
||||
return _increaseModifier;
|
||||
else if (stat == _decreaseStat)
|
||||
|
|
Loading…
Reference in New Issue