buckshotroulette-decomp/TempDeathScreen.gd
Lyssa a86f69ecf1
reverse v1.2.1 changes
goddammit bob
2024-04-10 22:19:04 +04:00

24 lines
698 B
GDScript

class_name TempDeathScreen extends Node
@export var isDeathScreen : bool
@export var savefile : SaveFileManager
@export var viewblocker : ColorRect
@export var speaker : AudioStreamPlayer2D
var allowed = true
var fs = false
func _ready():
if (isDeathScreen):
print("changing scene to: main")
get_tree().change_scene_to_file("res://scenes/main.tscn")
#func _unhandled_input(event):
# if (event.is_action_pressed("enter") && allowed && !fs):
# viewblocker.color = Color(0, 0, 0, 1)
# speaker.pitch_scale = .8
# await get_tree().create_timer(.5, false).timeout
# if (!isDeathScreen):
# savefile.ClearSave()
# get_tree().change_scene_to_file("res://scenes/main.tscn")
# allowed = false