54 lines
1.8 KiB
Text
54 lines
1.8 KiB
Text
[gd_scene load_steps=8 format=3 uid="uid://h3caql0b6vft"]
|
|
|
|
[ext_resource type="Script" uid="uid://dttgoqksqnsm0" path="res://traps/bear_trap.gd" id="1_u48ys"]
|
|
[ext_resource type="Texture2D" uid="uid://72rbgxwnb0u4" path="res://traps/bear_trap_open.png" id="2_u17g6"]
|
|
[ext_resource type="PackedScene" uid="uid://chs0u61f45nau" path="res://utils/earth_aligner.tscn" id="3_mnxjq"]
|
|
[ext_resource type="Texture2D" uid="uid://ejor11sqt878" path="res://traps/bear_trap_closing.png" id="3_xgq7l"]
|
|
[ext_resource type="Texture2D" uid="uid://ci3qx0v5ksvjv" path="res://traps/bear_trap_closed.png" id="4_phfkt"]
|
|
|
|
[sub_resource type="CircleShape2D" id="CircleShape2D_yh007"]
|
|
radius = 30.0
|
|
|
|
[sub_resource type="SpriteFrames" id="SpriteFrames_3n4a6"]
|
|
animations = [{
|
|
"frames": [{
|
|
"duration": 1.0,
|
|
"texture": ExtResource("2_u17g6")
|
|
}, {
|
|
"duration": 1.0,
|
|
"texture": ExtResource("3_xgq7l")
|
|
}, {
|
|
"duration": 1.0,
|
|
"texture": ExtResource("4_phfkt")
|
|
}],
|
|
"loop": false,
|
|
"name": &"close",
|
|
"speed": 10.0
|
|
}]
|
|
|
|
[node name="BearTrap" type="Node2D"]
|
|
script = ExtResource("1_u48ys")
|
|
player_damage = 2
|
|
enemy_damage = 50
|
|
|
|
[node name="Area2D" type="Area2D" parent="."]
|
|
collision_layer = 0
|
|
collision_mask = 6
|
|
|
|
[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"]
|
|
position = Vector2(0, -15)
|
|
scale = Vector2(1, 0.5)
|
|
shape = SubResource("CircleShape2D_yh007")
|
|
|
|
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
|
modulate = Color(2.1168277, 2.1168277, 2.1168277, 1)
|
|
z_index = 2
|
|
position = Vector2(5.9604645e-08, -37.000004)
|
|
scale = Vector2(0.7, 0.7)
|
|
sprite_frames = SubResource("SpriteFrames_3n4a6")
|
|
animation = &"close"
|
|
|
|
[node name="EarthAligner" parent="." instance=ExtResource("3_mnxjq")]
|
|
|
|
[connection signal="area_entered" from="Area2D" to="." method="_on_area_2d_area_entered"]
|
|
[connection signal="body_entered" from="Area2D" to="." method="_on_area_2d_body_entered"]
|