midori-school/backgounds/gameover.gd

20 lines
529 B
GDScript3
Raw Normal View History

2024-09-06 02:16:49 +02:00
extends Node2D
var sfx1 := AudioStreamPlayer.new()
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
add_child(sfx1)
sfx1.mix_target = 1
2024-11-07 21:39:59 +01:00
sfx1.bus = "SFX1"
2024-09-06 02:16:49 +02:00
sfx1.stream = load(Global.sfxtracks[0])
sfx1.play(0)
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
pass
func _input(event):
2024-12-02 02:45:44 +01:00
if Input.is_action_just_pressed("ui_accept") || Input.is_action_just_pressed("mclick"):
2024-11-07 21:39:59 +01:00
get_tree().change_scene("res://title.tscn")