Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » How do I make an option to restart the game?
- Maryrosetwo
-
1 post
How do I make an option to restart the game?
I am bit new and I will appreciate the help.

- AbracaDoodle
-
10 posts
How do I make an option to restart the game?
Hey @Maryrosetwo!
So, to make an option to restart the game, it would probably be most practical make a custom block. Here's an example:
Then, when you wanted the game to restart, it would go something like this:
A quick note, in the Scratch Editor the “Restart Game” custom block will be dark purple, not red.
Anyway, hope I could help!
Sincerely,
Doodle
So, to make an option to restart the game, it would probably be most practical make a custom block. Here's an example:
Then, when you wanted the game to restart, it would go something like this:
A quick note, in the Scratch Editor the “Restart Game” custom block will be dark purple, not red.

Sincerely,
Doodle
- Aronix
-
77 posts
How do I make an option to restart the game?
Well this is a tricky topic, in order to "restart“ a game it depends on what is in use in the project at the time of ”death“. It also depends what you want to happen after death, you could just go back to the menu (If there is one) or you could have an entire death screen dedicated to the death of the player. But just so I don't end up writing 10 paragraphs including what to do in every scenario, we'll just say you have a start screen. And on this start screen you have fully functional Play button, How To Play button, and High Score button, all leading to separate menus containing the intended information/data. And this point, when you click the ”Play“ (on the stat screen) button it takes you into the game, and then you die/lose the game. In order to properly ”restart“ or ”reset" the project you must summon -all- the proper sprites/assets/variables in order to make it seem (at least to the project) as if it never happened. And everything's back to normal. This means resetting the necessary variables, showing the correct sprites, & deleting clones, ect. Whatever is needed to simulate a proper start screen without any of the game assets being active. This is important because having assets that aren't supposed to be active, active leads to unwanted bugs. And bugs aren't fun to fix, or have. If your still having trouble understanding, you can message me on my profile, i'm glad to help. 

- Mrkrabsfanboy
-
3 posts
How do I make an option to restart the game?
how do i get that red code block?
- deck26
-
1000+ posts
How do I make an option to restart the game?
You don't. Red blocks appear in the forum because Scratchblocks doesn't understand them. Usually the person helping means ‘insert your own code here’. how do i get that red code block?
- --_Nova_--
-
1000+ posts
How do I make an option to restart the game?
If you broadcast something like init under a when gf clicked block and had the sprites get ready under that broadcast, you could use the broadcast as a forced gf click or use the broadcast to reset the sprites. You would have to replace every gf clicked block with when I recieve (except the gf script that broadcasts it).
Example:
If as Aronix said you had a start screen the play button would broadcast it when clicked and could be reset that way.
EDIT: oh wait this topic was necro'd
Example:
If as Aronix said you had a start screen the play button would broadcast it when clicked and could be reset that way.
EDIT: oh wait this topic was necro'd
Last edited by --_Nova_-- (Sept. 4, 2018 23:27:43)
- deck26
-
1000+ posts
How do I make an option to restart the game?
Please don't necropost or post when you have nothing useful to add. i don't know?
- 1063946student
-
5 posts
How do I make an option to restart the game?
I am making a platformer and I don´t know how to reset the level. Can you show me an actual script that I can use? Thank you! If you do so then you. 

- Nezon
-
1000+ posts
How do I make an option to restart the game?
Create your own topic, and please don't necropost. I am making a platformer and I don´t know how to reset the level. Can you show me an actual script that I can use? Thank you! If you do so then you.
an actual script is really easy.
- 1063946student
-
5 posts
How do I make an option to restart the game?
What I mean is when my player die, I want him to reset the level that it was on.
- CoolCrafter1231
-
100+ posts
How do I make an option to restart the game?
i would suggest making a new topic to get more people to answer
- utbotiand123
-
1 post
How do I make an option to restart the game?
Hello Everyone!
Im making a project and i need a bit help… My game is insperd by Flappybirds and i want to make a Restart/reset button when you die but can´t figure out how to do it. Here is a link to the project: https://scratch.mit.edu/projects/847400813/
All help Apriciated
/utbotiand
Im making a project and i need a bit help… My game is insperd by Flappybirds and i want to make a Restart/reset button when you die but can´t figure out how to do it. Here is a link to the project: https://scratch.mit.edu/projects/847400813/
All help Apriciated
/utbotiand
- Paddle2See
-
1000+ posts
How do I make an option to restart the game?
It would be best if you made your own topic for this question so the conversation doesn't get too confused. Hello Everyone!
Im making a project and i need a bit help… My game is insperd by Flappybirds and i want to make a Restart/reset button when you die but can´t figure out how to do it. Here is a link to the project: https://scratch.mit.edu/projects/847400813/
All help Apriciated
/utbotiand
- Discussion Forums
- » Help with Scripts
-
» How do I make an option to restart the game?