I’m probably overthinking it, but I’m having a hard time figuring out how to make an experience based leveling system for my game. I have made the system that actually stores and increments the experience, but I can’t get it work based on things that happen in the world. It works, at the moment, based on user input such as pressing the “fire” button.
I would use the player controller class to update the player state class with the experience level of the player. You can update it in the player controller via custom events.
So, when an actor in the world wants to generate a player level increase, you get player controller->cast to your player controller class->call the custom event.
It should ultimately be the player controller’s responsibility to increase (or not) the player experience level, not actors in the world though.
There is a tonne of youtube videos on setting this type of thing up and a lot of tutorials posted up in this forum already explaining this type of thing. Just do a search and you will find it out pretty easily.
I helped someone out before with this in the following thread: Xp Bar Help. - Blueprint Visual Scripting - Unreal Engine Forums.
This can get you started at least
This tutorial works pretty well! [OUTDATED]How to make an advanced RPG in Unreal Engine 4 [Ep 17 How to make XP bar] - YouTube