Set a default implementation for ESCGame._on_event_done() (#486)
This commit is contained in:
@@ -47,12 +47,6 @@ onready var inventory_ui = $ui/Control/panel_down/VBoxContainer/HBoxContainer\
|
||||
/InventoryMargin/inventory_ui
|
||||
|
||||
func _enter_tree():
|
||||
escoria.action_manager.connect(
|
||||
"action_finished",
|
||||
self,
|
||||
"_on_action_finished"
|
||||
)
|
||||
|
||||
var room_selector_parent = $ui/Control/panel_down/VBoxContainer\
|
||||
/HBoxContainer/MainMargin/VBoxContainer
|
||||
|
||||
@@ -65,14 +59,6 @@ func _enter_tree():
|
||||
).instance()
|
||||
)
|
||||
|
||||
func _exit_tree():
|
||||
escoria.action_manager.disconnect(
|
||||
"action_finished",
|
||||
self,
|
||||
"_on_action_finished"
|
||||
)
|
||||
|
||||
|
||||
|
||||
## BACKGROUND ##
|
||||
|
||||
@@ -301,10 +287,6 @@ func show_ui():
|
||||
inventory_ui.show()
|
||||
tooltip.show()
|
||||
|
||||
func _on_event_done(_event_name: String):
|
||||
escoria.action_manager.clear_current_action()
|
||||
verbs_menu.unselect_actions()
|
||||
|
||||
func hide_main_menu():
|
||||
if get_node(main_menu).visible:
|
||||
get_node(main_menu).hide()
|
||||
@@ -343,6 +325,10 @@ func _on_action_finished() -> void:
|
||||
verbs_menu.unselect_actions()
|
||||
tooltip.clear()
|
||||
|
||||
func _on_event_done(_return_code: int, _event_name: String):
|
||||
escoria.action_manager.clear_current_action()
|
||||
verbs_menu.unselect_actions()
|
||||
|
||||
|
||||
func apply_custom_settings(custom_settings: Dictionary):
|
||||
if custom_settings.has("a_custom_setting"):
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=12 format=2]
|
||||
[gd_scene load_steps=11 format=2]
|
||||
|
||||
[ext_resource path="res://addons/escoria-ui-9verbs/tooltip/action_target_tooltip.tscn" type="PackedScene" id=1]
|
||||
[ext_resource path="res://addons/escoria-ui-9verbs/inventory/inventory_ui.tscn" type="PackedScene" id=2]
|
||||
@@ -7,7 +7,6 @@
|
||||
[ext_resource path="res://addons/escoria-ui-9verbs/game.gd" type="Script" id=5]
|
||||
[ext_resource path="res://addons/escoria-core/game/scenes/camera_player/camera.tscn" type="PackedScene" id=6]
|
||||
[ext_resource path="res://addons/escoria-core/ui_library/menus/main_menu/main_menu.tscn" type="PackedScene" id=7]
|
||||
[ext_resource path="res://addons/escoria-ui-9verbs/tooltip/tooltip_action_target.gd" type="Script" id=8]
|
||||
[ext_resource path="res://addons/escoria-core/ui_library/menus/pause_menu/pause_menu.tscn" type="PackedScene" id=9]
|
||||
[ext_resource path="res://addons/escoria-ui-9verbs/theme.tres" type="Theme" id=10]
|
||||
|
||||
@@ -67,7 +66,6 @@ margin_bottom = 32.0
|
||||
bbcode_text = "[center]Test[/center]"
|
||||
text = "Test"
|
||||
fit_content_height = true
|
||||
script = ExtResource( 8 )
|
||||
color = Color( 1, 1, 1, 1 )
|
||||
|
||||
[node name="HSeparator" type="HSeparator" parent="ui/Control/panel_down/VBoxContainer"]
|
||||
|
||||
Reference in New Issue
Block a user