How can I programm an abillity that is charging up by taking damage?

Hi,
I wanted to know how you would best approach the following game mechanics, as I haven’t found anything on YT that goes in this direction. I would use Unreal Engine 5.
I’m a complete beginner and don’t know any programming languages. :slight_smile:

Example of what I want to try:

Character is shot by an evil enemy.
The character takes damage. At the same time, a bar charges up.
Once the bar is charged, you can trigger the superhero power by pressing a button.

Thank you for the help :slight_smile:

You can create a variable ChargedSuper as type Float in your character bp.

Using either of these event: (you will need to some tuto on how to setup apply damage from enenmy side)
image

AnyDamage > Clamp Dmg > Normalised(in needed in %) > set to widget ui

The widget ui bar will need to have some custom event that you can call from your pcontroller, in order to update the bar.