mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-07-03 03:31:16 +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,4 +1,4 @@
|
|||
[gd_scene load_steps=27 format=3 uid="uid://bghghp5ep4w2j"]
|
||||
[gd_scene load_steps=28 format=3 uid="uid://bghghp5ep4w2j"]
|
||||
|
||||
[ext_resource type="Script" path="res://Scripts/PlayerMovement.cs" id="1_m27vu"]
|
||||
[ext_resource type="Texture2D" uid="uid://la06powu57hu" path="res://Sprites/Cirno_Big.png" id="2_bwf6x"]
|
||||
|
|
@ -8,6 +8,7 @@
|
|||
[ext_resource type="Script" path="res://Scenes/CameraTarget.gd" id="5_cxvyt"]
|
||||
[ext_resource type="PackedScene" uid="uid://cfb3nsay84xdb" path="res://Scenes/crosshair.tscn" id="6_l43rf"]
|
||||
[ext_resource type="Script" path="res://Scenes/InteractionController.cs" id="7_uvgjg"]
|
||||
[ext_resource type="PackedScene" uid="uid://crry0rgk7a8sm" path="res://Scenes/Weapons/BaseWeapon.tscn" id="9_wblq0"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_ai4rh"]
|
||||
size = Vector2(6, 6)
|
||||
|
|
@ -141,7 +142,7 @@ radius = 17.2627
|
|||
[sub_resource type="CircleShape2D" id="CircleShape2D_e6woi"]
|
||||
radius = 1.41421
|
||||
|
||||
[node name="Player" type="CharacterBody2D" node_paths=PackedStringArray("Muzzle") groups=["Destroyable", "player"]]
|
||||
[node name="Player" type="CharacterBody2D" node_paths=PackedStringArray("Muzzle", "EquippedWeapon") groups=["Destroyable", "player"]]
|
||||
collision_layer = 2
|
||||
collision_mask = 99
|
||||
script = ExtResource("1_m27vu")
|
||||
|
|
@ -152,7 +153,7 @@ SelectorScene = ExtResource("3_8wt6s")
|
|||
GameOverScene = "res://Scenes/GameOver.tscn"
|
||||
Muzzle = NodePath("Muzzle")
|
||||
Health = 32.0
|
||||
RateOfFire = 0.1
|
||||
EquippedWeapon = NodePath("Weapon")
|
||||
metadata/_edit_group_ = true
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
|
|
@ -205,5 +206,12 @@ collision_mask = 128
|
|||
shape = SubResource("CircleShape2D_e6woi")
|
||||
debug_color = Color(1, 0.00817797, 0.0443347, 0.42)
|
||||
|
||||
[node name="Weapon" parent="." instance=ExtResource("9_wblq0")]
|
||||
BulletScene = ExtResource("2_ov36d")
|
||||
RateOfFire = 0.1
|
||||
BulletCapacity = 100
|
||||
ReloadTime = 0.4
|
||||
BulletSpeed = 300.0
|
||||
|
||||
[connection signal="area_entered" from="InteractionController" to="." method="_on_interaction_controller_area_entered"]
|
||||
[connection signal="area_entered" from="DamageHitBox" to="." method="_on_damage_hit_box_area_entered"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue