Picked observer, global observer

This commit is contained in:
2025-09-14 04:44:12 +02:00
parent 5e1d88c333
commit f41fc361b8
28 changed files with 183 additions and 103 deletions

View File

@@ -1,18 +1,17 @@
[gd_scene load_steps=3 format=3 uid="uid://84h4l81cuwdv"]
[gd_scene load_steps=4 format=3 uid="uid://84h4l81cuwdv"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://cueb8gkqhbads" path="res://gymkhana/items/inventory/assets/turno_cocina_ajo.png" id="2"]
[ext_resource type="Script" uid="uid://bh55kesnba2x4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentGlobalObserver.gd" id="6_fo2yn"]
[ext_resource type="Texture2D" uid="uid://c47biotravims" path="res://gymkhana/items/inventory/assets/turno_cocina_ajo.png" id="2"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="3_snubi"]
[node name="turno_cocina_ajo" type="Area2D"]
process_mode = 1
script = ExtResource("1")
global_id = "turno_cocina_ajo"
esc_script = "res://gymkhana/items/inventory/turno_cocina_ajo.esc"
combine_when_selected_action_is_in = ["action4"]
combine_when_selected_action_is_in = PackedStringArray("action4")
inventory_texture = ExtResource("2")
dialog_color = Color(1, 1, 1, 1)
inventory_texture_hovered = ExtResource("2")
custom_data = {
"tooltips": {
"action1": "tooltip_turno_cocina_ajo_action1",
@@ -20,7 +19,6 @@ custom_data = {
"action4": "tooltip_common_use"
}
}
animations = null
[node name="Sprite2D" type="Sprite2D" parent="."]
scale = Vector2(0.101548, 0.101548)
@@ -29,8 +27,6 @@ texture = ExtResource("2")
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."]
polygon = PackedVector2Array(-7, -6, 7, -6, 7, 6, -7, 6)
[node name="ESCItemComponentGlobalBooleanObserver" type="Node" parent="."]
script = ExtResource("6_fo2yn")
targeted_global_variable = "turno_cocina_ingrediente_ajo_cogido"
inverted = true
metadata/_custom_type_script = "uid://bh55kesnba2x4"
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("3_snubi")
metadata/_custom_type_script = "uid://cde2xhhd2twx4"

View File

@@ -1,16 +1,21 @@
[gd_scene load_steps=3 format=3 uid="uid://cpeqaymxabewi"]
[gd_scene load_steps=4 format=3 uid="uid://cpeqaymxabewi"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://nktfki1vvj7h" path="res://gymkhana/items/inventory/assets/turno_cocina_bol_inventario.png" id="2"]
[ext_resource type="Texture2D" uid="uid://276uevmvuuhp" path="res://gymkhana/items/inventory/assets/turno_cocina_bol_inventario.png" id="2"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="3_g5aye"]
[node name="turno_cocina_bol" type="Area2D"]
process_mode = 1
script = ExtResource("1")
action3_target_texts = {
"turno_cocina_peso": "tooltip_turno_cocina_bol_action3_turno_cocina_peso"
}
target_when_selected_action_is_in = ["action3"]
global_id = "turno_cocina_bol"
esc_script = "res://gymkhana/items/inventory/turno_cocina_bol.esc"
combine_when_selected_action_is_in = ["action4"]
combine_when_selected_action_is_in = PackedStringArray("action4")
inventory_texture = ExtResource("2")
dialog_color = Color(1, 1, 1, 1)
inventory_texture_hovered = ExtResource("2")
custom_data = {
"tooltips": {
"action1": "tooltip_turno_cocina_bol_action1",
@@ -18,8 +23,6 @@ custom_data = {
"action4": "tooltip_common_use"
}
}
action3_target_texts = {
"turno_cocina_peso": "tooltip_turno_cocina_bol_action3_turno_cocina_peso"
}
target_when_selected_action_is_in = ["action3"]
animations = null
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("3_g5aye")

View File

@@ -3,7 +3,6 @@
:action2
say($player, "Cartón pa la saca!", "cocina_delante_carton_action2_say")
set_active($turno_cocina_carton, false)
inventory_add($turno_cocina_carton)
:action3

View File

@@ -1,17 +1,22 @@
[gd_scene load_steps=4 format=3 uid="uid://dyejne0ibag68"]
[gd_scene load_steps=5 format=3 uid="uid://dyejne0ibag68"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://qkq00po4xvto" path="res://gymkhana/items/inventory/assets/turno_cocina_carton.png" id="2"]
[ext_resource type="Texture2D" uid="uid://dfxjkbugt0jld" path="res://gymkhana/items/inventory/assets/turno_cocina_carton_inventario.png" id="3"]
[ext_resource type="Texture2D" uid="uid://cpqta35jfbrd3" path="res://gymkhana/items/inventory/assets/turno_cocina_carton.png" id="2"]
[ext_resource type="Texture2D" uid="uid://cw3t327fk3bcg" path="res://gymkhana/items/inventory/assets/turno_cocina_carton_inventario.png" id="3"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="4_2tvrr"]
[node name="turno_cocina_carton" type="Area2D"]
process_mode = 1
script = ExtResource("1")
action3_target_texts = {
"turno_cocina_mechero": "tooltip_turno_cocina_carton_action3_turno_cocina_mechero"
}
target_when_selected_action_is_in = ["action3"]
global_id = "turno_cocina_carton"
esc_script = "res://gymkhana/items/inventory/turno_cocina_carton.esc"
combine_when_selected_action_is_in = ["action4"]
combine_when_selected_action_is_in = PackedStringArray("action4")
inventory_texture = ExtResource("3")
dialog_color = Color(1, 1, 1, 1)
inventory_texture_hovered = ExtResource("3")
custom_data = {
"tooltips": {
"action1": "tooltip_common_look",
@@ -20,14 +25,12 @@ custom_data = {
"action4": "tooltip_common_use"
}
}
action3_target_texts = {
"turno_cocina_mechero": "tooltip_turno_cocina_carton_action3_turno_cocina_mechero"
}
target_when_selected_action_is_in = ["action3"]
animations = null
[node name="Sprite2D" type="Sprite2D" parent="."]
texture = ExtResource("2")
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."]
polygon = PackedVector2Array(-23, -11, -24, 2, -24, 11, -21, 13, -6, 16, 5, 17, 21, 12, 25, 8, 25, -13, 0, -16, -9, -17)
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("4_2tvrr")

View File

@@ -3,4 +3,4 @@
:action3 "cocina_cuchillos"
say($player, "El cuchillo a su sitio!", "cocina_cuchillos_action3_cuchillo_say")
inventory_remove($turno_cocina_cuchillo)
inventory_remove("turno_cocina_cuchillo")

View File

@@ -1,16 +1,17 @@
[gd_scene load_steps=3 format=3 uid="uid://bnf0ylqtnajms"]
[gd_scene load_steps=4 format=3 uid="uid://bnf0ylqtnajms"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://7hcp3g8e17po" path="res://gymkhana/items/inventory/assets/turno_cocina_libro_de_cocina.png" id="2"]
[ext_resource type="Texture2D" uid="uid://yisdxay77l1j" path="res://gymkhana/items/inventory/assets/turno_cocina_libro_de_cocina.png" id="2"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="3_ndiib"]
[node name="turno_cocina_libro_de_cocina" type="Area2D"]
process_mode = 1
script = ExtResource("1")
global_id = "turno_cocina_libro_de_cocina"
esc_script = "res://gymkhana/items/inventory/turno_cocina_libro_de_cocina.esc"
combine_when_selected_action_is_in = []
combine_when_selected_action_is_in = PackedStringArray()
inventory_texture = ExtResource("2")
dialog_color = Color(1, 1, 1, 1)
inventory_texture_hovered = ExtResource("2")
custom_data = {
"tooltips": {
"action1": "tooltip_common_look",
@@ -18,4 +19,7 @@ custom_data = {
"action3": "tooltip_turno_cocina_libro_de_cocina_action3"
}
}
animations = null
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("3_ndiib")
metadata/_custom_type_script = "uid://cde2xhhd2twx4"

View File

@@ -4,7 +4,6 @@
:action2
say($player, "cocina_delante_madera_action2_say", "Con esto podré hacer un buen fuego.")
inventory_add("turno_cocina_madera")
set_active("turno_cocina_madera", false)
:action3
say($player, "cocina_delante_madera_action3_say", "Es leña de pino, esto tiene que dejar los tubos bien sucios.")

View File

@@ -1,15 +1,17 @@
[gd_scene load_steps=3 format=3 uid="uid://cbsyjat8xvwfx"]
[gd_scene load_steps=4 format=3 uid="uid://cbsyjat8xvwfx"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://bmivmrciqatkc" path="res://gymkhana/items/inventory/assets/turno_cocina_madera.png" id="2"]
[ext_resource type="Texture2D" uid="uid://b580c3swhl2q3" path="res://gymkhana/items/inventory/assets/turno_cocina_madera.png" id="2"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="3_3vrak"]
[node name="turno_cocina_madera" type="Area2D"]
process_mode = 1
script = ExtResource("1")
global_id = "turno_cocina_madera"
esc_script = "res://gymkhana/items/inventory/turno_cocina_madera.esc"
combine_when_selected_action_is_in = PackedStringArray("action4")
inventory_texture = ExtResource("2")
dialog_color = Color(1, 1, 1, 1)
inventory_texture_hovered = ExtResource("2")
custom_data = {
"tooltips": {
"action1": "tooltip_cocina_delante_madera_action1",
@@ -18,5 +20,6 @@ custom_data = {
"action4": "tooltip_common_use"
}
}
animations = null
combine_when_selected_action_is_in = ["action4"]
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("3_3vrak")

View File

@@ -4,7 +4,6 @@
:action2
say_to_camera($player, "A la saca!", "mechero_action2_say")
set_active($turno_cocina_mechero, false)
inventory_add("turno_cocina_mechero")
:action3

View File

@@ -1,16 +1,17 @@
[gd_scene load_steps=3 format=3 uid="uid://bxjtxquhseqdp"]
[gd_scene load_steps=4 format=3 uid="uid://bxjtxquhseqdp"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://p48fq13qx3d5" path="res://gymkhana/items/inventory/assets/turno_cocina_mechero.png" id="2"]
[ext_resource type="Texture2D" uid="uid://7jfdrbqf2a0h" path="res://gymkhana/items/inventory/assets/turno_cocina_mechero.png" id="2"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="3_fiv88"]
[node name="turno_cocina_mechero" type="Area2D"]
process_mode = 1
script = ExtResource("1")
global_id = "turno_cocina_mechero"
esc_script = "res://gymkhana/items/inventory/turno_cocina_mechero.esc"
combine_when_selected_action_is_in = ["action4"]
combine_when_selected_action_is_in = PackedStringArray("action4")
inventory_texture = ExtResource("2")
dialog_color = Color(1, 1, 1, 1)
inventory_texture_hovered = ExtResource("2")
custom_data = {
"tooltips": {
"action1": "tooltip_common_look",
@@ -19,7 +20,6 @@ custom_data = {
"action4": "tooltip_common_use"
}
}
animations = null
[node name="Sprite2D" type="Sprite2D" parent="."]
position = Vector2(-2, 0)
@@ -28,3 +28,6 @@ texture = ExtResource("2")
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."]
polygon = PackedVector2Array(-15, -29, 3, -33, 10, 30, -3, 32)
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("3_fiv88")

View File

@@ -40,7 +40,13 @@ polygon = PackedVector2Array(-59, 25, -59, 47, -35, 56, 7, 58, 54, 52, 55, -13,
[node name="SmokeParticles" parent="." instance=ExtResource("4")]
script = ExtResource("5")
[node name="ESCItemComponentGlobalBooleanObserver" type="Node" parent="."]
[node name="ESCItemComponentGlobalBooleanObserverVisible" type="Node" parent="."]
script = ExtResource("6_fo2yn")
targeted_global_variable = "turno_cocina_economica_con_olla"
targeted_property = 1
metadata/_custom_type_script = "uid://bh55kesnba2x4"
[node name="ESCItemComponentGlobalBooleanObserverActive" type="Node" parent="."]
script = ExtResource("6_fo2yn")
targeted_global_variable = "turno_cocina_economica_con_olla"
metadata/_custom_type_script = "uid://bh55kesnba2x4"

View File

@@ -3,7 +3,6 @@
:action2
say($current_player, "Podria ser útil!!", "olla_vacia_action1")
set_active($turno_cocina_olla_vacia, false)
inventory_add("turno_cocina_olla_vacia")
:action3

View File

@@ -1,8 +1,9 @@
[gd_scene load_steps=4 format=3 uid="uid://dgucic2086suo"]
[gd_scene load_steps=5 format=3 uid="uid://dgucic2086suo"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://brjb1fkbo0so" path="res://gymkhana/items/inventory/assets/turno_cocina_olla_inv_vacia.png" id="2"]
[ext_resource type="Texture2D" uid="uid://bhdcferfexcgb" path="res://gymkhana/items/inventory/assets/turno_cocina_olla.png" id="3"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="4_v2esb"]
[node name="turno_cocina_olla_vacia" type="Area2D"]
process_mode = 1
@@ -18,6 +19,7 @@ global_id = "turno_cocina_olla_vacia"
esc_script = "res://gymkhana/items/inventory/turno_cocina_olla_vacia.esc"
combine_when_selected_action_is_in = PackedStringArray("action4")
inventory_texture = ExtResource("2")
inventory_texture_hovered = ExtResource("2")
custom_data = {
"tooltips": {
"action1": "tooltip_common_look",
@@ -32,3 +34,6 @@ texture = ExtResource("3")
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."]
polygon = PackedVector2Array(-59, 41, -59, -44, -63, -48, -62, -52, -59, -54, -49, -58, -34, -60, -16, -62, 1, -61, 21, -60, 44, -57, 57, -53, 61, -47, 58, -41, 56, -29, 62, -29, 64, -27, 58, -25, 56, -21, 53, 33, 50, 44, 44, 52, 33, 55, 12, 59, -12, 59, -40, 56, -54, 50)
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("4_v2esb")

View File

@@ -1,8 +1,9 @@
[gd_scene load_steps=4 format=3 uid="uid://cwlq5pqwktbul"]
[gd_scene load_steps=5 format=3 uid="uid://cwlq5pqwktbul"]
[ext_resource type="Script" uid="uid://ceym82rf2qnxu" path="res://addons/escoria-ui-return-monkey-island/esc_item_with_tooltip.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://dtxqb3363mlxa" path="res://gymkhana/items/inventory/assets/turno_cocina_peso.png" id="2"]
[ext_resource type="Texture2D" uid="uid://bk7lml882oihk" path="res://gymkhana/items/inventory/assets/turno_cocina_peso_inventario.png" id="3"]
[ext_resource type="Script" uid="uid://cde2xhhd2twx4" path="res://addons/escoria-ui-return-monkey-island/item_components/ESCItemComponentPickedObserver.gd" id="4_66neb"]
[node name="turno_cocina_peso" type="Area2D"]
process_mode = 1
@@ -15,6 +16,7 @@ global_id = "turno_cocina_peso"
esc_script = "res://gymkhana/items/inventory/turno_cocina_peso.esc"
combine_when_selected_action_is_in = PackedStringArray("action4")
inventory_texture = ExtResource("3")
inventory_texture_hovered = ExtResource("3")
custom_data = {
"tooltips": {
"action1": "tooltip_common_whats_this",
@@ -28,3 +30,6 @@ custom_data = {
rotation = -0.0698132
scale = Vector2(0.18, 0.18)
texture = ExtResource("2")
[node name="ESCItemComponentPickedObserver" type="Node" parent="."]
script = ExtResource("4_66neb")