mirror of
https://github.com/thecatontheceiling/buckshotroulette-decomp.git
synced 2024-11-25 15:07:21 +00:00
23 lines
654 B
GDScript3
23 lines
654 B
GDScript3
|
class_name DecisionTextManager extends Node
|
||
|
|
||
|
@export var textArray : Array[TextInteraction]
|
||
|
@export var colliderArray : Array[StaticBody3D]
|
||
|
@export var animator : AnimationPlayer
|
||
|
|
||
|
func _ready():
|
||
|
for i in range(colliderArray.size()):
|
||
|
colliderArray[i].collision_layer = 0
|
||
|
colliderArray[i].collision_mask = 0
|
||
|
|
||
|
func SetUI(state : bool):
|
||
|
if (state):
|
||
|
for i in range(colliderArray.size()):
|
||
|
colliderArray[i].collision_layer = 1
|
||
|
colliderArray[i].collision_mask = 1
|
||
|
animator.play("show text")
|
||
|
else:
|
||
|
for i in range(colliderArray.size()):
|
||
|
colliderArray[i].collision_layer = 0
|
||
|
colliderArray[i].collision_mask = 0
|
||
|
animator.play("hide text")
|