This commit is contained in:
parent
4a31db6411
commit
88c05bbd8c
21 changed files with 194 additions and 75 deletions
11
pause_game.gd
Normal file
11
pause_game.gd
Normal file
|
@ -0,0 +1,11 @@
|
|||
extends Control
|
||||
|
||||
func _input(event):
|
||||
if event.is_action_pressed("pause"):
|
||||
get_tree().paused = not get_tree().paused
|
||||
visible = not visible
|
||||
if get_tree().paused:
|
||||
get_parent().paused.emit()
|
||||
else:
|
||||
get_parent().unpaused.emit()
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue