CHANGE TO escoria-core. action1 and action2 in tooltip
This commit is contained in:
@@ -221,7 +221,8 @@ func element_focused(element_id: String) -> void:
|
||||
)
|
||||
|
||||
var target_obj = escoria.object_manager.get_object(element_id).node
|
||||
$tooltip_layer/tooltip.set_target(target_obj.tooltip_name)
|
||||
$tooltip_layer/tooltip.set_target(target_obj.action1 + " " + target_obj.action2)
|
||||
# $tooltip_layer/tooltip.set_target(target_obj.tooltip_name)
|
||||
|
||||
if escoria.action_manager.current_action != VERB_USE \
|
||||
and escoria.action_manager.current_tool == null \
|
||||
@@ -236,7 +237,9 @@ func element_unfocused() -> void:
|
||||
|
||||
|
||||
## ITEMS ##
|
||||
func click_on_item(item_global_id: String, event: InputEvent) -> void:
|
||||
func click_on_item(item_global_id: String, event: InputEvent, action: String) -> void:
|
||||
escoria.action_manager.set_current_action(action)
|
||||
|
||||
var target_obj = escoria.object_manager.get_object(item_global_id).node
|
||||
|
||||
# current_action will be empty if an event completes between when you stop
|
||||
@@ -254,12 +257,10 @@ func click_on_item(item_global_id: String, event: InputEvent) -> void:
|
||||
)
|
||||
|
||||
func left_click_on_item(item_global_id: String, event: InputEvent) -> void:
|
||||
escoria.action_manager.set_current_action("action1")
|
||||
click_on_item(item_global_id, event)
|
||||
click_on_item(item_global_id, event, "action1")
|
||||
|
||||
func right_click_on_item(item_global_id: String, event: InputEvent) -> void:
|
||||
escoria.action_manager.set_current_action("action2")
|
||||
click_on_item(item_global_id, event)
|
||||
click_on_item(item_global_id, event, "action2")
|
||||
|
||||
func left_double_click_on_item(item_global_id: String, event: InputEvent) -> void:
|
||||
escoria.action_manager.do(
|
||||
|
||||
Reference in New Issue
Block a user