This commit is contained in:
Jonas Braus
2024-08-04 17:23:08 +02:00
parent 2e845bf217
commit 08f75b79d8
18 changed files with 392 additions and 129 deletions
+27 -1
View File
@@ -1,6 +1,7 @@
[gd_scene load_steps=5 format=3 uid="uid://daaajdv7ve15a"]
[gd_scene load_steps=8 format=3 uid="uid://daaajdv7ve15a"]
[ext_resource type="Texture2D" uid="uid://dth47lmb44qk8" path="res://assets/items.png" id="1_cnc0s"]
[ext_resource type="Script" path="res://scripts/items/jump_thing.gd" id="1_nrv87"]
[sub_resource type="AtlasTexture" id="AtlasTexture_jjx8i"]
atlas = ExtResource("1_cnc0s")
@@ -29,8 +30,33 @@ animations = [{
"speed": 5.0
}]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_mnewg"]
size = Vector2(14, 25)
[sub_resource type="RectangleShape2D" id="RectangleShape2D_luw3y"]
size = Vector2(16, 24)
[node name="jump_thing" type="Node2D"]
script = ExtResource("1_nrv87")
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
position = Vector2(8, -12)
sprite_frames = SubResource("SpriteFrames_1s1v4")
animation = &"down"
autoplay = "default"
[node name="Area2D" type="Area2D" parent="."]
collision_mask = 2
[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"]
position = Vector2(8, -12.5)
shape = SubResource("RectangleShape2D_mnewg")
[node name="StaticBody2D" type="StaticBody2D" parent="."]
[node name="CollisionShape2D" type="CollisionShape2D" parent="StaticBody2D"]
position = Vector2(8, -12)
shape = SubResource("RectangleShape2D_luw3y")
[connection signal="body_entered" from="Area2D" to="." method="_on_area_2d_body_entered"]
[connection signal="body_exited" from="Area2D" to="." method="_on_area_2d_body_exited"]