From edf2381028f6643637d788c9e40bfa12681608cd Mon Sep 17 00:00:00 2001 From: Logan Date: Mon, 15 May 2023 05:49:19 -0600 Subject: Fix physics sleep preventing ball position reset --- scripts/basketball.gd | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/basketball.gd b/scripts/basketball.gd index 57c211c..9b0f72b 100644 --- a/scripts/basketball.gd +++ b/scripts/basketball.gd @@ -37,6 +37,7 @@ func toggle_mode(): $GhostSprite.visible = false $Sprite2D.position = Vector2(0, 0) else: + sleeping = false # Adds offset of ball's rotation to sprite AFTER the entire object has rotated from physics. # Done to keep appearance of same rotation to add consistency when resetting the ball. $Sprite2D.rotation += rotation -- cgit v1.2.3