feat(outline): outline targets when using item and pressing shift key
This commit is contained in:
@@ -36,6 +36,12 @@ func _process(_delta: float):
|
||||
|
||||
func _input(event):
|
||||
if event.is_action_pressed("ui_show_hints") and escoria.current_state == escoria.GAME_STATE.DEFAULT:
|
||||
if escoria.action_manager.action_state == escoria.action_manager.ACTION_INPUT_STATE.AWAITING_TARGET_ITEM:
|
||||
var item = get_parent()
|
||||
var current_tool_id = escoria.action_manager.current_tool.global_id
|
||||
if item.action3_target_texts.get(current_tool_id) or item.action4_target_texts.get(current_tool_id):
|
||||
highlight(true)
|
||||
else:
|
||||
highlight(true)
|
||||
elif (event.is_action_released("ui_show_hints")):
|
||||
highlight(false)
|
||||
|
||||
@@ -10,11 +10,6 @@ size = Vector2(45, 25)
|
||||
[node name="turno_cocina_patata" type="Area2D"]
|
||||
process_mode = 1
|
||||
script = ExtResource("1")
|
||||
global_id = "turno_cocina_patata"
|
||||
esc_script = "res://gymkhana/items/inventory/turno_cocina_patata.esc"
|
||||
inventory_texture = ExtResource("2")
|
||||
dialog_color = Color(1, 1, 1, 1)
|
||||
combine_when_selected_action_is_in = ["action4"]
|
||||
action3_target_texts = {
|
||||
"turno_cocina_cuchillo": "tooltip_turno_cocina_patata_action3_turno_cocina_cuchillo"
|
||||
}
|
||||
@@ -22,7 +17,11 @@ action4_target_texts = {
|
||||
"turno_cocina_cuchillo": "tooltip_turno_cocina_patata_action4_turno_cocina_cuchillo"
|
||||
}
|
||||
target_when_selected_action_is_in = ["action3", "action4"]
|
||||
animations = null
|
||||
global_id = "turno_cocina_patata"
|
||||
esc_script = "res://gymkhana/items/inventory/turno_cocina_patata.esc"
|
||||
combine_when_selected_action_is_in = PackedStringArray("action4")
|
||||
inventory_texture = ExtResource("2")
|
||||
inventory_texture_hovered = ExtResource("2")
|
||||
custom_data = {
|
||||
"count_textures": [{
|
||||
"start": 1,
|
||||
|
||||
Reference in New Issue
Block a user