GMTK-2024/gmtk_2024/objects/PressurePlate.tscn

90 lines
2.5 KiB
Text
Raw Normal View History

2024-08-19 01:29:43 +02:00
[gd_scene load_steps=8 format=3 uid="uid://c6g2f7tm7iasr"]
[ext_resource type="Script" path="res://scripts/PressurePlate.gd" id="1_7ar3x"]
2024-08-19 18:33:47 +02:00
[ext_resource type="Texture2D" uid="uid://bpfvkxqajd1en" path="res://textures/PressurePlate.png" id="1_st48m"]
2024-08-19 01:29:43 +02:00
[sub_resource type="RectangleShape2D" id="RectangleShape2D_c6ukx"]
2024-08-19 03:15:07 +02:00
size = Vector2(24, 2)
2024-08-19 01:29:43 +02:00
[sub_resource type="Animation" id="Animation_fulu2"]
resource_name = "Disable"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite2D:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
"values": [1]
}
2024-08-19 03:15:07 +02:00
[sub_resource type="Animation" id="Animation_xxdm0"]
resource_name = "Enable"
2024-08-19 01:29:43 +02:00
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite2D:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
2024-08-19 03:15:07 +02:00
"values": [0]
2024-08-19 01:29:43 +02:00
}
2024-08-19 03:15:07 +02:00
[sub_resource type="Animation" id="Animation_7ggr5"]
length = 0.001
2024-08-19 01:29:43 +02:00
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite2D:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
2024-08-19 03:15:07 +02:00
"values": [1]
2024-08-19 01:29:43 +02:00
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_usrhb"]
_data = {
"Disable": SubResource("Animation_fulu2"),
"Enable": SubResource("Animation_xxdm0"),
"RESET": SubResource("Animation_7ggr5")
}
[node name="PressurePlate" type="StaticBody2D"]
2024-08-19 03:15:07 +02:00
collision_layer = 32
collision_mask = 37
2024-08-19 01:29:43 +02:00
script = ExtResource("1_7ar3x")
[node name="Area2D" type="Area2D" parent="."]
2024-08-19 03:15:07 +02:00
collision_layer = 32
2024-08-19 18:33:47 +02:00
collision_mask = 21
2024-08-19 01:29:43 +02:00
[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"]
2024-08-19 03:15:07 +02:00
position = Vector2(0, 11)
2024-08-19 01:29:43 +02:00
shape = SubResource("RectangleShape2D_c6ukx")
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."]
polygon = PackedVector2Array(-16, 16, -12, 12, 12, 12, 16, 16)
[node name="Sprite2D" type="Sprite2D" parent="."]
texture = ExtResource("1_st48m")
hframes = 2
frame = 1
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
libraries = {
"": SubResource("AnimationLibrary_usrhb")
}
autoplay = "Enable"
[connection signal="body_entered" from="Area2D" to="." method="_on_body_entered"]
[connection signal="body_exited" from="Area2D" to="." method="_on_body_exited"]