Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(1 edit)

Really interesting idea, but the really annoying thing is that the restart button isn't working and I have to refresh the entire page, I manage to get to 5 quote an don the 5th I had 130 seconds.

Yeah I noticed restart wasn’t working just before I had to submit. I couldn’t figure it out before the submission time ended.

How you handle it(in code)?

(1 edit)

#in my game over script in the gameOver scene

var mainScene = preload(“scene.tscn”).instantiate()

func playAgain():

    get_tree().root.add_child(mainScene)

    self.queue_free()


#in the main scene 
var gameOverScene = preload(“gameOver.tscn”).instantiate()

func gameOver():

    get_tree().root.add_child(gameOverScene)

    mainScene.queue_free()

You can use https://docs.godotengine.org/en/stable/classes/class_scenetree.html#class-scenet...