Default statistics system
A default statistics system can be enabled in your plugin configuration.
See the below links:
The default statistics system saves only wins and loses.
How to enable the default stats system?
Set useDefaultStatsSystem to true in your PluginConfiguartion.
How to add stats to users?
Stats can be added in two different ways:
When something is changed maybe the player has won the game.
Create a new user or get
Add stat
When the game ended.
The second way is the same but the method is called when the game is ended, maybe in the class which calls GameWinState.
Remember that stats must be saved in your UserGame object.