mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-01 10:35:34 +00:00
Wall emitters and traps
This commit is contained in:
parent
d0181a97f2
commit
ae1ed50043
11 changed files with 261 additions and 5 deletions
|
|
@ -7,7 +7,6 @@
|
|||
|
||||
[node name="ScriptableAreaTrigger" type="Node2D"]
|
||||
script = ExtResource("1_jpwi6")
|
||||
Events = Array[Object]([])
|
||||
|
||||
[node name="AreaTrigger" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
|
|
|
|||
50
Scenes/Interactable/ScriptableMovementSensor.tscn
Normal file
50
Scenes/Interactable/ScriptableMovementSensor.tscn
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
[gd_scene load_steps=8 format=3 uid="uid://oi8svqsspcsj"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://d0a0o50j82eo6" path="res://Scripts/Activables/ScriptableBase.cs" id="1_cpf8e"]
|
||||
[ext_resource type="Script" uid="uid://dmo0pw7natoja" path="res://Scripts/Interactables/AreaTrigger.cs" id="2_xybrs"]
|
||||
[ext_resource type="Texture2D" uid="uid://bs5fsrx07bolj" path="res://Sprites/Actors/MovementSensor.png" id="3_xybrs"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_1nht3"]
|
||||
size = Vector2(4, 30)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_a8ahg"]
|
||||
atlas = ExtResource("3_xybrs")
|
||||
region = Rect2(0, 0, 8, 8)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_5aqpj"]
|
||||
atlas = ExtResource("3_xybrs")
|
||||
region = Rect2(8, 0, 8, 8)
|
||||
|
||||
[sub_resource type="SpriteFrames" id="SpriteFrames_hqdqa"]
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_a8ahg")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_5aqpj")
|
||||
}],
|
||||
"loop": true,
|
||||
"name": &"default",
|
||||
"speed": 5.0
|
||||
}]
|
||||
|
||||
[node name="MovementSensor" type="Node2D"]
|
||||
script = ExtResource("1_cpf8e")
|
||||
|
||||
[node name="AreaTrigger" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 2
|
||||
script = ExtResource("2_xybrs")
|
||||
OneTime = true
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="AreaTrigger"]
|
||||
position = Vector2(0, 15)
|
||||
shape = SubResource("RectangleShape2D_1nht3")
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
sprite_frames = SubResource("SpriteFrames_hqdqa")
|
||||
autoplay = "default"
|
||||
|
||||
[connection signal="Activated" from="AreaTrigger" to="." method="Start"]
|
||||
[connection signal="area_entered" from="AreaTrigger" to="AreaTrigger" method="_on_area_entered"]
|
||||
50
Scenes/Interactable/ScriptableMovementSensorLonger.tscn
Normal file
50
Scenes/Interactable/ScriptableMovementSensorLonger.tscn
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
[gd_scene load_steps=8 format=3 uid="uid://dqr6myj0yaqvd"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://d0a0o50j82eo6" path="res://Scripts/Activables/ScriptableBase.cs" id="1_48f0r"]
|
||||
[ext_resource type="Script" uid="uid://dmo0pw7natoja" path="res://Scripts/Interactables/AreaTrigger.cs" id="2_ms26s"]
|
||||
[ext_resource type="Texture2D" uid="uid://bs5fsrx07bolj" path="res://Sprites/Actors/MovementSensor.png" id="3_7s6mr"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_1nht3"]
|
||||
size = Vector2(4, 62)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_a8ahg"]
|
||||
atlas = ExtResource("3_7s6mr")
|
||||
region = Rect2(0, 0, 8, 8)
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_5aqpj"]
|
||||
atlas = ExtResource("3_7s6mr")
|
||||
region = Rect2(8, 0, 8, 8)
|
||||
|
||||
[sub_resource type="SpriteFrames" id="SpriteFrames_hqdqa"]
|
||||
animations = [{
|
||||
"frames": [{
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_a8ahg")
|
||||
}, {
|
||||
"duration": 1.0,
|
||||
"texture": SubResource("AtlasTexture_5aqpj")
|
||||
}],
|
||||
"loop": true,
|
||||
"name": &"default",
|
||||
"speed": 5.0
|
||||
}]
|
||||
|
||||
[node name="MovementSensorLonger" type="Node2D"]
|
||||
script = ExtResource("1_48f0r")
|
||||
|
||||
[node name="AreaTrigger" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 2
|
||||
script = ExtResource("2_ms26s")
|
||||
OneTime = true
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="AreaTrigger"]
|
||||
position = Vector2(0, 31)
|
||||
shape = SubResource("RectangleShape2D_1nht3")
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
sprite_frames = SubResource("SpriteFrames_hqdqa")
|
||||
autoplay = "default"
|
||||
|
||||
[connection signal="Activated" from="AreaTrigger" to="." method="Start"]
|
||||
[connection signal="area_entered" from="AreaTrigger" to="AreaTrigger" method="_on_area_entered"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue