Skip to content

Commit

Permalink
tuto
Browse files Browse the repository at this point in the history
  • Loading branch information
BlendyDev committed Aug 20, 2024
1 parent ea8ef88 commit fab39e8
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 13 deletions.
4 changes: 2 additions & 2 deletions scenes/level/tutorial/level.tscn

Large diffs are not rendered by default.

8 changes: 7 additions & 1 deletion scenes/level/tutorial/tutorial.gd
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,16 @@ func _ready():
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta):
if Global.changeScreen:
$TransitionTime.start()
$Transitions.play("fadeout")



func _on_transition_time_timeout():
Global.changeScreen = false


func transitionFinished(anim_name):
if (Global.changeScreen):
Global.changeScreen = false
get_tree().change_scene_to_file("res://scenes/level/level1/level1.tscn")
pass # Replace with function body.
6 changes: 1 addition & 5 deletions scenes/level/tutorial/tutorial.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -321,15 +321,11 @@ grow_horizontal = 2
grow_vertical = 2
color = Color(0, 0, 0, 0)

[node name="TransitionTime" type="Timer" parent="."]
wait_time = 3.0
one_shot = true

[connection signal="area_entered" from="DoorHandler" to="DoorHandler" method="_on_area_entered"]
[connection signal="mouse_entered" from="Nabo" to="Nabo" method="_on_mouse_entered"]
[connection signal="mouse_exited" from="Nabo" to="Nabo" method="_on_mouse_exited"]
[connection signal="body_entered" from="Lupa" to="Lupa" method="bodyEntered"]
[connection signal="body_exited" from="Lupa" to="Lupa" method="bodyExited"]
[connection signal="scaleLevelChanged" from="Lupa" to="LevelHandler/Scaled/ScaledLevel" method="scaleLevelChange"]
[connection signal="scaleLevelChanged" from="Lupa" to="LevelHandler/Scaled/ScaledSpikes" method="scaleLevelChange"]
[connection signal="timeout" from="TransitionTime" to="." method="_on_transition_time_timeout"]
[connection signal="animation_finished" from="Transitions" to="." method="transitionFinished"]
7 changes: 2 additions & 5 deletions scenes/win_animation.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,9 @@ max_distance = 1e+09
bus = &"Music"

[node name="Sprite2D" type="Sprite2D" parent="."]
visible = false
position = Vector2(-2, -28)
texture = ExtResource("7_j1p8o")
hframes = 23

[node name="WinTimer" type="Timer" parent="."]
wait_time = 5.25
one_shot = true

[connection signal="timeout" from="WinTimer" to="." method="_on_win_timer_timeout"]
[connection signal="animation_finished" from="AnimationPlayer" to="." method="_on_animation_player_animation_finished"]

0 comments on commit fab39e8

Please sign in to comment.