Fixed Signals, effects, and collisions.

This commit is contained in:
Alan Youngblood
2025-01-18 12:02:23 -05:00
parent 41db52db5c
commit 3db440b7a9
10 changed files with 231 additions and 149 deletions

View File

@ -1,27 +1,26 @@
[gd_scene load_steps=5 format=2]
[gd_scene load_steps=5 format=3 uid="uid://dr7343qje6tm5"]
[ext_resource path="res://World/Grass.png" type="Texture2D" id=1]
[ext_resource path="res://World/Grass.gd" type="Script" id=2]
[ext_resource path="res://Overlap/Hurtbox.tscn" type="PackedScene" id=3]
[ext_resource type="Texture2D" uid="uid://dy76k7loscspo" path="res://World/Grass.png" id="1"]
[ext_resource type="Script" path="res://World/Grass.gd" id="2"]
[ext_resource type="PackedScene" path="res://Overlap/Hurtbox.tscn" id="3"]
[sub_resource type="RectangleShape2D" id=1]
extents = Vector2( 7, 7 )
[sub_resource type="RectangleShape2D" id="1"]
size = Vector2(14, 14)
[node name="Grass" type="Node2D"]
script = ExtResource( 2 )
script = ExtResource("2")
[node name="Sprite2D" type="Sprite2D" parent="."]
texture = ExtResource( 1 )
texture = ExtResource("1")
centered = false
offset = Vector2( -8, -8 )
offset = Vector2(-8, -8)
[node name="Hurtbox" parent="." instance=ExtResource( 3 )]
collision_layer = 8
show_hit = false
[node name="Hurtbox" parent="." instance=ExtResource("3")]
collision_mask = 2
[node name="CollisionShape2D" parent="Hurtbox" index="0"]
position = Vector2( 8, 8 )
shape = SubResource( 1 )
position = Vector2(8, 8)
shape = SubResource("1")
[connection signal="area_entered" from="Hurtbox" to="." method="_on_Hurtbox_area_entered"]