Particles system
This commit is contained in:
parent
30266b36cf
commit
0e5dee50f7
46 changed files with 643 additions and 200 deletions
|
|
@ -1,7 +1,8 @@
|
|||
[gd_scene load_steps=4 format=3 uid="uid://b2hrv0aqbui7u"]
|
||||
[gd_scene load_steps=5 format=3 uid="uid://b2hrv0aqbui7u"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://dxlwvwy3hj56x" path="res://scripts/components/LinearProjectile.cs" id="1_3kc4s"]
|
||||
[ext_resource type="Texture2D" uid="uid://dq0mul65hevtt" path="res://assets/sprites/plants/pea.tres" id="2_26q5x"]
|
||||
[ext_resource type="PackedScene" uid="uid://1d33w4ubtury" path="res://scenes/particles/pea_particles.tscn" id="2_osqrk"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_ix1sk"]
|
||||
radius = 6.0
|
||||
|
|
@ -12,6 +13,7 @@ collision_mask = 8
|
|||
script = ExtResource("1_3kc4s")
|
||||
_speed = 3.0
|
||||
_damage = 10
|
||||
particles = ExtResource("2_osqrk")
|
||||
|
||||
[node name="Sprite" type="Sprite2D" parent="."]
|
||||
texture = ExtResource("2_26q5x")
|
||||
|
|
|
|||
|
|
@ -1,8 +1,12 @@
|
|||
[gd_scene load_steps=5 format=3 uid="uid://domeukw4ucmyr"]
|
||||
[gd_scene load_steps=9 format=3 uid="uid://domeukw4ucmyr"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://dxlwvwy3hj56x" path="res://scripts/components/LinearProjectile.cs" id="1_fkydi"]
|
||||
[ext_resource type="Resource" uid="uid://7uj0oe656jfx" path="res://resources/effects/SnowSlow.tres" id="2_fn62x"]
|
||||
[ext_resource type="Texture2D" uid="uid://dn4l67snkx5mr" path="res://assets/sprites/plants/snowpea_projectile.tres" id="2_xt8td"]
|
||||
[ext_resource type="PackedScene" uid="uid://cijchi3f01q2t" path="res://scenes/particles/snow_pea_particles.tscn" id="3_t6hp0"]
|
||||
[ext_resource type="Texture2D" uid="uid://dejgsyw4f2crg" path="res://assets/sprites/particles/snowpea_flake1.tres" id="5_1u1j3"]
|
||||
[ext_resource type="Material" uid="uid://bflocbxbpv73j" path="res://assets/sprites/particles/snowflake.tres" id="6_pcdfd"]
|
||||
[ext_resource type="Texture2D" uid="uid://deiu2jr26meq" path="res://assets/sprites/particles/snowpea_flake2.tres" id="7_xke8y"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_ix1sk"]
|
||||
radius = 6.0
|
||||
|
|
@ -15,6 +19,7 @@ _speed = 3.0
|
|||
_damage = 10
|
||||
_impactEffect = ExtResource("2_fn62x")
|
||||
_damageType = 1
|
||||
particles = ExtResource("3_t6hp0")
|
||||
|
||||
[node name="Sprite" type="Sprite2D" parent="."]
|
||||
texture = ExtResource("2_xt8td")
|
||||
|
|
@ -27,5 +32,24 @@ wait_time = 15.0
|
|||
one_shot = true
|
||||
autostart = true
|
||||
|
||||
[node name="Particles1" type="GPUParticles2D" parent="."]
|
||||
position = Vector2(-5, 0)
|
||||
amount = 1
|
||||
texture = ExtResource("5_1u1j3")
|
||||
process_material = ExtResource("6_pcdfd")
|
||||
|
||||
[node name="Particles2" type="GPUParticles2D" parent="."]
|
||||
position = Vector2(5, 0)
|
||||
emitting = false
|
||||
amount = 1
|
||||
texture = ExtResource("7_xke8y")
|
||||
process_material = ExtResource("6_pcdfd")
|
||||
|
||||
[node name="Timer" type="Timer" parent="Particles2"]
|
||||
wait_time = 0.2
|
||||
one_shot = true
|
||||
autostart = true
|
||||
|
||||
[connection signal="area_entered" from="." to="." method="OnAreaEntered"]
|
||||
[connection signal="timeout" from="Timer" to="." method="queue_free"]
|
||||
[connection signal="timeout" from="Particles2/Timer" to="Particles2" method="set_emitting" binds= [true]]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue