# Game Unexpectedly Freezes when time's up

**URL:** <https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774>\
**Category:** Help\
**Created:** [May 1, 2026, 7:29pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774 "2026-05-01T19:29:50Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 1, 2026, 7:29pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/1 "2026-05-01T19:29:50Z")

</div>

In my Game Jam game, when time’s up, everything unexpectedly freezes and turns black. I’m not finished with the whole ending yet, but I at least need to fix this bug first. Please Help!!

> **[real Bird Run: Football Renegade](https://arcade.makecode.com/S59503-41870-31342-33610)**
>
> uhh a game i guess

---

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 2, 2026, 3:48am UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/2 "2026-05-02T03:48:05Z")

</div>

For clarification, when the time’s up, the game lags a bit, then the Time’s Up!! text appears very briefly before the screen turn entirely black. It lags a lot there during the events.  
Please I need help quick!! Got to get this in before the game jam deadline, you know what I’m saying? Heheh… 😅  
(_Actually tho please help!!_)

---

<div class="post-metadata">

**Author:** ![OrigamiArtist](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/origamiartist/32/33299_2.png) [@OrigamiArtist](https://forum.makecode.com/u/OrigamiArtist)\
**Post date:** [May 2, 2026, 6:52pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/3 "2026-05-02T18:52:28Z")

</div>

There is a glitch where the ball repeatedly throws itself at player 2’s goal.

 ![Screenshot 2026-05-02 09.03.47](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/3X/8/7/87609da75b7be1ff5d08dd6d0e0640c74ffff889.png)

---

<div class="post-metadata">

**Author:** ![OrigamiArtist](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/origamiartist/32/33299_2.png) [@OrigamiArtist](https://forum.makecode.com/u/OrigamiArtist)\
**Post date:** [May 2, 2026, 6:52pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/4 "2026-05-02T18:52:32Z")

</div>

Also when player 1 scores its worth 1 points, but when player 2 scores its worth 3 or 2 points

---

<div class="post-metadata">

**Author:** ![redSprite](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/redsprite/32/34262_2.png) [@redSprite](https://forum.makecode.com/u/redSprite)\
**Post date:** [May 2, 2026, 6:59pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/5 "2026-05-02T18:59:36Z")

</div>

Your using the `Pause()` function to wait between intervals. Which causes the lag.  
You can use the timer extension or the JavaScript function `setTimeout()` instead.

---

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 3, 2026, 12:33am UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/6 "2026-05-03T00:33:23Z")

</div>

What? The ball always starts at the middle!!

---

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 3, 2026, 12:39am UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/7 "2026-05-03T00:39:15Z")

</div>

Think I can fix that.

---

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 3, 2026, 12:39am UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/8 "2026-05-03T00:39:21Z")

</div>

Yeah I see that now. @redSprite you fixed the lag error, can you fix this one too! Would help alot, thanks!

---

<div class="post-metadata">

**Author:** ![redSprite](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/redsprite/32/34262_2.png) [@redSprite](https://forum.makecode.com/u/redSprite)\
**Post date:** [May 3, 2026, 3:02am UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/9 "2026-05-03T03:02:38Z")

</div>

I’m pretty sure the bug comes from the sprite hitting multiple tiles simultaneously within one frame, causing multiple points to be awarded.  
I _guess_ you could have it ghost through tiles until it gets reset to the middle of the screen.

---

<div class="post-metadata">

**Author:** ![OrigamiArtist](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/origamiartist/32/33299_2.png) [@OrigamiArtist](https://forum.makecode.com/u/OrigamiArtist)\
**Post date:** [May 3, 2026, 4:18pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/10 "2026-05-03T16:18:51Z")

</div>

Maybe make it go to random areas?

---

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 4, 2026, 7:11pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/11 "2026-05-04T19:11:56Z")

</div>

Then it might start on one of the goals

---

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 4, 2026, 11:40pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/12 "2026-05-04T23:40:55Z")

</div>

How do I do that? What do you mean by that? Whenever the football ghosts and stuff, it never collects the points.

---

<div class="post-metadata">

**Author:** ![OrigamiArtist](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/origamiartist/32/33299_2.png) [@OrigamiArtist](https://forum.makecode.com/u/OrigamiArtist)\
**Post date:** [May 4, 2026, 11:54pm UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/13 "2026-05-04T23:54:56Z")

</div>

Make the code to place it beyond the box, but I will help after the game jam, don’t worry for now.. 🙂

---

<div class="post-metadata">

**Author:** ![RoboVacDev](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robovacdev/32/29619_2.png) [@RoboVacDev](https://forum.makecode.com/u/RoboVacDev)\
**Post date:** [May 5, 2026, 3:04am UTC](https://forum.makecode.com/t/game-unexpectedly-freezes-when-times-up/43774/14 "2026-05-05T03:04:52Z")

</div>

That didn’t work.  
Maybe @WoofWoof can help?
