Inheritance cleared
This commit is contained in:
parent
38dc6ec4d2
commit
76ab2727de
18 changed files with 3396 additions and 763 deletions
|
|
@ -1,19 +1,13 @@
|
|||
[gd_scene load_steps=23 format=3 uid="uid://bw1w8jp0yeypy"]
|
||||
[gd_scene load_steps=24 format=3 uid="uid://bw1w8jp0yeypy"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_n25yi"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_dm0tl"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_8fr1j"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_aimqk"]
|
||||
[ext_resource type="Texture2D" uid="uid://b6tyoa5htapir" path="res://assets/sprites/atlases/plants/aloe.png" id="2_iup5p"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://bgutjc3ruq27s" path="res://assets/animations/plants/aloe.res" id="3_3sp3b"]
|
||||
[ext_resource type="Script" uid="uid://cljytsmqac0w7" path="res://scripts/entities/plants/behaviours/AloeBehaviour.cs" id="4_55asm"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="4_aimqk"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="5_gfy6j"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_8fr1j"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_dm0tl")
|
||||
shader_parameter/FLASH_COLOR = Color(1, 0.709804, 0.439216, 0.5)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(1, 0.709804, 0.439216, 0.5)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="7_vpcbp"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_vknky"]
|
||||
length = 0.001
|
||||
|
|
@ -103,43 +97,54 @@ node_connections = [&"TimeScale", 0, &"Tree", &"output", 0, &"TimeScale"]
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_oe0dc"]
|
||||
size = Vector2(22, 32)
|
||||
|
||||
[node name="Aloe" instance=ExtResource("1_n25yi")]
|
||||
GetInternalID() = "aloe"
|
||||
[node name="Aloe" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_8fr1j")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_8fr1j")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_aimqk")
|
||||
position = Vector2(9, -14)
|
||||
texture = ExtResource("2_iup5p")
|
||||
hframes = 8
|
||||
vframes = 4
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_wlien"),
|
||||
&"aloe": ExtResource("3_3sp3b")
|
||||
}
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_gfy6j")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/conditions/charged = false
|
||||
parameters/Tree/conditions/heal = false
|
||||
script = ExtResource("4_aimqk")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="3"]
|
||||
[node name="Behaviour" type="Node" parent="."]
|
||||
script = ExtResource("4_55asm")
|
||||
_hpTreshold = 0.5
|
||||
|
||||
[node name="Timer" type="Timer" parent="Behaviour" index="0" node_paths=PackedStringArray("entity")]
|
||||
[node name="Timer" type="Timer" parent="Behaviour" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 15.0
|
||||
one_shot = true
|
||||
script = ExtResource("5_gfy6j")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
shape = SubResource("RectangleShape2D_oe0dc")
|
||||
|
||||
[node name="FlashController" parent="." index="5"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_8fr1j")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("7_vpcbp")
|
||||
shaderMaterial = ExtResource("2_aimqk")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="timeout" from="Behaviour/Timer" to="Behaviour" method="OnTimeout"]
|
||||
|
|
|
|||
|
|
@ -1,21 +1,15 @@
|
|||
[gd_scene load_steps=25 format=3 uid="uid://cjoyh54cpjla7"]
|
||||
[gd_scene load_steps=26 format=3 uid="uid://cjoyh54cpjla7"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_65f4u"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_xwpd6"]
|
||||
[ext_resource type="Texture2D" uid="uid://bt76iudw2qgnv" path="res://assets/sprites/atlases/plants/cumbucer.png" id="2_ig0op"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_jbggv"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_q31qc"]
|
||||
[ext_resource type="Script" uid="uid://dn53jvpjyg63l" path="res://scripts/entities/plants/Eyesight.cs" id="3_d45iq"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="3_q31qc"]
|
||||
[ext_resource type="Script" uid="uid://ceprqkraw3v6m" path="res://scripts/entities/plants/Shooter.cs" id="4_sckvu"]
|
||||
[ext_resource type="PackedScene" uid="uid://c1ig40gtdcb60" path="res://scenes/projectiles/cucumber_projectile.tscn" id="5_sckvu"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="6_xwpd6"]
|
||||
[ext_resource type="Script" uid="uid://bdk5iqtw4xbkl" path="res://scripts/entities/plants/behaviours/PeashooterBehaviour.cs" id="7_q31qc"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_jbggv"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_jbggv")
|
||||
shader_parameter/FLASH_COLOR = Color(0.78, 0.78, 0.78, 0.501961)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(0.69, 0, 0, 0.282353)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="9_a66ro"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_n1xkd"]
|
||||
length = 0.001
|
||||
|
|
@ -118,7 +112,6 @@ transitions = ["Start", "cucumber_idle", SubResource("AnimationNodeStateMachineT
|
|||
graph_offset = Vector2(137, -3)
|
||||
|
||||
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_xwpd6"]
|
||||
graph_offset = Vector2(-370, 72)
|
||||
nodes/TimeScale/node = SubResource("AnimationNodeTimeScale_ig0op")
|
||||
nodes/TimeScale/position = Vector2(60, 140)
|
||||
nodes/Tree/node = SubResource("AnimationNodeStateMachine_jbggv")
|
||||
|
|
@ -132,54 +125,67 @@ height = 48.0
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_n1xkd"]
|
||||
size = Vector2(26, 600)
|
||||
|
||||
[node name="Cucumber" instance=ExtResource("1_65f4u")]
|
||||
GetInternalID() = "cucumber"
|
||||
[node name="Cucumber" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
material = ExtResource("2_q31qc")
|
||||
script = ExtResource("1_xwpd6")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_jbggv")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_q31qc")
|
||||
texture = ExtResource("2_ig0op")
|
||||
hframes = 10
|
||||
vframes = 2
|
||||
frame = 10
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_gogcg"),
|
||||
&"cucumber": SubResource("AnimationLibrary_n1xkd")
|
||||
}
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_xwpd6")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/conditions/ready = false
|
||||
script = ExtResource("3_q31qc")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
shape = SubResource("CapsuleShape2D_ig0op")
|
||||
|
||||
[node name="Eysight" type="Area2D" parent="." index="4"]
|
||||
[node name="Eysight" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 8
|
||||
script = ExtResource("3_d45iq")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Eysight" index="0"]
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Eysight"]
|
||||
shape = SubResource("RectangleShape2D_n1xkd")
|
||||
|
||||
[node name="Shooter" type="Marker2D" parent="." index="5" node_paths=PackedStringArray("_timer")]
|
||||
[node name="Shooter" type="Marker2D" parent="." node_paths=PackedStringArray("_timer")]
|
||||
script = ExtResource("4_sckvu")
|
||||
_projectile = ExtResource("5_sckvu")
|
||||
_timer = NodePath("FireTimer")
|
||||
|
||||
[node name="FireTimer" type="Timer" parent="Shooter" index="0" node_paths=PackedStringArray("entity")]
|
||||
[node name="FireTimer" type="Timer" parent="Shooter" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 2.5
|
||||
one_shot = true
|
||||
script = ExtResource("6_xwpd6")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="6" node_paths=PackedStringArray("_shootTimer", "_sight")]
|
||||
[node name="Behaviour" type="Node" parent="." node_paths=PackedStringArray("_shootTimer", "_sight")]
|
||||
script = ExtResource("7_q31qc")
|
||||
_shootTimer = NodePath("../Shooter/FireTimer")
|
||||
_sight = NodePath("../Eysight")
|
||||
|
||||
[node name="FlashController" parent="." index="7"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_jbggv")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("9_a66ro")
|
||||
shaderMaterial = ExtResource("2_q31qc")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
|
|
|
|||
|
|
@ -1,11 +1,14 @@
|
|||
[gd_scene load_steps=16 format=3 uid="uid://qq0cw8xtcoj3"]
|
||||
[gd_scene load_steps=19 format=3 uid="uid://qq0cw8xtcoj3"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_5i0e6"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_gu3kj"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_1angc"]
|
||||
[ext_resource type="Texture2D" uid="uid://dff73m8ahamaa" path="res://assets/sprites/atlases/plants/garlic.png" id="2_w2jbi"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://cjl81f61gdlvi" path="res://assets/animations/plants/garlic.res" id="3_jkb3q"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="4_1angc"]
|
||||
[ext_resource type="Script" uid="uid://btkmd86pn828y" path="res://scripts/entities/plants/behaviours/HpBasedBehaviour.cs" id="4_bv44h"]
|
||||
[ext_resource type="Script" uid="uid://bmtukcq10m8wo" path="res://scripts/entities/plants/ReturnEffect.cs" id="5_oob20"]
|
||||
[ext_resource type="Resource" uid="uid://dsg1vjx76ifgu" path="res://assets/effects/RandomRedirectEffect.tres" id="6_gho1l"]
|
||||
[ext_resource type="Resource" uid="uid://dsg1vjx76ifgu" path="res://assets/effects/GarlicEffect.tres" id="6_gho1l"]
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="8_6iwlp"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_k0cex"]
|
||||
length = 0.001
|
||||
|
|
@ -59,37 +62,52 @@ node_connections = [&"TimeScale", 0, &"Tree", &"output", 0, &"TimeScale"]
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_thlvs"]
|
||||
size = Vector2(32, 29)
|
||||
|
||||
[node name="Garlic" instance=ExtResource("1_5i0e6")]
|
||||
GetInternalID() = "garlic"
|
||||
[node name="Garlic" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_gu3kj")
|
||||
MaxHP = 200.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_1angc")
|
||||
texture = ExtResource("2_w2jbi")
|
||||
hframes = 8
|
||||
vframes = 3
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_v4l78"),
|
||||
&"garlic": ExtResource("3_jkb3q")
|
||||
}
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_2o7sr")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/blend_position = 1.0
|
||||
script = ExtResource("4_1angc")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(1, 11.5)
|
||||
shape = SubResource("RectangleShape2D_thlvs")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="4"]
|
||||
[node name="Behaviour" type="Node" parent="."]
|
||||
script = ExtResource("4_bv44h")
|
||||
parameters = Array[String](["parameters/Tree/blend_position"])
|
||||
|
||||
[node name="ReturnEffect" type="Node" parent="." index="5"]
|
||||
[node name="ReturnEffect" type="Node" parent="."]
|
||||
script = ExtResource("5_oob20")
|
||||
_effectToReturn = ExtResource("6_gho1l")
|
||||
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("8_6iwlp")
|
||||
shaderMaterial = ExtResource("2_1angc")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="OnHPChanged" from="." to="Behaviour" method="OnHPChanged"]
|
||||
[connection signal="OnHPChanged" from="." to="ReturnEffect" method="OnDamageRecieved"]
|
||||
|
|
|
|||
|
|
@ -1,10 +1,13 @@
|
|||
[gd_scene load_steps=31 format=3 uid="uid://k5aj2slxar7w"]
|
||||
[gd_scene load_steps=34 format=3 uid="uid://k5aj2slxar7w"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_8ui1h"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_o12iv"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_6e60l"]
|
||||
[ext_resource type="Texture2D" uid="uid://b06e8xhdy77d1" path="res://assets/sprites/atlases/plants/nerdus.png" id="2_614v4"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="3_6e60l"]
|
||||
[ext_resource type="Script" uid="uid://dcokqes5wwo3k" path="res://scripts/entities/plants/NerdusReturnAttack.cs" id="3_614v4"]
|
||||
[ext_resource type="Resource" uid="uid://dme4nvp28otq6" path="res://assets/effects/NerdusEffect.tres" id="4_ga4vy"]
|
||||
[ext_resource type="Script" uid="uid://btkmd86pn828y" path="res://scripts/entities/plants/behaviours/HpBasedBehaviour.cs" id="5_o1ggp"]
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="7_v7ffp"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_ga4vy"]
|
||||
length = 0.001
|
||||
|
|
@ -251,46 +254,61 @@ radius = 24.0
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_ga4vy"]
|
||||
size = Vector2(73, 48)
|
||||
|
||||
[node name="Nerdus" instance=ExtResource("1_8ui1h")]
|
||||
GetInternalID() = "nerdus"
|
||||
[node name="Nerdus" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_o12iv")
|
||||
MaxHP = 200.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_6e60l")
|
||||
texture = ExtResource("2_614v4")
|
||||
hframes = 7
|
||||
vframes = 6
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_o1ggp"),
|
||||
&"nerdus": SubResource("AnimationLibrary_pddnl")
|
||||
}
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_6a4q1")
|
||||
advance_expression_base_node = NodePath("../Hurtbox")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/Attack/blend_position = 1.0
|
||||
parameters/Tree/Idle/blend_position = 1.0
|
||||
script = ExtResource("3_6e60l")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(0, 3)
|
||||
shape = SubResource("CircleShape2D_8ui1h")
|
||||
|
||||
[node name="Hurtbox" type="Area2D" parent="." index="4"]
|
||||
[node name="Hurtbox" type="Area2D" parent="."]
|
||||
collision_layer = 0
|
||||
collision_mask = 8
|
||||
script = ExtResource("3_614v4")
|
||||
returnEffect = ExtResource("4_ga4vy")
|
||||
bitesToPeas = 1.6
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hurtbox" index="0"]
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hurtbox"]
|
||||
position = Vector2(3.5, 3)
|
||||
shape = SubResource("RectangleShape2D_ga4vy")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="5"]
|
||||
[node name="Behaviour" type="Node" parent="."]
|
||||
script = ExtResource("5_o1ggp")
|
||||
parameters = Array[String](["parameters/Tree/Attack/blend_position", "parameters/Tree/Idle/blend_position"])
|
||||
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("7_v7ffp")
|
||||
shaderMaterial = ExtResource("2_6e60l")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="OnHPChanged" from="." to="Hurtbox" method="OnHPChanged"]
|
||||
[connection signal="OnHPChanged" from="." to="Behaviour" method="OnHPChanged"]
|
||||
|
|
|
|||
|
|
@ -1,25 +1,19 @@
|
|||
[gd_scene load_steps=26 format=3 uid="uid://dy41q1kxray5t"]
|
||||
[gd_scene load_steps=27 format=3 uid="uid://dy41q1kxray5t"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_pyk3o"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_p4cd5"]
|
||||
[ext_resource type="Texture2D" uid="uid://cksryh4w5dbbx" path="res://assets/sprites/atlases/plants/peashooter.png" id="2_14qlx"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_fp65y"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_p4cd5"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://bv1dl1g4dmbho" path="res://assets/animations/plants/peashooter.res" id="3_8lrhp"]
|
||||
[ext_resource type="Script" uid="uid://ceprqkraw3v6m" path="res://scripts/entities/plants/Shooter.cs" id="3_a4ew1"]
|
||||
[ext_resource type="PackedScene" uid="uid://b2hrv0aqbui7u" path="res://scenes/projectiles/pea.tscn" id="4_saxds"]
|
||||
[ext_resource type="Script" uid="uid://bdk5iqtw4xbkl" path="res://scripts/entities/plants/behaviours/PeashooterBehaviour.cs" id="5_7qiua"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="5_ceium"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="6_q58jr"]
|
||||
[ext_resource type="Script" uid="uid://dn53jvpjyg63l" path="res://scripts/entities/plants/Eyesight.cs" id="7_2bki8"]
|
||||
[ext_resource type="Script" uid="uid://hccb0aee0x0o" path="res://scripts/entities/plants/PlantEyesightLimiter.cs" id="8_nl4jc"]
|
||||
[ext_resource type="Script" uid="uid://c36bj8u7jghc7" path="res://scripts/audio/ChannelPlayer.cs" id="9_mbbd7"]
|
||||
[ext_resource type="AudioStream" uid="uid://dsv81mvrdg3w3" path="res://assets/audio/sfx/throw_generic.tres" id="10_q58jr"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_fp65y"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_fp65y")
|
||||
shader_parameter/FLASH_COLOR = Color(0.78, 0.78, 0.78, 0.501961)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(0.69, 0, 0, 0.282353)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="14_dmys5"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_a2y0j"]
|
||||
length = 0.001
|
||||
|
|
@ -81,63 +75,75 @@ resource_local_to_scene = true
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_r7xnh"]
|
||||
size = Vector2(20, 44)
|
||||
|
||||
[node name="Peashooter" instance=ExtResource("1_pyk3o")]
|
||||
GetInternalID() = "peashooter"
|
||||
[node name="Peashooter" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_p4cd5")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_fp65y")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_p4cd5")
|
||||
texture = ExtResource("2_14qlx")
|
||||
hframes = 10
|
||||
vframes = 2
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_ipp6b"),
|
||||
&"peashooter": ExtResource("3_8lrhp")
|
||||
}
|
||||
autoplay = "peashooter/idle"
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_q58jr")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/conditions/ready = false
|
||||
script = ExtResource("5_ceium")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Shooter" type="Marker2D" parent="." index="3" node_paths=PackedStringArray("_timer")]
|
||||
[node name="Shooter" type="Marker2D" parent="." node_paths=PackedStringArray("_timer")]
|
||||
position = Vector2(12, -4)
|
||||
script = ExtResource("3_a4ew1")
|
||||
_projectile = ExtResource("4_saxds")
|
||||
_timer = NodePath("FireTimer")
|
||||
|
||||
[node name="FireTimer" type="Timer" parent="Shooter" index="0" node_paths=PackedStringArray("entity")]
|
||||
[node name="FireTimer" type="Timer" parent="Shooter" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 1.5
|
||||
one_shot = true
|
||||
script = ExtResource("6_q58jr")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="4" node_paths=PackedStringArray("_shootTimer", "_sight")]
|
||||
[node name="Behaviour" type="Node" parent="." node_paths=PackedStringArray("_shootTimer", "_sight")]
|
||||
script = ExtResource("5_7qiua")
|
||||
_shootTimer = NodePath("../Shooter/FireTimer")
|
||||
_sight = NodePath("../Eysight")
|
||||
|
||||
[node name="Eysight" type="Area2D" parent="." index="5"]
|
||||
[node name="Eysight" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 8
|
||||
script = ExtResource("7_2bki8")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Eysight" index="0"]
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Eysight"]
|
||||
shape = SubResource("SegmentShape2D_8iovl")
|
||||
script = ExtResource("8_nl4jc")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(0, 5)
|
||||
shape = SubResource("RectangleShape2D_r7xnh")
|
||||
|
||||
[node name="ChannelPlayer" type="Node" parent="." index="7"]
|
||||
[node name="ChannelPlayer" type="Node" parent="."]
|
||||
script = ExtResource("9_mbbd7")
|
||||
audioStream = ExtResource("10_q58jr")
|
||||
channel = "pea_shoot"
|
||||
metadata/_custom_type_script = "uid://c36bj8u7jghc7"
|
||||
|
||||
[node name="FlashController" parent="." index="8"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_fp65y")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("14_dmys5")
|
||||
shaderMaterial = ExtResource("2_p4cd5")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
|
|
|
|||
|
|
@ -1,24 +1,18 @@
|
|||
[gd_scene load_steps=29 format=3 uid="uid://b5x35v3w2u8dx"]
|
||||
[gd_scene load_steps=30 format=3 uid="uid://b5x35v3w2u8dx"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_dj7ul"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_lx7n5"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_a0d1l"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_a0d1l"]
|
||||
[ext_resource type="Texture2D" uid="uid://c77o6ba0mw7a3" path="res://assets/sprites/atlases/plants/potato_mine.png" id="2_sneas"]
|
||||
[ext_resource type="Script" uid="uid://bhl6o2m3fn4xg" path="res://scripts/entities/plants/ExplosionComponent.cs" id="3_2hd5y"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://bjlbdvr6f0r7e" path="res://assets/animations/plants/potato_mine.res" id="3_7tqmj"]
|
||||
[ext_resource type="Script" uid="uid://c7qfh4py0uulo" path="res://scripts/entities/plants/behaviours/PotatomineBehaviour.cs" id="4_twx65"]
|
||||
[ext_resource type="PackedScene" uid="uid://ckanq33rao1ur" path="res://scenes/particles/potato_explosion.tscn" id="5_px4r0"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="5_v27q1"]
|
||||
[ext_resource type="Script" uid="uid://c36bj8u7jghc7" path="res://scripts/audio/ChannelPlayer.cs" id="7_b1j2f"]
|
||||
[ext_resource type="AudioStream" uid="uid://dltjtpyfr1so0" path="res://assets/audio/sfx/potato_mine.mp3" id="8_3vqdc"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="8_824aq"]
|
||||
[ext_resource type="AudioStream" uid="uid://b27om1bw1x04e" path="res://assets/audio/sfx/dirt_rise.mp3" id="9_3vqdc"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_crloj"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_lx7n5")
|
||||
shader_parameter/FLASH_COLOR = Color(0.78, 0.78, 0.78, 0.501961)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(0.69, 0, 0, 0.282353)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="13_cfvur"]
|
||||
|
||||
[sub_resource type="AnimationNodeTimeScale" id="AnimationNodeTimeScale_3vqdc"]
|
||||
|
||||
|
|
@ -86,85 +80,96 @@ size = Vector2(15, 27)
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_ti2g4"]
|
||||
size = Vector2(22, 19)
|
||||
|
||||
[node name="Potato mine" instance=ExtResource("1_dj7ul")]
|
||||
GetInternalID() = "potatomine"
|
||||
[node name="Potato mine" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_a0d1l")
|
||||
MaxHP = 20.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_crloj")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_a0d1l")
|
||||
texture = ExtResource("2_sneas")
|
||||
hframes = 7
|
||||
vframes = 4
|
||||
frame = 7
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"potato_mine": ExtResource("3_7tqmj")
|
||||
}
|
||||
autoplay = "idle_unprimed"
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_824aq")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/conditions/explode = false
|
||||
parameters/Tree/conditions/primed = false
|
||||
script = ExtResource("5_v27q1")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Detectionbox" type="Area2D" parent="." index="3"]
|
||||
[node name="Detectionbox" type="Area2D" parent="."]
|
||||
collision_layer = 0
|
||||
collision_mask = 8
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Detectionbox" index="0"]
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Detectionbox"]
|
||||
position = Vector2(0, 9)
|
||||
shape = SubResource("CircleShape2D_824aq")
|
||||
|
||||
[node name="ExplosionBox" type="Area2D" parent="." index="4"]
|
||||
[node name="ExplosionBox" type="Area2D" parent="."]
|
||||
collision_layer = 0
|
||||
collision_mask = 8
|
||||
script = ExtResource("3_2hd5y")
|
||||
damage = 6000
|
||||
particles = ExtResource("5_px4r0")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="ExplosionBox" index="0"]
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="ExplosionBox"]
|
||||
position = Vector2(0, 9)
|
||||
shape = SubResource("CircleShape2D_wvns6")
|
||||
|
||||
[node name="ExplosionPlayer" type="Node" parent="ExplosionBox" index="1"]
|
||||
[node name="ExplosionPlayer" type="Node" parent="ExplosionBox"]
|
||||
script = ExtResource("7_b1j2f")
|
||||
audioStream = ExtResource("8_3vqdc")
|
||||
channel = "explosion"
|
||||
metadata/_custom_type_script = "uid://c36bj8u7jghc7"
|
||||
|
||||
[node name="PrimeTimer" type="Timer" parent="." index="5" node_paths=PackedStringArray("entity")]
|
||||
[node name="PrimeTimer" type="Timer" parent="." node_paths=PackedStringArray("entity")]
|
||||
wait_time = 15.0
|
||||
one_shot = true
|
||||
autostart = true
|
||||
script = ExtResource("8_824aq")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="6" node_paths=PackedStringArray("_hitbox", "detectionBox", "_unprimedShape", "_primedShape")]
|
||||
[node name="Behaviour" type="Node" parent="." node_paths=PackedStringArray("_hitbox", "detectionBox", "_unprimedShape", "_primedShape")]
|
||||
script = ExtResource("4_twx65")
|
||||
_hitbox = NodePath("../Hitbox")
|
||||
detectionBox = NodePath("../Detectionbox")
|
||||
_unprimedShape = NodePath("../Hitbox/Unprimed")
|
||||
_primedShape = NodePath("../Hitbox/Primed")
|
||||
|
||||
[node name="Unprimed" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="Unprimed" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(-0.5, 14.5)
|
||||
shape = SubResource("RectangleShape2D_qfqko")
|
||||
|
||||
[node name="Primed" type="CollisionShape2D" parent="Hitbox" index="1"]
|
||||
[node name="Primed" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(0, 16.5)
|
||||
shape = SubResource("RectangleShape2D_ti2g4")
|
||||
disabled = true
|
||||
|
||||
[node name="ChannelPlayer" type="Node" parent="." index="8"]
|
||||
[node name="ChannelPlayer" type="Node" parent="."]
|
||||
script = ExtResource("7_b1j2f")
|
||||
audioStream = ExtResource("9_3vqdc")
|
||||
channel = "plant_rise"
|
||||
metadata/_custom_type_script = "uid://c36bj8u7jghc7"
|
||||
|
||||
[node name="FlashController" parent="." index="9"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_crloj")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("13_cfvur")
|
||||
shaderMaterial = ExtResource("2_a0d1l")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="area_entered" from="Detectionbox" to="Behaviour" method="OnAreaEntered"]
|
||||
[connection signal="timeout" from="PrimeTimer" to="Behaviour" method="Prime"]
|
||||
|
|
|
|||
|
|
@ -1,21 +1,15 @@
|
|||
[gd_scene load_steps=13 format=3 uid="uid://bmk41n57j7hgx"]
|
||||
[gd_scene load_steps=14 format=3 uid="uid://bmk41n57j7hgx"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_ltcu2"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_ktw4a"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_moq7q"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_moq7q"]
|
||||
[ext_resource type="Texture2D" uid="uid://dvldjlg0nr355" path="res://assets/sprites/atlases/atlas1.png" id="3_ktw4a"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="4_4ermv"]
|
||||
[ext_resource type="Script" uid="uid://cu63aiowp5bqd" path="res://scripts/entities/plants/DragAction.cs" id="4_5jowj"]
|
||||
[ext_resource type="Script" uid="uid://co7ttejdo2qot" path="res://scripts/entities/plants/AreaAttack.cs" id="5_twsk4"]
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="6_4uf0y"]
|
||||
[ext_resource type="Script" uid="uid://csgksiyma0h4t" path="res://scripts/entities/plants/behaviours/SnipachBehaviour.cs" id="6_twsk4"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="7_3hyni"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_f4wwx"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_ktw4a")
|
||||
shader_parameter/FLASH_COLOR = Color(0.78, 0.78, 0.78, 0.501961)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(0.69, 0, 0, 0.282353)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_f4wwx"]
|
||||
atlas = ExtResource("3_ktw4a")
|
||||
region = Rect2(525, 241, 79, 72)
|
||||
|
|
@ -30,26 +24,40 @@ region = Rect2(592, 64, 50, 60)
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_5jowj"]
|
||||
size = Vector2(40, 36)
|
||||
|
||||
[node name="Snipach" instance=ExtResource("1_ltcu2")]
|
||||
GetInternalID() = "snipach"
|
||||
[node name="Snipach" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_moq7q")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_f4wwx")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_moq7q")
|
||||
position = Vector2(8, -16)
|
||||
texture = SubResource("AtlasTexture_f4wwx")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
script = ExtResource("4_4ermv")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(-0.75, -2.5)
|
||||
shape = SubResource("RectangleShape2D_ktw4a")
|
||||
|
||||
[node name="DragAction" type="Node" parent="Hitbox" index="1"]
|
||||
[node name="DragAction" type="Node" parent="Hitbox"]
|
||||
script = ExtResource("4_5jowj")
|
||||
|
||||
[node name="FlashController" parent="." index="4"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_f4wwx")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("6_4uf0y")
|
||||
shaderMaterial = ExtResource("2_moq7q")
|
||||
|
||||
[node name="ShootBox" type="Area2D" parent="." index="5"]
|
||||
[node name="ShootBox" type="Area2D" parent="."]
|
||||
visible = false
|
||||
collision_layer = 32
|
||||
collision_mask = 24
|
||||
|
|
@ -57,29 +65,30 @@ input_pickable = false
|
|||
script = ExtResource("5_twsk4")
|
||||
_damage = 400
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="ShootBox" index="0"]
|
||||
[node name="Sprite2D" type="Sprite2D" parent="ShootBox"]
|
||||
texture = SubResource("AtlasTexture_3hyni")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="ShootBox" index="1"]
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="ShootBox"]
|
||||
shape = SubResource("RectangleShape2D_5jowj")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="6" node_paths=PackedStringArray("attackBox", "timer", "guardTimer")]
|
||||
[node name="Behaviour" type="Node" parent="." node_paths=PackedStringArray("attackBox", "timer", "guardTimer")]
|
||||
script = ExtResource("6_twsk4")
|
||||
attackBox = NodePath("../ShootBox")
|
||||
timer = NodePath("Timer")
|
||||
guardTimer = NodePath("GuardTimer")
|
||||
|
||||
[node name="Timer" type="Timer" parent="Behaviour" index="0" node_paths=PackedStringArray("entity")]
|
||||
[node name="Timer" type="Timer" parent="Behaviour" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 15.0
|
||||
one_shot = true
|
||||
script = ExtResource("7_3hyni")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="GuardTimer" type="Timer" parent="Behaviour" index="1"]
|
||||
[node name="GuardTimer" type="Timer" parent="Behaviour"]
|
||||
wait_time = 0.2
|
||||
one_shot = true
|
||||
autostart = true
|
||||
ignore_time_scale = true
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="DragBegin" from="Hitbox/DragAction" to="Behaviour" method="OnDragBegin"]
|
||||
[connection signal="DragEnd" from="Hitbox/DragAction" to="Behaviour" method="OnDragEnd"]
|
||||
|
|
|
|||
|
|
@ -1,18 +1,19 @@
|
|||
[gd_scene load_steps=18 format=3 uid="uid://b7innrovtmf5u"]
|
||||
[gd_scene load_steps=27 format=3 uid="uid://b7innrovtmf5u"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dy41q1kxray5t" path="res://scenes/entities/plants/peashooter.tscn" id="1_lp85e"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_klsgb"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_klsgb"]
|
||||
[ext_resource type="Texture2D" uid="uid://cu0651pvvkmvm" path="res://assets/sprites/atlases/plants/snow_pea.png" id="2_ytrm0"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_yyg2a"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://cke5wmmrvevbs" path="res://assets/animations/plants/snowpea.res" id="4_jvx5y"]
|
||||
[ext_resource type="PackedScene" uid="uid://domeukw4ucmyr" path="res://scenes/projectiles/snowpea_projectile.tscn" id="5_bv86m"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_g872w"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_yyg2a")
|
||||
shader_parameter/FLASH_COLOR = Color(0.78, 0.78, 0.78, 0.501961)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(0.69, 0, 0, 0.282353)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="5_fbp2l"]
|
||||
[ext_resource type="Script" uid="uid://ceprqkraw3v6m" path="res://scripts/entities/plants/Shooter.cs" id="6_br16s"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="8_bjd0y"]
|
||||
[ext_resource type="Script" uid="uid://bdk5iqtw4xbkl" path="res://scripts/entities/plants/behaviours/PeashooterBehaviour.cs" id="9_hg126"]
|
||||
[ext_resource type="Script" uid="uid://dn53jvpjyg63l" path="res://scripts/entities/plants/Eyesight.cs" id="10_noqdw"]
|
||||
[ext_resource type="Script" uid="uid://hccb0aee0x0o" path="res://scripts/entities/plants/PlantEyesightLimiter.cs" id="11_terbf"]
|
||||
[ext_resource type="Script" uid="uid://c36bj8u7jghc7" path="res://scripts/audio/ChannelPlayer.cs" id="12_dvoqf"]
|
||||
[ext_resource type="AudioStream" uid="uid://dsv81mvrdg3w3" path="res://assets/audio/sfx/throw_generic.tres" id="13_o05jr"]
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="14_oijop"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_pephc"]
|
||||
length = 0.001
|
||||
|
|
@ -71,28 +72,78 @@ node_connections = [&"TimeScale", 0, &"Tree", &"output", 0, &"TimeScale"]
|
|||
[sub_resource type="SegmentShape2D" id="SegmentShape2D_3oyhk"]
|
||||
resource_local_to_scene = true
|
||||
|
||||
[node name="Snowpea" instance=ExtResource("1_lp85e")]
|
||||
GetInternalID() = "snowpea"
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_r7xnh"]
|
||||
size = Vector2(20, 44)
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_g872w")
|
||||
[node name="Snowpea" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_klsgb")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_klsgb")
|
||||
texture = ExtResource("2_ytrm0")
|
||||
hframes = 10
|
||||
vframes = 2
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_djmlc"),
|
||||
&"snowpea": ExtResource("4_jvx5y")
|
||||
}
|
||||
autoplay = "snowpea/idle"
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_3oyhk")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/conditions/ready = false
|
||||
script = ExtResource("5_fbp2l")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Shooter" parent="." index="3"]
|
||||
[node name="Shooter" type="Marker2D" parent="." node_paths=PackedStringArray("_timer")]
|
||||
position = Vector2(12, -4)
|
||||
script = ExtResource("6_br16s")
|
||||
_projectile = ExtResource("5_bv86m")
|
||||
_timer = NodePath("FireTimer")
|
||||
|
||||
[node name="CollisionShape2D" parent="Eysight" index="0"]
|
||||
[node name="FireTimer" type="Timer" parent="Shooter" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 1.5
|
||||
one_shot = true
|
||||
script = ExtResource("8_bjd0y")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." node_paths=PackedStringArray("_shootTimer", "_sight")]
|
||||
script = ExtResource("9_hg126")
|
||||
_shootTimer = NodePath("../Shooter/FireTimer")
|
||||
_sight = NodePath("../Eysight")
|
||||
|
||||
[node name="Eysight" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 8
|
||||
script = ExtResource("10_noqdw")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Eysight"]
|
||||
shape = SubResource("SegmentShape2D_3oyhk")
|
||||
script = ExtResource("11_terbf")
|
||||
|
||||
[node name="FlashController" parent="." index="8"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_g872w")
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(0, 5)
|
||||
shape = SubResource("RectangleShape2D_r7xnh")
|
||||
|
||||
[node name="ChannelPlayer" type="Node" parent="."]
|
||||
script = ExtResource("12_dvoqf")
|
||||
audioStream = ExtResource("13_o05jr")
|
||||
channel = "pea_shoot"
|
||||
metadata/_custom_type_script = "uid://c36bj8u7jghc7"
|
||||
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("14_oijop")
|
||||
shaderMaterial = ExtResource("2_klsgb")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
|
|
|
|||
|
|
@ -1,20 +1,14 @@
|
|||
[gd_scene load_steps=15 format=3 uid="uid://bdhod5c6o53ha"]
|
||||
[gd_scene load_steps=16 format=3 uid="uid://bdhod5c6o53ha"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_vmbvr"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_63okc"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_kd62n"]
|
||||
[ext_resource type="Texture2D" uid="uid://coafh3mjharxo" path="res://assets/sprites/atlases/plants/spikeweed.png" id="2_ffrjr"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_kd62n"]
|
||||
[ext_resource type="Script" uid="uid://co7ttejdo2qot" path="res://scripts/entities/plants/AreaAttack.cs" id="3_hqtbm"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://cen6ku4y01dyg" path="res://assets/animations/plants/spikeweed.res" id="3_nwshn"]
|
||||
[ext_resource type="Script" uid="uid://dqquodxaijmem" path="res://scripts/entities/plants/behaviours/SpikeweedBehaviour.cs" id="3_uhpn7"]
|
||||
[ext_resource type="Script" uid="uid://dw7v3s4kbu7ma" path="res://scripts/entities/AnimationStatistics.cs" id="5_yfuxj"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_yfuxj"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_63okc")
|
||||
shader_parameter/FLASH_COLOR = Color(0.78, 0.78, 0.78, 0.501961)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(0.69, 0, 0, 0.282353)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="6_sqcsr"]
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="9_lq7xg"]
|
||||
|
||||
[sub_resource type="AnimationNodeTimeScale" id="AnimationNodeTimeScale_jleqa"]
|
||||
|
||||
|
|
@ -45,47 +39,54 @@ node_connections = [&"TimeScale", 0, &"Tree", &"output", 0, &"TimeScale"]
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_1di76"]
|
||||
size = Vector2(49, 38)
|
||||
|
||||
[node name="Spikeweed" instance=ExtResource("1_vmbvr")]
|
||||
GetInternalID() = "spikeweed"
|
||||
[node name="Spikeweed" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_kd62n")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_yfuxj")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_kd62n")
|
||||
texture = ExtResource("2_ffrjr")
|
||||
hframes = 10
|
||||
vframes = 2
|
||||
frame = 6
|
||||
frame = 1
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"spikeweed": ExtResource("3_nwshn")
|
||||
}
|
||||
|
||||
[node name="DPSStatistics" type="Node" parent="AnimationPlayer" index="0"]
|
||||
[node name="DPSStatistics" type="Node" parent="AnimationPlayer"]
|
||||
script = ExtResource("5_yfuxj")
|
||||
animationName = "spikeweed/attack"
|
||||
trackToFind = "Hitbox"
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_63okc")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/blend_position = 0
|
||||
script = ExtResource("6_sqcsr")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="3"]
|
||||
[node name="Behaviour" type="Node" parent="."]
|
||||
script = ExtResource("3_uhpn7")
|
||||
|
||||
[node name="Hitbox" parent="." index="4"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 8
|
||||
script = ExtResource("3_hqtbm")
|
||||
_damage = 6
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(0.5, 9)
|
||||
shape = SubResource("RectangleShape2D_1di76")
|
||||
|
||||
[node name="FlashController" parent="." index="5"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_yfuxj")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("9_lq7xg")
|
||||
shaderMaterial = ExtResource("2_kd62n")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="area_entered" from="Hitbox" to="Behaviour" method="OnHitboxEntered"]
|
||||
[connection signal="area_exited" from="Hitbox" to="Behaviour" method="OnHitboxExited"]
|
||||
|
|
|
|||
|
|
@ -1,21 +1,15 @@
|
|||
[gd_scene load_steps=21 format=3 uid="uid://bg7lomiorxo2c"]
|
||||
[gd_scene load_steps=22 format=3 uid="uid://bg7lomiorxo2c"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_bikjn"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_yyn2e"]
|
||||
[ext_resource type="Texture2D" uid="uid://b3tuidu8dag8u" path="res://assets/sprites/atlases/plants/sunflower.png" id="2_fwcda"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_qpvbo"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_yyn2e"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://yjytiuj4u7oh" path="res://assets/animations/plants/sunflower.res" id="3_btsik"]
|
||||
[ext_resource type="Script" uid="uid://b71gebny84s81" path="res://scripts/entities/plants/PlantSunSpawner.cs" id="3_te0pl"]
|
||||
[ext_resource type="PackedScene" uid="uid://bpekho7leatr5" path="res://scenes/sun.tscn" id="4_b8hls"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="5_7omaw"]
|
||||
[ext_resource type="Script" uid="uid://bth7gah4tn7uj" path="res://scripts/entities/plants/behaviours/SunflowerBehaviour.cs" id="5_26je0"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="7_rlkb7"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_mdjfv"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_qpvbo")
|
||||
shader_parameter/FLASH_COLOR = Color(0.78, 0.78, 0.78, 0.501961)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(0.69, 0, 0, 0.282353)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="10_w3e3c"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_bfx6v"]
|
||||
length = 0.001
|
||||
|
|
@ -73,56 +67,67 @@ node_connections = [&"TimeScale", 0, &"Tree", &"output", 0, &"TimeScale"]
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_4xs4g"]
|
||||
size = Vector2(26, 48)
|
||||
|
||||
[node name="Sunflower" instance=ExtResource("1_bikjn")]
|
||||
GetInternalID() = "sunflower"
|
||||
[node name="Sunflower" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_yyn2e")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_mdjfv")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_yyn2e")
|
||||
texture = ExtResource("2_fwcda")
|
||||
hframes = 9
|
||||
vframes = 2
|
||||
frame = 2
|
||||
frame = 4
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_ek2al"),
|
||||
&"sunflower": ExtResource("3_btsik")
|
||||
}
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_rlkb7")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/conditions/produce = false
|
||||
script = ExtResource("5_7omaw")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="PlantSunSpawner" type="Node2D" parent="." index="3"]
|
||||
[node name="PlantSunSpawner" type="Node2D" parent="."]
|
||||
position = Vector2(-2, 0)
|
||||
script = ExtResource("3_te0pl")
|
||||
_sunScene = ExtResource("4_b8hls")
|
||||
_amountPerSun = 25
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="4"]
|
||||
[node name="Behaviour" type="Node" parent="."]
|
||||
script = ExtResource("5_26je0")
|
||||
|
||||
[node name="Timer" type="Timer" parent="Behaviour" index="0" node_paths=PackedStringArray("entity")]
|
||||
[node name="Timer" type="Timer" parent="Behaviour" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 24.25
|
||||
script = ExtResource("7_rlkb7")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="StartTimer" type="Timer" parent="Behaviour" index="1" node_paths=PackedStringArray("entity")]
|
||||
[node name="StartTimer" type="Timer" parent="Behaviour" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 12.0
|
||||
one_shot = true
|
||||
autostart = true
|
||||
script = ExtResource("7_rlkb7")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(0, 4)
|
||||
shape = SubResource("RectangleShape2D_4xs4g")
|
||||
|
||||
[node name="FlashController" parent="." index="6"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_mdjfv")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("10_w3e3c")
|
||||
shaderMaterial = ExtResource("2_yyn2e")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="timeout" from="Behaviour/Timer" to="Behaviour" method="Timeout"]
|
||||
[connection signal="timeout" from="Behaviour/StartTimer" to="Behaviour" method="Timeout"]
|
||||
[connection signal="timeout" from="Behaviour/StartTimer" to="Behaviour/Timer" method="start"]
|
||||
|
|
|
|||
|
|
@ -1,9 +1,18 @@
|
|||
[gd_scene load_steps=20 format=3 uid="uid://eegv1qihfv2q"]
|
||||
[gd_scene load_steps=30 format=3 uid="uid://eegv1qihfv2q"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dy41q1kxray5t" path="res://scenes/entities/plants/peashooter.tscn" id="1_muntu"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_833fu"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_833fu"]
|
||||
[ext_resource type="Script" uid="uid://djpc0kvagpadv" path="res://scripts/entities/plants/ThreepeaterShooter.cs" id="2_ieami"]
|
||||
[ext_resource type="Texture2D" uid="uid://dyfa4462hu3w1" path="res://assets/sprites/atlases/plants/threepeater.png" id="2_j7h7q"]
|
||||
[ext_resource type="Script" uid="uid://hccb0aee0x0o" path="res://scripts/entities/plants/PlantEyesightLimiter.cs" id="3_dqn6w"]
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="4_ht2a0"]
|
||||
[ext_resource type="PackedScene" uid="uid://b2hrv0aqbui7u" path="res://scenes/projectiles/pea.tscn" id="6_kscbk"]
|
||||
[ext_resource type="Script" uid="uid://c4jy0cnbnx33h" path="res://scripts/TimeScalableTimer.cs" id="7_anbbx"]
|
||||
[ext_resource type="Script" uid="uid://bdk5iqtw4xbkl" path="res://scripts/entities/plants/behaviours/PeashooterBehaviour.cs" id="8_pp80j"]
|
||||
[ext_resource type="Script" uid="uid://dn53jvpjyg63l" path="res://scripts/entities/plants/Eyesight.cs" id="9_salpp"]
|
||||
[ext_resource type="Script" uid="uid://c36bj8u7jghc7" path="res://scripts/audio/ChannelPlayer.cs" id="11_13f0q"]
|
||||
[ext_resource type="AudioStream" uid="uid://dsv81mvrdg3w3" path="res://assets/audio/sfx/throw_generic.tres" id="12_4a4xw"]
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="13_otw6n"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_a2y0j"]
|
||||
length = 0.001
|
||||
|
|
@ -134,39 +143,89 @@ resource_local_to_scene = true
|
|||
[sub_resource type="SegmentShape2D" id="SegmentShape2D_yb26d"]
|
||||
resource_local_to_scene = true
|
||||
|
||||
[node name="Threepeater" instance=ExtResource("1_muntu")]
|
||||
GetInternalID() = "threepeater"
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_r7xnh"]
|
||||
size = Vector2(20, 44)
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
[node name="Threepeater" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_833fu")
|
||||
MaxHP = 30.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_833fu")
|
||||
position = Vector2(6, -13)
|
||||
texture = ExtResource("2_j7h7q")
|
||||
hframes = 13
|
||||
vframes = 2
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_ipp6b"),
|
||||
&"threepeater": SubResource("AnimationLibrary_o2obw")
|
||||
}
|
||||
autoplay = "peashooter/idle"
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_j7h7q")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/conditions/ready = false
|
||||
script = ExtResource("4_ht2a0")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="Shooter" parent="." index="3"]
|
||||
[node name="Shooter" type="Marker2D" parent="." node_paths=PackedStringArray("_timer")]
|
||||
position = Vector2(20, -9)
|
||||
script = ExtResource("2_ieami")
|
||||
_projectile = ExtResource("6_kscbk")
|
||||
_timer = NodePath("FireTimer")
|
||||
|
||||
[node name="Timer" parent="Shooter" index="0"]
|
||||
wait_time = 1.6
|
||||
[node name="FireTimer" type="Timer" parent="Shooter" node_paths=PackedStringArray("entity")]
|
||||
wait_time = 1.5
|
||||
one_shot = true
|
||||
script = ExtResource("7_anbbx")
|
||||
entity = NodePath("../..")
|
||||
|
||||
[node name="CollisionShape2D" parent="Eysight" index="0"]
|
||||
[node name="Behaviour" type="Node" parent="." node_paths=PackedStringArray("_shootTimer", "_sight")]
|
||||
script = ExtResource("8_pp80j")
|
||||
_shootTimer = NodePath("../Shooter/FireTimer")
|
||||
_sight = NodePath("../Eysight")
|
||||
|
||||
[node name="Eysight" type="Area2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 8
|
||||
script = ExtResource("9_salpp")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Eysight"]
|
||||
shape = SubResource("SegmentShape2D_j7h7q")
|
||||
script = ExtResource("3_dqn6w")
|
||||
|
||||
[node name="CollisionShape2D2" type="CollisionShape2D" parent="Eysight" index="1"]
|
||||
[node name="CollisionShape2D2" type="CollisionShape2D" parent="Eysight"]
|
||||
position = Vector2(0, 60)
|
||||
shape = SubResource("SegmentShape2D_yb26d")
|
||||
script = ExtResource("3_dqn6w")
|
||||
|
||||
[node name="CollisionShape2D3" type="CollisionShape2D" parent="Eysight" index="2"]
|
||||
[node name="CollisionShape2D3" type="CollisionShape2D" parent="Eysight"]
|
||||
position = Vector2(0, -60)
|
||||
shape = SubResource("SegmentShape2D_yb26d")
|
||||
script = ExtResource("3_dqn6w")
|
||||
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(0, 5)
|
||||
shape = SubResource("RectangleShape2D_r7xnh")
|
||||
|
||||
[node name="ChannelPlayer" type="Node" parent="."]
|
||||
script = ExtResource("11_13f0q")
|
||||
audioStream = ExtResource("12_4a4xw")
|
||||
channel = "pea_shoot"
|
||||
metadata/_custom_type_script = "uid://c36bj8u7jghc7"
|
||||
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("13_otw6n")
|
||||
shaderMaterial = ExtResource("2_833fu")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
|
|
|
|||
|
|
@ -1,18 +1,12 @@
|
|||
[gd_scene load_steps=14 format=3 uid="uid://bq7imkpr2yqyr"]
|
||||
[gd_scene load_steps=15 format=3 uid="uid://bq7imkpr2yqyr"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://b1hjjbdwf1rtc" path="res://scenes/templates/plant_template.tscn" id="1_fluxn"]
|
||||
[ext_resource type="Shader" uid="uid://cgc7spjkhsx7c" path="res://assets/shaders/generic_flash.gdshader" id="2_bi7an"]
|
||||
[ext_resource type="Script" uid="uid://dli2i6albvugt" path="res://scripts/entities/plants/RuntimePlantData.cs" id="1_mnh2m"]
|
||||
[ext_resource type="Material" uid="uid://cn7ac4meka1hc" path="res://assets/GenericFlashMaterial.tres" id="2_mnh2m"]
|
||||
[ext_resource type="Texture2D" uid="uid://dstqh1wc5dvmo" path="res://assets/sprites/atlases/plants/wallnut.png" id="2_o5tda"]
|
||||
[ext_resource type="AnimationLibrary" uid="uid://0bdesb8j2mbo" path="res://assets/animations/plants/wallnut.res" id="3_xl65q"]
|
||||
[ext_resource type="Script" uid="uid://btkmd86pn828y" path="res://scripts/entities/plants/behaviours/HpBasedBehaviour.cs" id="4_cjtyy"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_ladjs"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_bi7an")
|
||||
shader_parameter/FLASH_COLOR = Color(1, 0.709804, 0.439216, 0.5)
|
||||
shader_parameter/HIGHLIGHT_COLOR = Color(1, 0.709804, 0.439216, 0.5)
|
||||
shader_parameter/selected = false
|
||||
shader_parameter/blend = 0.0
|
||||
[ext_resource type="Script" uid="uid://dwlwi42smgxkb" path="res://scripts/TimeScalableAnimationTree.cs" id="5_2hmhw"]
|
||||
[ext_resource type="Script" uid="uid://30pbgasu64aw" path="res://scripts/entities/FlashShaderController.cs" id="7_frxj2"]
|
||||
|
||||
[sub_resource type="AnimationNodeTimeScale" id="AnimationNodeTimeScale_y3tlf"]
|
||||
|
||||
|
|
@ -46,35 +40,47 @@ node_connections = [&"TimeScale", 0, &"Tree", &"output", 0, &"TimeScale"]
|
|||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_khltr"]
|
||||
size = Vector2(33, 46)
|
||||
|
||||
[node name="Wallnut" instance=ExtResource("1_fluxn")]
|
||||
GetInternalID() = "wallnut"
|
||||
[node name="Wallnut" type="Node2D" node_paths=PackedStringArray("_player", "_tree")]
|
||||
script = ExtResource("1_mnh2m")
|
||||
MaxHP = 600.0
|
||||
_player = NodePath("AnimationPlayer")
|
||||
_tree = NodePath("AnimationTree")
|
||||
|
||||
[node name="Sprite2D" parent="." index="0"]
|
||||
material = SubResource("ShaderMaterial_ladjs")
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
material = ExtResource("2_mnh2m")
|
||||
texture = ExtResource("2_o5tda")
|
||||
hframes = 12
|
||||
vframes = 3
|
||||
frame = 10
|
||||
|
||||
[node name="AnimationPlayer" parent="." index="1"]
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"wallnut": ExtResource("3_xl65q")
|
||||
}
|
||||
|
||||
[node name="AnimationTree" parent="." index="2"]
|
||||
[node name="AnimationTree" type="AnimationTree" parent="." node_paths=PackedStringArray("entity")]
|
||||
tree_root = SubResource("AnimationNodeBlendTree_bi7an")
|
||||
anim_player = NodePath("../AnimationPlayer")
|
||||
parameters/TimeScale/scale = 1.0
|
||||
parameters/Tree/blend_position = 1.0
|
||||
script = ExtResource("5_2hmhw")
|
||||
entity = NodePath("..")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
[node name="Hitbox" type="Area2D" parent="."]
|
||||
collision_layer = 2
|
||||
collision_mask = 0
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Hitbox"]
|
||||
position = Vector2(3.5, 5)
|
||||
shape = SubResource("RectangleShape2D_khltr")
|
||||
|
||||
[node name="Behaviour" type="Node" parent="." index="4"]
|
||||
[node name="Behaviour" type="Node" parent="."]
|
||||
script = ExtResource("4_cjtyy")
|
||||
parameters = Array[String](["parameters/Tree/blend_position"])
|
||||
|
||||
[node name="FlashController" parent="." index="5"]
|
||||
shaderMaterial = SubResource("ShaderMaterial_ladjs")
|
||||
[node name="FlashController" type="Node" parent="."]
|
||||
script = ExtResource("7_frxj2")
|
||||
shaderMaterial = ExtResource("2_mnh2m")
|
||||
|
||||
[connection signal="OnDamaged" from="." to="FlashController" method="DamageFlash"]
|
||||
[connection signal="OnHPChanged" from="." to="Behaviour" method="OnHPChanged"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue