Gradually increase score on death UMG

Hey all, I’m a bit of a beginner in UE 4 so excuse me if you don’t understand what I’m talking about.

So I’ve made a game based on the Endless Runner tutorials found here -
https://docs.unrealengine.com/latest/INT/Videos/PLZlv_N0_O1gbY4FN8pZuEPVC9PzQThNn1/

I have made a death UMG that is added to the viewport when the character dies. I have numbers on the death screen that will display the players distance and the players total amount of coins (both of which I already have an existing variable for). However, I don’t want these numbers to just appear, I would like them to gradually increase (an example of this can be found in this users video, https://www.youtube.com/watch?v=4t-t4MJdWws. When the character dies, instead of the numbers just appearing, they gradually increase)

Does anyone know how to blueprint this??

I’ve tried that but because a tick is so fast, the score is added pretty much instantly, unlike how it is shown in the video linked in my first post.

I will screenshot the code I have done later when I get back on UE 4

I’m not too familiar with timelines but wouldn’t this produce decimal numbers?

Does anyone have a screenshot of the code that will do something like the death screen for the video linked in my original post?

It’s really like you would think. You just count another variable to your score until it reaches your score, preferably every tick. To make things go faster, you just add by a higher number and if this variable goes over your score, you just set the variable like your score. Yes, it’s simple like that. <3

Here is something even better. Use a timeline, make it go from 0-1. Multiply your score with that. Change the length of your timeline whatever you feel like.

You can just use trunc and convert to int.

I don’t think timelines are not available in UMG so if your logic is there it wont work… Just replace the tick function with a simple Timer by FunctionName node and call it as often as you need it to happen, then clear the timer(or don’t call it again) when you reach max.

That’s the wrong way, you have to show your code first, to show other people that you actually tried it. Now, you just sound like you want other people to code for you :expressionless: