# How to make a game end when timer runs out?

**URL:** <https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862>\
**Category:** Blueprint\
**Tags:** timer, unreal-engine, UE4, Blueprint, question\
**Created:** [August 25, 2017, 9:38pm UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862 "2017-08-25T21:38:48Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![valval1128](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@valval1128](https://forums.unrealengine.com/u/valval1128)\
**Post date:** [August 25, 2017, 9:38pm UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/1 "2017-08-25T21:38:48Z")

</div>

How do we make the game end when the timer runs out? we can’t seem to figure out a simple way of doing this using blue prints.

---

<div class="post-metadata">

**Author:** ![cmarston74](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@cmarston74](https://forums.unrealengine.com/u/cmarston74)\
**Post date:** [August 25, 2017, 10:17pm UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/2 "2017-08-25T22:17:17Z")

</div>

Two options set a timer in your game mode that will trigger an event after a set amount of time. Or track elapsed time by summing the DeltaTime values in OnTick. Test for elapsed time greater than your desired match time then end match if true.

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 17, 2026, 10:14am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/3 "2026-03-17T10:14:09Z")

</div>

And how do we set a timer that triggers the game to quit in the gamemode?

---

<div class="post-metadata">

**Author:** ![VKittyCat2022](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/vkittycat2022/32/1149005_2.png) [@VKittyCat2022](https://forums.unrealengine.com/u/VKittyCat2022)\
**Post date:** [March 18, 2026, 5:23pm UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/4 "2026-03-18T17:23:58Z")

</div>

If you mean quit to menu, just open whichever level is your menu. If you mean quit the game entirely, just use the quit game node, like so:

 ![Screenshot (88)](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/7/d/07d98962acfb6474c243fff5ae91b3018c9d2ea3.png)

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 19, 2026, 10:48am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/5 "2026-03-19T10:48:40Z")

</div>

Nice, could you show me a screenshot of a countdown timer with it quitting the game entirely please? I’m still trying to figure this out.

Thanks.

---

<div class="post-metadata">

**Author:** ![VKittyCat2022](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/vkittycat2022/32/1149005_2.png) [@VKittyCat2022](https://forums.unrealengine.com/u/VKittyCat2022)\
**Post date:** [March 19, 2026, 5:49pm UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/6 "2026-03-19T17:49:26Z")

</div>

This quits the game after five seconds:

 ![Screenshot (90)](https://d3kjluh73b9h9o.cloudfront.net/original/4X/b/3/0/b3085f96284a2a98826b181376116d17ddc75b7c.png)

If you want to display the remaining time on screen, you then need to add this in a widget blueprint:

 ![Screenshot (94)](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/4/e/04eb91170b6cafa4b8062a71a66126119559c2f8.png)

It updates a variable every second, which you then need to link to a text:

 ![Screenshot (91)](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/0/6/706396ac3f9d5de54dc34dae9f908572f0ea2056.png)

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 23, 2026, 9:33am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/7 "2026-03-23T09:33:58Z")

</div>

What are the other nodes before the quit game node in the first screenshot? I see it connecting to something off-screen but what is it?

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 23, 2026, 9:58am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/8 "2026-03-23T09:58:20Z")

</div>

And if I may ask, what type of blueprint class is that quit game node in?

---

<div class="post-metadata">

**Author:** ![VKittyCat2022](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/vkittycat2022/32/1149005_2.png) [@VKittyCat2022](https://forums.unrealengine.com/u/VKittyCat2022)\
**Post date:** [March 23, 2026, 7:42pm UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/9 "2026-03-23T19:42:07Z")

</div>

The off screen connection is just to whatever event starts the timer. It could be BeginPlay or something else.

It’s in a player pawn, but you could put it in anything that’s in your world(player controller, gamemode, even a random actor.)

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 24, 2026, 9:26am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/10 "2026-03-24T09:26:22Z")

</div>

Yeah, I don’t know about this. A shame there isn’t a video on a timer like this. I really need an in-depth video guide on this please.

I tried searching on youtube and there isn’t a single video about a timer that ends the game without a menu.

Blueprints aren’t really my strong-suit.

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 24, 2026, 9:31am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/11 "2026-03-24T09:31:47Z")

</div>

On a related note, I only remade a timer that Fcb Dev made since that one is the simplest by far. It’s only a user widget blueprint as far as I know.

---

<div class="post-metadata">

**Author:** ![VKittyCat2022](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/vkittycat2022/32/1149005_2.png) [@VKittyCat2022](https://forums.unrealengine.com/u/VKittyCat2022)\
**Post date:** [March 25, 2026, 4:19pm UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/12 "2026-03-25T16:19:00Z")

</div>

This video explains timers:

[https://www.youtube.com/watch?v=W4VrlNK8fj0](https://www.youtube.com/watch?v=W4VrlNK8fj0)

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 26, 2026, 9:31am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/13 "2026-03-26T09:31:51Z")

</div>

Didn’t really help but thanks anyway.

---

<div class="post-metadata">

**Author:** ![TeknoStyle555](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TeknoStyle555](https://forums.unrealengine.com/u/TeknoStyle555)\
**Post date:** [March 30, 2026, 9:46am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/14 "2026-03-30T09:46:44Z")

</div>

I actually figured it out, it’s much simpler than I thought, literally a no-brainer.

This Event BeginPlay node goes into a Set Time By Event node, which gives it 60 seconds. It then fires off into a custom event that tells it that this event only has a minute. Once those 60 seconds have elapsed, the game quits.

Other people may have their own way of doing it but this worked for me. I did it in the character blueprint.

 ![Screenshot (682)](https://d3kjluh73b9h9o.cloudfront.net/original/4X/a/f/6/af62f391e52eb43976778d3cddd1128c4e826d52.png)

---

<div class="post-metadata">

**Author:** ![usa423](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/usa423/32/918773_2.png) [@usa423](https://forums.unrealengine.com/u/usa423)\
**Post date:** [April 3, 2026, 5:35am UTC](https://forums.unrealengine.com/t/how-to-make-a-game-end-when-timer-runs-out/402862/15 "2026-04-03T05:35:33Z")

</div>

That seems to be the thing with Unreal, so many ways to do the same things.
