the-crypt/magic/Projectiles/ExplosiveProjectile.tscn

64 lines
1.8 KiB
Plaintext
Raw Normal View History

2020-07-21 15:50:32 -05:00
[gd_scene load_steps=9 format=2]
2020-07-19 18:36:36 -05:00
[ext_resource path="res://art/MineProjectile.png" type="Texture" id=1]
2020-07-20 01:18:45 -05:00
[ext_resource path="res://magic/Projectiles/ExplosiveProjectile.gd" type="Script" id=2]
2020-07-21 15:50:32 -05:00
[ext_resource path="res://Sound Effects/Explosion.wav" type="AudioStream" id=3]
2020-07-19 18:36:36 -05:00
[sub_resource type="CircleShape2D" id=1]
2020-07-20 16:36:28 -05:00
radius = 6.0
2020-07-19 18:36:36 -05:00
2020-07-21 15:50:32 -05:00
[sub_resource type="Gradient" id=2]
2020-07-20 01:18:45 -05:00
offsets = PoolRealArray( 0.0120482, 0.192771, 0.534137, 1 )
colors = PoolColorArray( 1, 0.449219, 0.449219, 1, 1, 0, 0, 1, 1, 0.351563, 0, 1, 0.155762, 0.155762, 0.155762, 1 )
2020-07-21 15:50:32 -05:00
[sub_resource type="GradientTexture" id=3]
gradient = SubResource( 2 )
2020-07-20 01:18:45 -05:00
2020-07-21 15:50:32 -05:00
[sub_resource type="ParticlesMaterial" id=4]
2020-07-20 01:18:45 -05:00
emission_shape = 1
emission_sphere_radius = 1.0
flag_disable_z = true
spread = 180.0
gravity = Vector3( 0, 0, 0 )
initial_velocity = 50.0
orbit_velocity = 0.0
orbit_velocity_random = 0.0
2020-07-21 15:50:32 -05:00
color_ramp = SubResource( 3 )
2020-07-20 01:18:45 -05:00
2020-07-21 15:50:32 -05:00
[sub_resource type="CircleShape2D" id=5]
2020-07-20 01:18:45 -05:00
radius = 50.0
2020-07-19 18:36:36 -05:00
[node name="ExplosiveProjectile" type="KinematicBody2D"]
collision_layer = 8
collision_mask = 6
2020-07-19 18:36:36 -05:00
script = ExtResource( 2 )
[node name="Sprite" type="Sprite" parent="."]
2020-07-20 14:24:15 -05:00
rotation = 0.785398
2020-07-20 16:36:28 -05:00
scale = Vector2( 1.5, 1.5 )
2020-07-19 18:36:36 -05:00
texture = ExtResource( 1 )
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
shape = SubResource( 1 )
2020-07-20 01:18:45 -05:00
[node name="Particles2D" type="Particles2D" parent="."]
emitting = false
amount = 200
one_shot = true
speed_scale = 2.5
explosiveness = 0.8
2020-07-21 15:50:32 -05:00
process_material = SubResource( 4 )
2020-07-20 01:18:45 -05:00
[node name="Area2D" type="Area2D" parent="."]
2020-07-20 16:36:28 -05:00
visible = false
2020-07-20 01:18:45 -05:00
[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"]
2020-07-21 15:50:32 -05:00
shape = SubResource( 5 )
2020-07-20 01:18:45 -05:00
[node name="KillTimer" type="Timer" parent="."]
one_shot = true
2020-07-21 15:50:32 -05:00
[node name="Explosion" type="AudioStreamPlayer2D" parent="."]
stream = ExtResource( 3 )
2020-07-20 01:18:45 -05:00
[connection signal="timeout" from="KillTimer" to="." method="_on_KillTimer_timeout"]