mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-07-04 10:51:17 +00:00
Moved weapons to their own scene
This commit is contained in:
parent
7ebbc207e6
commit
34e0603170
6 changed files with 159 additions and 62 deletions
|
|
@ -1,8 +1,9 @@
|
|||
[gd_scene load_steps=8 format=3 uid="uid://v8s3kubgb2qg"]
|
||||
[gd_scene load_steps=9 format=3 uid="uid://v8s3kubgb2qg"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://b4ynnb14mb4uq" path="res://Sprites/Reisen.png" id="1_4w8mj"]
|
||||
[ext_resource type="Script" path="res://Scripts/Enemy.cs" id="1_lpwdj"]
|
||||
[ext_resource type="PackedScene" uid="uid://cuixq5ex0j40h" path="res://Scenes/enemyBullet.tscn" id="2_ogldd"]
|
||||
[ext_resource type="PackedScene" uid="uid://crry0rgk7a8sm" path="res://Scenes/Weapons/BaseWeapon.tscn" id="4_2k1dv"]
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_2brqc"]
|
||||
atlas = ExtResource("1_4w8mj")
|
||||
|
|
@ -17,12 +18,11 @@ radius = 4.0
|
|||
[sub_resource type="CircleShape2D" id="CircleShape2D_v711r"]
|
||||
radius = 85.0529
|
||||
|
||||
[node name="Enemy" type="Area2D" groups=["Destroyable"]]
|
||||
[node name="Enemy" type="Area2D" node_paths=PackedStringArray("EquippedWeapon") groups=["Destroyable"]]
|
||||
collision_layer = 16
|
||||
collision_mask = 9
|
||||
script = ExtResource("1_lpwdj")
|
||||
BulletScene = ExtResource("2_ogldd")
|
||||
BulletSpeed = 50.0
|
||||
EquippedWeapon = NodePath("Weapon")
|
||||
metadata/_edit_group_ = true
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
|
|
@ -48,6 +48,11 @@ shape = SubResource("CircleShape2D_v711r")
|
|||
wait_time = 0.4
|
||||
one_shot = true
|
||||
|
||||
[node name="Weapon" parent="." instance=ExtResource("4_2k1dv")]
|
||||
BulletScene = ExtResource("2_ogldd")
|
||||
BulletCapacity = 4
|
||||
BulletSpeed = 50.0
|
||||
|
||||
[connection signal="area_entered" from="." to="." method="_on_area_entered"]
|
||||
[connection signal="area_entered" from="PlayerDetection" to="." method="_on_player_detection_area_entered"]
|
||||
[connection signal="area_exited" from="PlayerDetection" to="." method="_on_player_detection_area_exited"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue