# Convert time to score

**URL:** <https://forum.makecode.com/t/convert-time-to-score/39898>\
**Category:** Help\
**Created:** [October 21, 2025, 3:45pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898 "2025-10-21T15:45:17Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Awesomefreez](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/awesomefreez/32/24832_2.png) [@Awesomefreez](https://forum.makecode.com/u/Awesomefreez)\
**Post date:** [October 21, 2025, 3:45pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/1 "2025-10-21T15:45:17Z")

</div>

For my Heist game jam game I want to add a scoring system for how quickly you finish a level.

I tried figuring out how you would do that but I don’t know what to do

Could someone help me Pls

---

<div class="post-metadata">

**Author:** ![Bilangus](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/bilangus/32/33219_2.png) [@Bilangus](https://forum.makecode.com/u/Bilangus)\
**Post date:** [October 21, 2025, 5:13pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/2 "2025-10-21T17:13:46Z")

</div>

You could assign the starting time to a variable and when you finish the level get score based on a set value minus the difference between start time and time remaining.

---

<div class="post-metadata">

**Author:** ![randomuser](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/randomuser/32/32505_2.png) [@randomuser](https://forum.makecode.com/u/randomuser)\
**Post date:** [October 21, 2025, 8:32pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/3 "2025-10-21T20:32:01Z")

</div>

![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/3X/2/0/206bd62563900be4b1d3992351be50983b161a93.png)  
Here’s a code version, very similar to @Bilangus 's answer!

---

<div class="post-metadata">

**Author:** ![MyCraft\_Steve](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/mycraft_steve/32/25707_2.png) [@MyCraft\_Steve](https://forum.makecode.com/u/MyCraft_Steve)\
**Post date:** [October 22, 2025, 6:51pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/4 "2025-10-22T18:51:46Z")

</div>

How ‘bout this?

 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/3X/5/4/54a8e4a89c504cc471e064b84941f7eb631c81f7.png)

---

<div class="post-metadata">

**Author:** ![Not-a-creepy-doll](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/not-a-creepy-doll/32/28255_2.png) [@Not-a-creepy-doll](https://forum.makecode.com/u/Not-a-creepy-doll)\
**Post date:** [October 22, 2025, 6:51pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/5 "2025-10-22T18:51:51Z")

</div>

Wow this is all really cool just one question, ARE THOSE COMMENT BLOCKS!!! how did you do that … _wizardry no doubt_

---

<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:** [October 22, 2025, 8:41pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/6 "2025-10-22T20:41:45Z")

</div>

How much you wanna bet there were splash blocks underneath those comments

Creating a comment is simple actually

In blocks, double click and pick the “add comment” option

In JavaScript, type // and type away.

---

<div class="post-metadata">

**Author:** ![randomuser](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/randomuser/32/32505_2.png) [@randomuser](https://forum.makecode.com/u/randomuser)\
**Post date:** [October 22, 2025, 8:41pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/7 "2025-10-22T20:41:48Z")

</div>

😆 Thank you!! Just right click on the block and there’s an option to add a comment, after that I moved them to cover up the random block they were attached to. It’s my attempt at recreating Javascript’s inline comments!

---

<div class="post-metadata">

**Author:** ![Not-a-creepy-doll](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/not-a-creepy-doll/32/28255_2.png) [@Not-a-creepy-doll](https://forum.makecode.com/u/Not-a-creepy-doll)\
**Post date:** [October 22, 2025, 9:39pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/8 "2025-10-22T21:39:31Z")

</div>

Ah, so it WAS WIZARDRY!!! But still a neat trick. I should honestly use the comment feature more often myself

---

<div class="post-metadata">

**Author:** ![TheEarth](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/theearth/32/34579_2.png) [@TheEarth](https://forum.makecode.com/u/TheEarth)\
**Post date:** [October 23, 2025, 2:38am UTC](https://forum.makecode.com/t/convert-time-to-score/39898/9 "2025-10-23T02:38:33Z")

</div>

you could just right click the code space and then drag it

---

<div class="post-metadata">

**Author:** ![Awesomefreez](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/awesomefreez/32/24832_2.png) [@Awesomefreez](https://forum.makecode.com/u/Awesomefreez)\
**Post date:** [October 27, 2025, 5:00pm UTC](https://forum.makecode.com/t/convert-time-to-score/39898/10 "2025-10-27T17:00:03Z")

</div>

thank you
