23 lines
888 B
GDScript
23 lines
888 B
GDScript
extends Node3D
|
|
|
|
@onready var floating_text_component: FloatingComponent = %FloatingTextComponent
|
|
var current_displayed_text : String = ""
|
|
|
|
func _ready() -> void:
|
|
floating_text_component.set_text(tr("FLOAT_TEXT"))
|
|
floating_text_component.emit_spawn_text.emit()
|
|
await get_tree().create_timer(33.0).timeout
|
|
$start_btn.visible = true
|
|
|
|
|
|
func _on_area_3d_input_event(camera: Node, event: InputEvent, event_position: Vector3, normal: Vector3, shape_idx: int) -> void:
|
|
if event is InputEventMouseButton:
|
|
if event.button_index == MOUSE_BUTTON_LEFT:
|
|
get_tree().change_scene_to_file("res://ai_act_text.tscn")
|
|
|
|
|
|
func _on_start_btn_input_event(camera: Node, event: InputEvent, event_position: Vector3, normal: Vector3, shape_idx: int) -> void:
|
|
if event is InputEventMouseButton:
|
|
if event.button_index == MOUSE_BUTTON_LEFT:
|
|
get_tree().change_scene_to_file("res://star_animation.tscn")
|