road-rage-tank/buildings/building_behavior.gd

6 lines
176 B
GDScript

extends Node
func _ready() -> void:
var idx := randi_range(0, %Shaker.get_child_count() - 1)
for child in %Shaker.get_children():
child.visible = child.get_index() == idx