This site is currently in read-only mode during migration to a new platform.
You cannot post questions, answers or comments, as they would be lost during the migration otherwise.
+1 vote

Hey how do i reset control node while switching scene's
like from gameover scene to World scene
In my project when my player hp reaches 0 it switches to gameover scene then when i press restart button with get_tree().change_scene("res://Node2D.tscn") this simple code
it changes scene, But My playerhp is still in 0
setters is used for playerhp, any solution?

Godot version 3.2.3
in Engine by (56 points)

2 Answers

0 votes
by (646 points)

thats because he asked the question twice. Look - exactly the same user.

So the idea was not to answer this question but the one I linked to ;-)

0 votes

In order to restart a scene, you must use


You do not require to put the scene name in the brackets as the code auto-detects the scene. I hope this helped!

by (309 points)

hey did u read my question properly my question is "like from gameover scene to World scene"?
im using a seperate scene to display "gameover"
Any solution for this?

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.