poursuite de la finition de l'introduction
This commit is contained in:
+25
-4
@@ -1,19 +1,40 @@
|
||||
extends CanvasLayer
|
||||
|
||||
@onready var text_container = $MarginContainer/TextContainer
|
||||
@onready var intro_text_container = $MarginContainer/IntroBoxContainer/TextContainer
|
||||
@onready var skip = $SkipContainer/SkipButton
|
||||
|
||||
signal slide_finished
|
||||
signal on_skip_request
|
||||
signal on_transition_finished
|
||||
|
||||
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
func _ready() -> void:
|
||||
skip.pressed.connect(_on_skip_pressed)
|
||||
self.connect("on_skip_request", _on_skip_request)
|
||||
|
||||
pass # Replace with function body.
|
||||
self.hide()
|
||||
for node in intro_text_container.get_children():
|
||||
node.hide()
|
||||
|
||||
|
||||
|
||||
func _on_skip_pressed():
|
||||
slide_finished.emit()
|
||||
if Globals.is_transitioning == false:
|
||||
on_skip_request.emit()
|
||||
else:
|
||||
pass
|
||||
|
||||
|
||||
func _input(event):
|
||||
if event is InputEventKey and event.pressed and Globals.is_transitioning == false:
|
||||
if event.keycode == KEY_SPACE:
|
||||
on_skip_request.emit()
|
||||
|
||||
|
||||
func _on_skip_request():
|
||||
if Globals.is_transitioning == false:
|
||||
on_transition_finished.emit()
|
||||
|
||||
|
||||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta: float) -> void:
|
||||
|
||||
Reference in New Issue
Block a user