added blocking doors to paths.
This commit is contained in:
@@ -23,6 +23,9 @@ func show_level(level_number: int):
|
||||
if tween.is_valid():
|
||||
tween.kill()
|
||||
|
||||
# Get vbox once at the start (reuse throughout function)
|
||||
var vbox = get_child(0) if get_child_count() > 0 else null
|
||||
|
||||
# Update label text FIRST before showing
|
||||
if level_label:
|
||||
level_label.text = "LEVEL " + str(level_number)
|
||||
@@ -30,7 +33,6 @@ func show_level(level_number: int):
|
||||
else:
|
||||
print("LevelTextUI: ERROR - level_label is null!")
|
||||
# Try to find it again
|
||||
var vbox = get_child(0) if get_child_count() > 0 else null
|
||||
if vbox:
|
||||
for child in vbox.get_children():
|
||||
if child.name == "LevelLabel" or child is Label:
|
||||
@@ -43,7 +45,6 @@ func show_level(level_number: int):
|
||||
visible = true
|
||||
|
||||
# Fade in - fade the VBoxContainer and level label
|
||||
var vbox = get_child(0) if get_child_count() > 0 else null
|
||||
if vbox:
|
||||
vbox.modulate.a = 0.0
|
||||
var fade_in = create_tween()
|
||||
@@ -68,4 +69,3 @@ func show_level(level_number: int):
|
||||
await fade_out.finished
|
||||
|
||||
visible = false
|
||||
|
||||
|
||||
Reference in New Issue
Block a user