
With this system you can easily implement Stats (aka Attributes) and Modifiers in your game. Keep Stat Modifiers organized and applying in a consistent way.v2.0 Update Notice:Eliminated ALL allocations from Adding, Removing and instantiating StatModifiers.The only thing that should allocate now is instantiating CharacterStats.Changed StatModifier from a class to a struct.This should not negatively affect most users. However, it could impact you depending on your usage patterns.Whether you want to modify your stat by +5, +10% or -27.5%, this system keeps it all neatly organized and accurately calculates the stat's value.Just declare a CharacterStat variable, set its BaseValue, and then AddModifier() to your heart's content.Get the stat's final value from the Value property.Mix and match flat and percentual modifiers in any order you want:1) For a base value of 10, add +100 and +10% modifiers for a total of 121. Or reverse the order of calculation to get a total of 111. (Independent of when they are gained in-game)2) Add two 50% modifiers stacking additively for a total of +100%. Or make them stack multiplicatively for a total of +125%.3) Do whatever the heck you want! Full source code included. All classes are fully extendable: all variables are protected or public; all methods are virtual.The package consists of two main scripts: CharacterStat and StatModifier. There's also a few example scenes included.YouTube Channel: youtube.com/c/kryzarelOther Links:Discord Channel - Contact me directly.Character Stats YouTube Tutorial - How to implement this asset from scratch.Character Stats Text Tutorial - Text version of the same tutorial.Fantasy Icon Pack By Ravenmore:Author's site: http://dycha.netDownloaded from: OpenGameArtUnder license: CC BY 3.0