瀏覽代碼

Remove focus from restart button, fixes #1850

Fixes a problem where the restart button would keep focus after being pressed, making the tetris' pieces impossible to rotate without activating the button again.
Nicolas Laurito 10 年之前
父節點
當前提交
862b9a50f7
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      2d/tetris/grid.gd

+ 1 - 0
2d/tetris/grid.gd

@@ -143,6 +143,7 @@ func restart_pressed():
 		cells.clear()
 		cells.clear()
 		get_node("gameover").set_text("")		
 		get_node("gameover").set_text("")		
 		piece_active=true
 		piece_active=true
+		get_node("../restart").release_focus()
 		update()
 		update()