diff --git a/entities/chupacabra.tscn b/entities/chupacabra.tscn index 82ae7cb..cdfb118 100644 --- a/entities/chupacabra.tscn +++ b/entities/chupacabra.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=40 format=3 uid="uid://cmemgijh6nfmk"] +[gd_scene load_steps=41 format=3 uid="uid://cmemgijh6nfmk"] [ext_resource type="PackedScene" uid="uid://bxbjfev0lhwws" path="res://behaviours/sprite_left_right.tscn" id="1_11voy"] [ext_resource type="Script" path="res://entities/chupacabra.gd" id="1_s4qg1"] @@ -18,6 +18,7 @@ [ext_resource type="PackedScene" uid="uid://cbg5kgwxusvxf" path="res://behaviours/cursor_detector.tscn" id="10_3wu3x"] [ext_resource type="PackedScene" uid="uid://b04xhv32ypi42" path="res://entities/monocle.tscn" id="10_k033w"] [ext_resource type="PackedScene" uid="uid://rx24bppccih7" path="res://behaviours/move_physics.tscn" id="12_oildi"] +[ext_resource type="PackedScene" uid="uid://dfdr3e32lohq" path="res://behaviours/edible.tscn" id="13_het3n"] [ext_resource type="PackedScene" uid="uid://cml7rqvyfuagx" path="res://behaviours/move_towards.tscn" id="13_vh42q"] [ext_resource type="PackedScene" uid="uid://dijcjahkddudv" path="res://behaviours/draggable.tscn" id="13_wcydr"] [ext_resource type="PackedScene" uid="uid://ctpn4hvkhxoi3" path="res://behaviours/tracker_edible.tscn" id="14_mk76g"] @@ -434,6 +435,9 @@ next/drag_start = &"drag_loop" next/run = &"run" next/sit = &"sit" +[node name="Edible" parent="." instance=ExtResource("13_het3n")] +diet = &"Demon" + [node name="Sacrificable" parent="." instance=ExtResource("7_igror")] kind = &"Chupacabra" diff --git a/entities/cthulhu.tscn b/entities/cthulhu.tscn index 97f0885..61febeb 100644 --- a/entities/cthulhu.tscn +++ b/entities/cthulhu.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=26 format=3 uid="uid://gl4umoff474y"] +[gd_scene load_steps=27 format=3 uid="uid://gl4umoff474y"] [ext_resource type="PackedScene" uid="uid://bxbjfev0lhwws" path="res://behaviours/sprite_left_right.tscn" id="1_a8ato"] [ext_resource type="Script" path="res://entities/cthulhu.gd" id="1_b55wc"] @@ -18,6 +18,7 @@ [ext_resource type="AudioStream" uid="uid://d0feiq5s6fnux" path="res://entities/imp_drag.wav" id="11_jt7u1"] [ext_resource type="AudioStream" uid="uid://cwsg776c11xfc" path="res://entities/fall.ogg" id="12_v8da5"] [ext_resource type="PackedScene" uid="uid://jg7qkbswgqjc" path="res://behaviours/eater.tscn" id="15_vopba"] +[ext_resource type="AudioStream" uid="uid://c1yuksnjdd6g2" path="res://entities/imp_eat.ogg" id="19_3hopf"] [sub_resource type="CircleShape2D" id="CircleShape2D_wjkbi"] radius = 56.0 @@ -290,6 +291,20 @@ bus = &"DragSounds" stream = ExtResource("12_v8da5") bus = &"FallSounds" +[node name="Eater" parent="." instance=ExtResource("15_vopba")] +unique_name_in_owner = true +position = Vector2(0, 36) +collision_mask = 24 +acceptable_diets = Array[StringName]([&"Demon"]) + +[node name="EatSound" type="AudioStreamPlayer2D" parent="Eater"] +stream = ExtResource("19_3hopf") +bus = &"KillSounds" + +[node name="Shape" type="CollisionShape2D" parent="Eater"] +shape = SubResource("CircleShape2D_wjkbi") +debug_color = Color(1, 0, 0, 0) + [connection signal="eaten" from="SpriteFocus/Sprite/TopHatter" to="." method="_on_eater_eaten"] [connection signal="eaten" from="SpriteFocus/Sprite/TopHatter" to="SpriteFocus/Sprite/TopHatter/Spawner" method="enable" unbinds=1] [connection signal="goal_reached" from="SpriteFocus/Sprite/TopHatter" to="SpriteFocus/Sprite/TopHatter/Sprite" method="show"] @@ -307,3 +322,5 @@ bus = &"FallSounds" [connection signal="move" from="MovementDrag" to="." method="_on_move"] [connection signal="dragged" from="MovementDrag/Draggable" to="MovementDrag" method="drag"] [connection signal="dropped" from="MovementDrag/Draggable" to="MovementDrag" method="drop"] +[connection signal="eaten" from="Eater" to="." method="_on_eater_eaten"] +[connection signal="eaten" from="Eater" to="Eater/EatSound" method="play" unbinds=1] diff --git a/entities/imp.tscn b/entities/imp.tscn index 4214e54..1f29b2a 100644 --- a/entities/imp.tscn +++ b/entities/imp.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=37 format=3 uid="uid://4d3ksr3171x4"] +[gd_scene load_steps=38 format=3 uid="uid://4d3ksr3171x4"] [ext_resource type="Script" path="res://entities/imp.gd" id="1_dixpc"] [ext_resource type="PackedScene" uid="uid://bxbjfev0lhwws" path="res://behaviours/sprite_left_right.tscn" id="2_eqcdi"] @@ -19,6 +19,7 @@ [ext_resource type="PackedScene" uid="uid://g8t6dt0ye6n3" path="res://behaviours/timer_stddev.tscn" id="10_phvea"] [ext_resource type="PackedScene" uid="uid://cml7rqvyfuagx" path="res://behaviours/move_towards.tscn" id="11_4ra22"] [ext_resource type="PackedScene" uid="uid://ctpn4hvkhxoi3" path="res://behaviours/tracker_edible.tscn" id="12_dr2oe"] +[ext_resource type="PackedScene" uid="uid://dfdr3e32lohq" path="res://behaviours/edible.tscn" id="13_43t3r"] [ext_resource type="PackedScene" uid="uid://dti7l0d40hhgt" path="res://behaviours/target_picker.tscn" id="13_mwxuf"] [ext_resource type="PackedScene" uid="uid://rx24bppccih7" path="res://behaviours/move_physics.tscn" id="14_p3w0g"] [ext_resource type="PackedScene" uid="uid://jg7qkbswgqjc" path="res://behaviours/eater.tscn" id="14_w2h8x"] @@ -299,6 +300,9 @@ libraries = { next/drag_loop = &"drag_loop" next/drag_start = &"drag_loop" +[node name="Edible" parent="." instance=ExtResource("13_43t3r")] +diet = &"Demon" + [node name="Sacrificable" parent="." instance=ExtResource("7_gg20m")] kind = &"Imp" diff --git a/entities/watcher.tscn b/entities/watcher.tscn index 1de5512..d40d286 100644 --- a/entities/watcher.tscn +++ b/entities/watcher.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=38 format=3 uid="uid://dnjtduk0hla3f"] +[gd_scene load_steps=39 format=3 uid="uid://dnjtduk0hla3f"] [ext_resource type="Script" path="res://entities/watcher.gd" id="1_brahc"] [ext_resource type="PackedScene" uid="uid://bxbjfev0lhwws" path="res://behaviours/sprite_left_right.tscn" id="1_thu73"] @@ -20,6 +20,7 @@ [ext_resource type="PackedScene" uid="uid://g8t6dt0ye6n3" path="res://behaviours/timer_stddev.tscn" id="11_20lvf"] [ext_resource type="AudioStream" uid="uid://d0feiq5s6fnux" path="res://entities/imp_drag.wav" id="11_rydo5"] [ext_resource type="AudioStream" uid="uid://cwsg776c11xfc" path="res://entities/fall.ogg" id="12_0h21e"] +[ext_resource type="PackedScene" uid="uid://dfdr3e32lohq" path="res://behaviours/edible.tscn" id="13_lowgs"] [ext_resource type="PackedScene" uid="uid://uoxwjpmgg27a" path="res://entities/gold.tscn" id="14_cfqh8"] [ext_resource type="PackedScene" uid="uid://cml7rqvyfuagx" path="res://behaviours/move_towards.tscn" id="14_qtr50"] [ext_resource type="PackedScene" uid="uid://ctpn4hvkhxoi3" path="res://behaviours/tracker_edible.tscn" id="15_ihnef"] @@ -306,6 +307,9 @@ libraries = { next/drag_loop = &"drag_loop" next/drag_start = &"drag_loop" +[node name="Edible" parent="." instance=ExtResource("13_lowgs")] +diet = &"Demon" + [node name="Sacrificable" parent="." instance=ExtResource("7_lxtqq")] kind = &"Watcher"