mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-21 13:23:47 +00:00
Event System
This commit is contained in:
parent
797e24d766
commit
f379eac5c3
10 changed files with 336 additions and 10 deletions
22
Scenes/Interactable/ScriptableAreaTrigger.tscn
Normal file
22
Scenes/Interactable/ScriptableAreaTrigger.tscn
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
[gd_scene load_steps=4 format=3 uid="uid://fxvlaidieiv7"]
|
||||
|
||||
[ext_resource type="Script" path="res://Scripts/Activables/ScriptableBase.cs" id="1_jpwi6"]
|
||||
[ext_resource type="Script" path="res://Scripts/Interactables/AreaTrigger.cs" id="1_l5s1w"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_1nht3"]
|
||||
|
||||
[node name="ScriptableAreaTrigger" type="Node2D"]
|
||||
script = ExtResource("1_jpwi6")
|
||||
Events = Array[Object]([])
|
||||
|
||||
[node name="AreaTrigger" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 2
|
||||
script = ExtResource("1_l5s1w")
|
||||
OneTime = true
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="AreaTrigger"]
|
||||
shape = SubResource("RectangleShape2D_1nht3")
|
||||
|
||||
[connection signal="Activated" from="AreaTrigger" to="." method="Start"]
|
||||
[connection signal="area_entered" from="AreaTrigger" to="AreaTrigger" method="_on_area_entered"]
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
[gd_scene load_steps=46 format=4 uid="uid://bv451a8wgty4u"]
|
||||
[gd_scene load_steps=54 format=4 uid="uid://bv451a8wgty4u"]
|
||||
|
||||
[ext_resource type="Script" path="res://Scripts/GameManager.cs" id="1_8tmoj"]
|
||||
[ext_resource type="PackedScene" uid="uid://bghghp5ep4w2j" path="res://Scenes/player.tscn" id="2_8mh54"]
|
||||
|
|
@ -42,6 +42,10 @@
|
|||
[ext_resource type="PackedScene" uid="uid://d0yes7huiyisw" path="res://Scenes/Items/Blue_Keycard.tscn" id="35_rblsn"]
|
||||
[ext_resource type="PackedScene" uid="uid://r25rq6ijgm6m" path="res://Scenes/Items/Green_Keycard.tscn" id="36_f8fh1"]
|
||||
[ext_resource type="Script" path="res://Scripts/Activables/PlayerMover.cs" id="37_wxy1q"]
|
||||
[ext_resource type="PackedScene" uid="uid://fxvlaidieiv7" path="res://Scenes/Interactable/ScriptableAreaTrigger.tscn" id="43_kf3qc"]
|
||||
[ext_resource type="Script" path="res://Scripts/Resources/Events/MovePlayerEvent.cs" id="44_klwgh"]
|
||||
[ext_resource type="Script" path="res://Scripts/Resources/Events/ActivateEvent.cs" id="45_emjoj"]
|
||||
[ext_resource type="Script" path="res://Scripts/Resources/Events/DialogueStartEvent.cs" id="46_i0omr"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_vuevm"]
|
||||
|
||||
|
|
@ -49,6 +53,31 @@
|
|||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_8wuck"]
|
||||
|
||||
[sub_resource type="Resource" id="Resource_4f4id"]
|
||||
script = ExtResource("44_klwgh")
|
||||
RelativeTargetPosition = Vector2(0, -64)
|
||||
MovementTime = 1.0
|
||||
EaseType = 2
|
||||
TransitionType = 0
|
||||
WaitForCompletion = true
|
||||
|
||||
[sub_resource type="Resource" id="Resource_s2o7m"]
|
||||
script = ExtResource("45_emjoj")
|
||||
ActivationType = 2
|
||||
Targets = Array[NodePath]([NodePath("../Factory Tilemaps/HorizontalDoor3"), NodePath("../Factory Tilemaps/HorizontalDoor5")])
|
||||
WaitForCompletion = true
|
||||
|
||||
[sub_resource type="Resource" id="Resource_b1dht"]
|
||||
script = ExtResource("46_i0omr")
|
||||
TimelineName = "Rumia_Intro"
|
||||
WaitForCompletion = true
|
||||
|
||||
[sub_resource type="Resource" id="Resource_xrgpy"]
|
||||
script = ExtResource("45_emjoj")
|
||||
ActivationType = 0
|
||||
Targets = Array[NodePath]([NodePath("../Rumia")])
|
||||
WaitForCompletion = true
|
||||
|
||||
[node name="GameScene" type="Node2D" node_paths=PackedStringArray("PlayerSpawnMarker")]
|
||||
position = Vector2(38, 39)
|
||||
script = ExtResource("1_8tmoj")
|
||||
|
|
@ -281,7 +310,7 @@ script = ExtResource("25_rpwvt")
|
|||
position = Vector2(-1111, -22)
|
||||
|
||||
[node name="AreaTrigger" parent="." node_paths=PackedStringArray("Target") instance=ExtResource("28_6au4t")]
|
||||
position = Vector2(-1487, -366)
|
||||
position = Vector2(-1357, -356)
|
||||
Target = NodePath("../PlayerMover")
|
||||
OneTime = true
|
||||
|
||||
|
|
@ -376,3 +405,7 @@ position = Vector2(-808, -400)
|
|||
|
||||
[node name="Ammo4" parent="." instance=ExtResource("34_17pjh")]
|
||||
position = Vector2(-791, -401)
|
||||
|
||||
[node name="ScriptableAreaTrigger" parent="." instance=ExtResource("43_kf3qc")]
|
||||
position = Vector2(-1487, -396)
|
||||
Events = Array[Object]([SubResource("Resource_4f4id"), SubResource("Resource_s2o7m"), SubResource("Resource_b1dht"), SubResource("Resource_xrgpy")])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue