Hello, I have implemented a time trial for a racing game but the problem when the player crosses the finish line the timer continues to run in the background this is an inconvenance because I made a win widget and a game over widget.
For the victory widget I made an actor blueprint (BP_Finish Line) with a collision box that when the player touches the box the victory widget appears on the screen.
For the Game over widget I made it appear on the screen when the timer reaches 0.
The timer continues to rotate in the background after the player crosses the line which normally displays the victory widget on the screen but as the timer continues to rotate in the background this gives this kind of situation…
I am having a near identical issue with a game I am building. After looking at the screenshots of your blueprints, which are very similar to mine, I am wondering if there is something missing. One person suggested using “Clear Timer by Function Name”; however, this requires the “timer process” to have a function name or event name to which I am bereft in my understanding of how to apply. I am eager to hear of any solutions you find to our common problem.
After several reflections I decided to try to use Set Timer by Event so I created an event that will count the minutes and seconds but for the Game Over and stop the timer I have no idea how to do.
I try with another method using the set timer by function name the timer works but the problem is the condition to trigger the game over because I don’t know if I should do a function or use the branch ?
For the BP the finish line I chose to use the function Clear Timer by function name however I still have the same problem when the player crosses the finish line the timer continues to run and the game over is triggered while the player is supposed to have won so that is what must-I do?
I am assuming these are the cars that finish the race, right? So you’re asking the car to stop the timer it does not have. If it’s the controller that is running the function, ask it to stop it:
I adopted the method you recommended for the timer and then I changed the code in the BP finish line by asking the car to stop the timer and I also tested in the viewport and it works.