This repository has been archived on 2024-09-30. You can view files and clone it, but cannot push or open issues/pull-requests.
gbjam12/puzzles/button_puzzle.gd

16 lines
249 B
GDScript
Raw Normal View History

class_name ButtonPuzzle
extends Puzzle
@export var buttons: Array[GroundButton] = []
func _process(delta):
var is_finished = true
for button in buttons:
if !button.is_active:
is_finished = false
break;
if is_finished:
complete()