Ability work and portal fixes....

This commit is contained in:
dingo
2026-02-11 15:28:08 -05:00
parent 8ddbd3a231
commit 6e7cec8959
9 changed files with 274 additions and 53 deletions
+1 -1
View File
@@ -296,7 +296,7 @@ func _on_logout_pressed():
# Reset GameState
if GameState:
GameState.reset_state()
GameState.set_state(0)
# Return to login screen
get_tree().change_scene_to_file("res://scenes/ui/login.tscn")
+6 -2
View File
@@ -39,9 +39,13 @@ func _on_state_changed(new_state: String):
func _show_screen(state: String):
print("[Main] _show_screen called with: ", state)
# Transitional states (portal exit, dungeon cleared) show the loading screen
# while waiting for the server to send HUB_STATE.
var is_transitioning = state == "PORTALUSED" or state == "DUNGEONCLEARED"
if loading_screen:
_set_screen_visible(loading_screen, state == "LOADING")
print("[Main] LoadingScreen visible: ", state == "LOADING")
_set_screen_visible(loading_screen, state == "LOADING" or is_transitioning)
print("[Main] LoadingScreen visible: ", state == "LOADING" or is_transitioning)
if auth_screen:
_set_screen_visible(auth_screen, state == "AUTH")
print("[Main] AuthScreen visible: ", state == "AUTH")