diff --git a/DungeonShooting_Godot/DungeonShooting.csproj b/DungeonShooting_Godot/DungeonShooting.csproj index 65ee589..36c02a1 100644 --- a/DungeonShooting_Godot/DungeonShooting.csproj +++ b/DungeonShooting_Godot/DungeonShooting.csproj @@ -1,4 +1,4 @@ - + net7.0 true diff --git a/DungeonShooting_Godot/DungeonShooting.csproj.old.1 b/DungeonShooting_Godot/DungeonShooting.csproj.old.1 new file mode 100644 index 0000000..65ee589 --- /dev/null +++ b/DungeonShooting_Godot/DungeonShooting.csproj.old.1 @@ -0,0 +1,11 @@ + + + net7.0 + true + + + + + + + \ No newline at end of file diff --git a/DungeonShooting_Godot/DungeonShooting.csproj.old.2 b/DungeonShooting_Godot/DungeonShooting.csproj.old.2 new file mode 100644 index 0000000..543224c --- /dev/null +++ b/DungeonShooting_Godot/DungeonShooting.csproj.old.2 @@ -0,0 +1,11 @@ + + + net7.0 + true + + + + + + + \ No newline at end of file diff --git a/DungeonShooting_Godot/excel/excelFile/ActivityBase.xlsx b/DungeonShooting_Godot/excel/excelFile/ActivityBase.xlsx new file mode 100644 index 0000000..62c2d8a --- /dev/null +++ b/DungeonShooting_Godot/excel/excelFile/ActivityBase.xlsx Binary files differ diff --git a/DungeonShooting_Godot/excel/excelFile/ActivityMaterial.xlsx b/DungeonShooting_Godot/excel/excelFile/ActivityMaterial.xlsx new file mode 100644 index 0000000..ad56ce8 --- /dev/null +++ b/DungeonShooting_Godot/excel/excelFile/ActivityMaterial.xlsx Binary files differ diff --git a/DungeonShooting_Godot/excel/excelFile/ActivityObject.xlsx b/DungeonShooting_Godot/excel/excelFile/ActivityObject.xlsx deleted file mode 100644 index 508bcd9..0000000 --- a/DungeonShooting_Godot/excel/excelFile/ActivityObject.xlsx +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/excel/excelFile/AiAttackAttr.xlsx b/DungeonShooting_Godot/excel/excelFile/AiAttackAttr.xlsx index 152aabd..4531299 100644 --- a/DungeonShooting_Godot/excel/excelFile/AiAttackAttr.xlsx +++ b/DungeonShooting_Godot/excel/excelFile/AiAttackAttr.xlsx Binary files differ diff --git a/DungeonShooting_Godot/excel/excelFile/BulletBase.xlsx b/DungeonShooting_Godot/excel/excelFile/BulletBase.xlsx new file mode 100644 index 0000000..8e3e0b4 --- /dev/null +++ b/DungeonShooting_Godot/excel/excelFile/BulletBase.xlsx Binary files differ diff --git a/DungeonShooting_Godot/excel/excelFile/Sound.xlsx b/DungeonShooting_Godot/excel/excelFile/Sound.xlsx index a17d8a7..5a36ef9 100644 --- a/DungeonShooting_Godot/excel/excelFile/Sound.xlsx +++ b/DungeonShooting_Godot/excel/excelFile/Sound.xlsx Binary files differ diff --git a/DungeonShooting_Godot/excel/excelFile/Weapon.xlsx b/DungeonShooting_Godot/excel/excelFile/Weapon.xlsx deleted file mode 100644 index 7602be4..0000000 --- a/DungeonShooting_Godot/excel/excelFile/Weapon.xlsx +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/excel/excelFile/WeaponBase.xlsx b/DungeonShooting_Godot/excel/excelFile/WeaponBase.xlsx new file mode 100644 index 0000000..c5a29ed --- /dev/null +++ b/DungeonShooting_Godot/excel/excelFile/WeaponBase.xlsx Binary files differ diff --git a/DungeonShooting_Godot/prefab/bullet/Bullet0001.tscn b/DungeonShooting_Godot/prefab/bullet/Bullet0001.tscn deleted file mode 100644 index 858cd81..0000000 --- a/DungeonShooting_Godot/prefab/bullet/Bullet0001.tscn +++ /dev/null @@ -1,71 +0,0 @@ -[gd_scene load_steps=8 format=3 uid="uid://bj4kmvt8jg1cf"] - -[ext_resource type="Script" path="res://src/game/activity/bullet/Bullet.cs" id="1_82ma0"] -[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_6wvtu"] -[ext_resource type="Texture2D" uid="uid://bu0b11hiuecxy" path="res://resource/sprite/bullet/bullet0001.png" id="3_hjgpe"] - -[sub_resource type="ShaderMaterial" id="ShaderMaterial_w5w0i"] -resource_local_to_scene = true -shader = ExtResource("2_6wvtu") -shader_parameter/blend = Color(0, 0, 0, 0.470588) -shader_parameter/schedule = 1.0 -shader_parameter/modulate = Color(1, 1, 1, 1) -shader_parameter/show_outline = false -shader_parameter/outline_color = Color(0, 0, 0, 1) -shader_parameter/outline_rainbow = false -shader_parameter/outline_use_blend = true - -[sub_resource type="ShaderMaterial" id="ShaderMaterial_qhkgc"] -resource_local_to_scene = true -shader = ExtResource("2_6wvtu") -shader_parameter/blend = Color(1, 1, 1, 1) -shader_parameter/schedule = 0.0 -shader_parameter/modulate = Color(1, 1, 1, 1) -shader_parameter/show_outline = false -shader_parameter/outline_color = Color(0, 0, 0, 1) -shader_parameter/outline_rainbow = false -shader_parameter/outline_use_blend = true - -[sub_resource type="SpriteFrames" id="SpriteFrames_5wvmf"] -animations = [{ -"frames": [{ -"duration": 1.0, -"texture": ExtResource("3_hjgpe") -}], -"loop": true, -"name": &"default", -"speed": 5.0 -}] - -[sub_resource type="RectangleShape2D" id="RectangleShape2D_lcqb8"] -size = Vector2(9, 4) - -[node name="Bullet0001" type="CharacterBody2D" node_paths=PackedStringArray("CollisionArea", "ShadowSprite", "AnimatedSprite", "Collision")] -collision_layer = 2 -script = ExtResource("1_82ma0") -CollisionArea = NodePath("CollisionArea") -ShadowSprite = NodePath("ShadowSprite") -AnimatedSprite = NodePath("AnimatedSprite") -Collision = NodePath("Collision") - -[node name="ShadowSprite" type="Sprite2D" parent="."] -z_index = -1 -material = SubResource("ShaderMaterial_w5w0i") - -[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] -material = SubResource("ShaderMaterial_qhkgc") -sprite_frames = SubResource("SpriteFrames_5wvmf") - -[node name="CollisionArea" type="Area2D" parent="."] -visible = false -collision_layer = 0 -collision_mask = 0 -monitorable = false - -[node name="CollisionShape2D" type="CollisionShape2D" parent="CollisionArea"] -position = Vector2(2.93353, 0) -shape = SubResource("RectangleShape2D_lcqb8") - -[node name="Collision" type="CollisionShape2D" parent="."] -position = Vector2(1.5, 0) -shape = SubResource("RectangleShape2D_lcqb8") diff --git a/DungeonShooting_Godot/prefab/bullet/Bullet0002.tscn b/DungeonShooting_Godot/prefab/bullet/Bullet0002.tscn deleted file mode 100644 index 7ff1c64..0000000 --- a/DungeonShooting_Godot/prefab/bullet/Bullet0002.tscn +++ /dev/null @@ -1,63 +0,0 @@ -[gd_scene load_steps=8 format=3 uid="uid://bqkj0rn72ppge"] - -[ext_resource type="Script" path="res://src/game/activity/bullet/Bullet.cs" id="1_hga3h"] -[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_n44pd"] -[ext_resource type="SpriteFrames" uid="uid://bpeodjqiy3mil" path="res://resource/spriteFrames/bullet/Bullet0002.tres" id="3_uvuj8"] - -[sub_resource type="ShaderMaterial" id="ShaderMaterial_v77gw"] -resource_local_to_scene = true -shader = ExtResource("2_n44pd") -shader_parameter/blend = Color(0, 0, 0, 0.470588) -shader_parameter/schedule = 1.0 -shader_parameter/modulate = Color(1, 1, 1, 1) -shader_parameter/show_outline = false -shader_parameter/outline_color = Color(0, 0, 0, 1) -shader_parameter/outline_rainbow = false -shader_parameter/outline_use_blend = true - -[sub_resource type="ShaderMaterial" id="ShaderMaterial_p0wfd"] -resource_local_to_scene = true -shader = ExtResource("2_n44pd") -shader_parameter/blend = Color(1, 1, 1, 1) -shader_parameter/schedule = 0.0 -shader_parameter/modulate = Color(1, 1, 1, 1) -shader_parameter/show_outline = false -shader_parameter/outline_color = Color(0, 0, 0, 1) -shader_parameter/outline_rainbow = false -shader_parameter/outline_use_blend = true - -[sub_resource type="CircleShape2D" id="CircleShape2D_0vxfv"] -radius = 3.0 - -[sub_resource type="CircleShape2D" id="CircleShape2D_e2yn3"] -radius = 3.0 - -[node name="Bullet0002" type="CharacterBody2D" node_paths=PackedStringArray("CollisionArea", "ShadowSprite", "AnimatedSprite", "Collision")] -collision_layer = 2 -script = ExtResource("1_hga3h") -CollisionArea = NodePath("CollisionArea") -ShadowSprite = NodePath("ShadowSprite") -AnimatedSprite = NodePath("AnimatedSprite") -Collision = NodePath("Collision") - -[node name="ShadowSprite" type="Sprite2D" parent="."] -z_index = -1 -material = SubResource("ShaderMaterial_v77gw") - -[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] -modulate = Color(1.6, 1.6, 1.6, 1) -material = SubResource("ShaderMaterial_p0wfd") -sprite_frames = ExtResource("3_uvuj8") - -[node name="CollisionArea" type="Area2D" parent="."] -visible = false -collision_layer = 0 -collision_mask = 0 -monitorable = false - -[node name="CollisionShape2D" type="CollisionShape2D" parent="CollisionArea"] -position = Vector2(-2.38419e-07, 0) -shape = SubResource("CircleShape2D_0vxfv") - -[node name="Collision" type="CollisionShape2D" parent="."] -shape = SubResource("CircleShape2D_e2yn3") diff --git a/DungeonShooting_Godot/prefab/bullet/Bullet0003.tscn b/DungeonShooting_Godot/prefab/bullet/Bullet0003.tscn deleted file mode 100644 index 605759f..0000000 --- a/DungeonShooting_Godot/prefab/bullet/Bullet0003.tscn +++ /dev/null @@ -1,58 +0,0 @@ -[gd_scene load_steps=7 format=3 uid="uid://ee24ocwk8snj"] - -[ext_resource type="Script" path="res://src/game/activity/bullet/Bullet.cs" id="1_h6lfm"] -[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_bteri"] -[ext_resource type="SpriteFrames" uid="uid://bcnhyin0aufl1" path="res://resource/spriteFrames/bullet/Bullet0003.tres" id="3_qvo0u"] - -[sub_resource type="ShaderMaterial" id="ShaderMaterial_v77gw"] -resource_local_to_scene = true -shader = ExtResource("2_bteri") -shader_parameter/blend = Color(0, 0, 0, 0.470588) -shader_parameter/schedule = 1.0 -shader_parameter/modulate = Color(1, 1, 1, 1) -shader_parameter/show_outline = false -shader_parameter/outline_color = Color(0, 0, 0, 1) -shader_parameter/outline_rainbow = false - -[sub_resource type="ShaderMaterial" id="ShaderMaterial_p0wfd"] -resource_local_to_scene = true -shader = ExtResource("2_bteri") -shader_parameter/blend = Color(1, 1, 1, 1) -shader_parameter/schedule = 0.0 -shader_parameter/modulate = Color(1, 1, 1, 1) -shader_parameter/show_outline = false -shader_parameter/outline_color = Color(0, 0, 0, 1) -shader_parameter/outline_rainbow = false - -[sub_resource type="RectangleShape2D" id="RectangleShape2D_c0onq"] -size = Vector2(6, 3.125) - -[node name="Bullet0003" type="CharacterBody2D" node_paths=PackedStringArray("CollisionArea", "ShadowSprite", "AnimatedSprite", "Collision")] -collision_layer = 2 -script = ExtResource("1_h6lfm") -CollisionArea = NodePath("CollisionArea") -ShadowSprite = NodePath("ShadowSprite") -AnimatedSprite = NodePath("AnimatedSprite") -Collision = NodePath("Collision") - -[node name="ShadowSprite" type="Sprite2D" parent="."] -z_index = -1 -material = SubResource("ShaderMaterial_v77gw") - -[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] -modulate = Color(1.6, 1.6, 1.6, 1) -material = SubResource("ShaderMaterial_p0wfd") -sprite_frames = ExtResource("3_qvo0u") - -[node name="CollisionArea" type="Area2D" parent="."] -visible = false -collision_layer = 0 -collision_mask = 0 -monitorable = false - -[node name="CollisionShape2D" type="CollisionShape2D" parent="CollisionArea"] -position = Vector2(1, 0) -shape = SubResource("RectangleShape2D_c0onq") - -[node name="Collision" type="CollisionShape2D" parent="."] -shape = SubResource("RectangleShape2D_c0onq") diff --git a/DungeonShooting_Godot/prefab/bullet/explode/Explode0001.tscn b/DungeonShooting_Godot/prefab/bullet/explode/Explode0001.tscn new file mode 100644 index 0000000..31cb46f --- /dev/null +++ b/DungeonShooting_Godot/prefab/bullet/explode/Explode0001.tscn @@ -0,0 +1,356 @@ +[gd_scene load_steps=26 format=3 uid="uid://cw3c600m8rv6t"] + +[ext_resource type="Texture2D" uid="uid://h7hkgbwj1li" path="res://resource/sprite/effects/common/Smoke.png" id="1_ctx3v"] +[ext_resource type="Script" path="res://src/game/activity/bullet/explode/Explode.cs" id="1_qn5pu"] +[ext_resource type="Texture2D" uid="uid://ccdflg560oub6" path="res://resource/sprite/effects/explode/Explode_circle0001.png" id="2_bpdnr"] +[ext_resource type="Texture2D" uid="uid://rk73piti0qot" path="res://resource/sprite/effects/common/Smoke2.png" id="3_xt36q"] +[ext_resource type="Texture2D" uid="uid://cquv6nomd3tpf" path="res://resource/sprite/effects/explode/Explode_line0001.png" id="4_i3ry2"] + +[sub_resource type="CanvasItemMaterial" id="CanvasItemMaterial_sk5lv"] +particles_animation = true +particles_anim_h_frames = 3 +particles_anim_v_frames = 1 +particles_anim_loop = false + +[sub_resource type="Gradient" id="Gradient_r2jo0"] +offsets = PackedFloat32Array(0.196911, 0.787645) +colors = PackedColorArray(0.862745, 0.862745, 0.862745, 0.741176, 0.34902, 0.34902, 0.34902, 0.933333) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_1neuh"] +gradient = SubResource("Gradient_r2jo0") + +[sub_resource type="Curve" id="Curve_2xqp4"] +_data = [Vector2(0, 0.516483), 0.0, 2.31551, 0, 0, Vector2(0.602787, 1), 0.0, 0.0, 0, 0, Vector2(1, 0.274725), 0.0, 0.0, 0, 0] +point_count = 3 + +[sub_resource type="CurveTexture" id="CurveTexture_lbho4"] +curve = SubResource("Curve_2xqp4") + +[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_8sxfm"] +particle_flag_disable_z = true +emission_shape = 3 +emission_box_extents = Vector3(5, 5, 5) +spread = 180.0 +initial_velocity_max = 30.0 +gravity = Vector3(0, 0, 0) +damping_max = 3.0 +scale_min = 0.5 +scale_curve = SubResource("CurveTexture_lbho4") +color_ramp = SubResource("GradientTexture1D_1neuh") +anim_offset_max = 1.0 + +[sub_resource type="Gradient" id="Gradient_36yod"] +offsets = PackedFloat32Array(0.196911, 0.791506) +colors = PackedColorArray(0.215686, 0.215686, 0.215686, 0.709804, 0.0196078, 0.0196078, 0.0196078, 0.537255) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_d3vr4"] +gradient = SubResource("Gradient_36yod") + +[sub_resource type="Curve" id="Curve_dvd5q"] +_data = [Vector2(0, 0.516483), 0.0, 2.31551, 0, 0, Vector2(0.602787, 1), 0.0, 0.0, 0, 0, Vector2(1, 0.274725), 0.0, 0.0, 0, 0] +point_count = 3 + +[sub_resource type="CurveTexture" id="CurveTexture_anl6y"] +curve = SubResource("Curve_dvd5q") + +[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_h3c43"] +particle_flag_disable_z = true +emission_shape = 3 +emission_box_extents = Vector3(4, 4, 4) +spread = 180.0 +initial_velocity_max = 25.0 +gravity = Vector3(0, 0, 0) +damping_max = 3.0 +scale_min = 1.3 +scale_max = 2.5 +scale_curve = SubResource("CurveTexture_anl6y") +color_ramp = SubResource("GradientTexture1D_d3vr4") +anim_offset_max = 1.0 + +[sub_resource type="Gradient" id="Gradient_wcvi2"] +offsets = PackedFloat32Array(0, 0.135135, 0.498069, 0.72973, 0.888031) +colors = PackedColorArray(1, 1, 1, 1, 0.976471, 0.862745, 0.34902, 0.843137, 1, 0.501961, 0.101961, 0.839216, 1, 0, 0, 0.690196, 0, 0, 0, 0.490196) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_ftewy"] +gradient = SubResource("Gradient_wcvi2") + +[sub_resource type="Curve" id="Curve_d4xab"] +_data = [Vector2(0, 0.318681), 0.0, 0.0, 0, 0, Vector2(0.146341, 1), 0.0, 0.0, 0, 0, Vector2(1, 0.120879), 0.0, 0.0, 0, 0] +point_count = 3 + +[sub_resource type="CurveTexture" id="CurveTexture_pdvs3"] +curve = SubResource("Curve_d4xab") + +[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_j41d3"] +lifetime_randomness = 0.5 +particle_flag_disable_z = true +spread = 180.0 +initial_velocity_max = 30.0 +gravity = Vector3(0, 0, 0) +damping_min = 0.5 +damping_max = 3.0 +scale_max = 2.0 +scale_curve = SubResource("CurveTexture_pdvs3") +color_ramp = SubResource("GradientTexture1D_ftewy") +anim_offset_max = 1.0 + +[sub_resource type="CircleShape2D" id="CircleShape2D_isein"] +resource_local_to_scene = true + +[sub_resource type="Animation" id="Animation_20asn"] +length = 0.001 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("Circle:visible") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [true] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath("Circle:frame") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [0] +} +tracks/2/type = "value" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("Line:visible") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [true] +} +tracks/3/type = "value" +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/path = NodePath("Line:frame") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [0] +} +tracks/4/type = "value" +tracks/4/imported = false +tracks/4/enabled = true +tracks/4/path = NodePath("ParticlesSmoke2:emitting") +tracks/4/interp = 1 +tracks/4/loop_wrap = true +tracks/4/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [false] +} +tracks/5/type = "value" +tracks/5/imported = false +tracks/5/enabled = true +tracks/5/path = NodePath("ParticlesFire:emitting") +tracks/5/interp = 1 +tracks/5/loop_wrap = true +tracks/5/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [false] +} +tracks/6/type = "value" +tracks/6/imported = false +tracks/6/enabled = true +tracks/6/path = NodePath("ParticlesSmoke:emitting") +tracks/6/interp = 1 +tracks/6/loop_wrap = true +tracks/6/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [false] +} +tracks/7/type = "value" +tracks/7/imported = false +tracks/7/enabled = true +tracks/7/path = NodePath("CollisionShape2D:disabled") +tracks/7/interp = 1 +tracks/7/loop_wrap = true +tracks/7/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [false] +} + +[sub_resource type="Animation" id="Animation_j6a2s"] +resource_name = "play" +length = 4.0 +step = 0.05 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("Circle:visible") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0, 0.55), +"transitions": PackedFloat32Array(1, 1), +"update": 1, +"values": [true, false] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath("Circle:frame") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0, 0.5), +"transitions": PackedFloat32Array(1, 1), +"update": 0, +"values": [0, 6] +} +tracks/2/type = "value" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("Line:visible") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"times": PackedFloat32Array(0.15, 0.45), +"transitions": PackedFloat32Array(1, 1), +"update": 1, +"values": [true, false] +} +tracks/3/type = "value" +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/path = NodePath("Line:frame") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/keys = { +"times": PackedFloat32Array(0.15, 0.4), +"transitions": PackedFloat32Array(1, 1), +"update": 0, +"values": [0, 5] +} +tracks/4/type = "value" +tracks/4/imported = false +tracks/4/enabled = true +tracks/4/path = NodePath("ParticlesSmoke2:emitting") +tracks/4/interp = 1 +tracks/4/loop_wrap = true +tracks/4/keys = { +"times": PackedFloat32Array(0.15), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [true] +} +tracks/5/type = "value" +tracks/5/imported = false +tracks/5/enabled = true +tracks/5/path = NodePath("ParticlesFire:emitting") +tracks/5/interp = 1 +tracks/5/loop_wrap = true +tracks/5/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [true] +} +tracks/6/type = "value" +tracks/6/imported = false +tracks/6/enabled = true +tracks/6/path = NodePath("ParticlesSmoke:emitting") +tracks/6/interp = 1 +tracks/6/loop_wrap = true +tracks/6/keys = { +"times": PackedFloat32Array(0.15), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [true] +} +tracks/7/type = "value" +tracks/7/imported = false +tracks/7/enabled = true +tracks/7/path = NodePath("CollisionShape2D:disabled") +tracks/7/interp = 1 +tracks/7/loop_wrap = true +tracks/7/keys = { +"times": PackedFloat32Array(0, 0.2), +"transitions": PackedFloat32Array(1, 1), +"update": 1, +"values": [false, true] +} + +[sub_resource type="AnimationLibrary" id="AnimationLibrary_p6l6x"] +_data = { +"RESET": SubResource("Animation_20asn"), +"play": SubResource("Animation_j6a2s") +} + +[node name="Explode0001" type="Area2D"] +modulate = Color(1.3, 1.3, 1.3, 1) +z_index = 1 +collision_layer = 0 +monitorable = false +script = ExtResource("1_qn5pu") + +[node name="ParticlesSmoke" type="GPUParticles2D" parent="."] +material = SubResource("CanvasItemMaterial_sk5lv") +emitting = false +process_material = SubResource("ParticleProcessMaterial_8sxfm") +texture = ExtResource("3_xt36q") +one_shot = true +explosiveness = 0.6 +randomness = 1.0 + +[node name="ParticlesSmoke2" type="GPUParticles2D" parent="."] +material = SubResource("CanvasItemMaterial_sk5lv") +emitting = false +amount = 10 +process_material = SubResource("ParticleProcessMaterial_h3c43") +texture = ExtResource("1_ctx3v") +one_shot = true +explosiveness = 0.6 +randomness = 1.0 + +[node name="ParticlesFire" type="GPUParticles2D" parent="."] +material = SubResource("CanvasItemMaterial_sk5lv") +emitting = false +amount = 25 +process_material = SubResource("ParticleProcessMaterial_j41d3") +texture = ExtResource("1_ctx3v") +one_shot = true +explosiveness = 0.7 +randomness = 1.0 + +[node name="Circle" type="Sprite2D" parent="."] +texture = ExtResource("2_bpdnr") +hframes = 7 + +[node name="Line" type="Sprite2D" parent="."] +texture = ExtResource("4_i3ry2") +hframes = 6 + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +shape = SubResource("CircleShape2D_isein") + +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +libraries = { +"": SubResource("AnimationLibrary_p6l6x") +} diff --git a/DungeonShooting_Godot/prefab/bullet/laser/Laser0001.tscn b/DungeonShooting_Godot/prefab/bullet/laser/Laser0001.tscn new file mode 100644 index 0000000..5117e12 --- /dev/null +++ b/DungeonShooting_Godot/prefab/bullet/laser/Laser0001.tscn @@ -0,0 +1,22 @@ +[gd_scene load_steps=4 format=3 uid="uid://d1q8jjtgi2wpu"] + +[ext_resource type="Script" path="res://src/game/activity/bullet/laser/Laser.cs" id="1_3w0rp"] +[ext_resource type="Texture2D" uid="uid://clfpbq1c1ilp1" path="res://resource/sprite/bullet/laser/Laser0001.png" id="2_uqalj"] + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_l4vuk"] +resource_local_to_scene = true + +[node name="Laser0001" type="Area2D"] +collision_layer = 2 +monitorable = false +script = ExtResource("1_3w0rp") + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_l4vuk") + +[node name="LineSprite" type="Sprite2D" parent="."] +modulate = Color(1.5, 1.5, 1.5, 1) +position = Vector2(0, 1.19209e-07) +texture = ExtResource("2_uqalj") +centered = false +offset = Vector2(0, -8) diff --git a/DungeonShooting_Godot/prefab/bullet/normal/Bullet0001.tscn b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0001.tscn new file mode 100644 index 0000000..740c1cd --- /dev/null +++ b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0001.tscn @@ -0,0 +1,71 @@ +[gd_scene load_steps=8 format=3 uid="uid://bj4kmvt8jg1cf"] + +[ext_resource type="Script" path="res://src/game/activity/bullet/normal/Bullet.cs" id="1_3d3df"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_mxa72"] +[ext_resource type="Texture2D" uid="uid://bu0b11hiuecxy" path="res://resource/sprite/bullet/normal/bullet0001.png" id="3_pm4pr"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_w5w0i"] +resource_local_to_scene = true +shader = ExtResource("2_mxa72") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_qhkgc"] +resource_local_to_scene = true +shader = ExtResource("2_mxa72") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="SpriteFrames" id="SpriteFrames_5wvmf"] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": ExtResource("3_pm4pr") +}], +"loop": true, +"name": &"default", +"speed": 5.0 +}] + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_lcqb8"] +size = Vector2(9, 4) + +[node name="Bullet0001" type="CharacterBody2D" node_paths=PackedStringArray("CollisionArea", "ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 2 +script = ExtResource("1_3d3df") +CollisionArea = NodePath("AnimatedSprite/CollisionArea") +ShadowSprite = NodePath("ShadowSprite") +AnimatedSprite = NodePath("AnimatedSprite") +Collision = NodePath("Collision") + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_w5w0i") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +modulate = Color(1.6, 1.6, 1.6, 1) +material = SubResource("ShaderMaterial_qhkgc") +sprite_frames = SubResource("SpriteFrames_5wvmf") + +[node name="CollisionArea" type="Area2D" parent="AnimatedSprite"] +collision_layer = 0 +collision_mask = 0 +monitorable = false + +[node name="CollisionShape2D" type="CollisionShape2D" parent="AnimatedSprite/CollisionArea"] +position = Vector2(2.93353, 0) +shape = SubResource("RectangleShape2D_lcqb8") + +[node name="Collision" type="CollisionShape2D" parent="."] +position = Vector2(1.5, 0) +shape = SubResource("RectangleShape2D_lcqb8") diff --git a/DungeonShooting_Godot/prefab/bullet/normal/Bullet0002.tscn b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0002.tscn new file mode 100644 index 0000000..b1a1813 --- /dev/null +++ b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0002.tscn @@ -0,0 +1,63 @@ +[gd_scene load_steps=8 format=3 uid="uid://bqkj0rn72ppge"] + +[ext_resource type="Script" path="res://src/game/activity/bullet/normal/Bullet.cs" id="1_hepay"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_0n2yg"] +[ext_resource type="SpriteFrames" uid="uid://bpeodjqiy3mil" path="res://resource/spriteFrames/bullet/Bullet0002.tres" id="3_ldd0h"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_v77gw"] +resource_local_to_scene = true +shader = ExtResource("2_0n2yg") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_p0wfd"] +resource_local_to_scene = true +shader = ExtResource("2_0n2yg") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="CircleShape2D" id="CircleShape2D_0vxfv"] +radius = 3.0 + +[sub_resource type="CircleShape2D" id="CircleShape2D_e2yn3"] +radius = 3.0 + +[node name="Bullet0002" type="CharacterBody2D" node_paths=PackedStringArray("CollisionArea", "ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 2 +script = ExtResource("1_hepay") +CollisionArea = NodePath("AnimatedSprite/CollisionArea") +ShadowSprite = NodePath("ShadowSprite") +AnimatedSprite = NodePath("AnimatedSprite") +Collision = NodePath("Collision") + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_v77gw") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +modulate = Color(1.6, 1.6, 1.6, 1) +material = SubResource("ShaderMaterial_p0wfd") +sprite_frames = ExtResource("3_ldd0h") + +[node name="CollisionArea" type="Area2D" parent="AnimatedSprite"] +visible = false +collision_layer = 0 +collision_mask = 0 +monitorable = false + +[node name="CollisionShape2D" type="CollisionShape2D" parent="AnimatedSprite/CollisionArea"] +position = Vector2(-2.38419e-07, 0) +shape = SubResource("CircleShape2D_0vxfv") + +[node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("CircleShape2D_e2yn3") diff --git a/DungeonShooting_Godot/prefab/bullet/normal/Bullet0003.tscn b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0003.tscn new file mode 100644 index 0000000..65b9e2a --- /dev/null +++ b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0003.tscn @@ -0,0 +1,60 @@ +[gd_scene load_steps=7 format=3 uid="uid://ee24ocwk8snj"] + +[ext_resource type="Script" path="res://src/game/activity/bullet/normal/Bullet.cs" id="1_h6lfm"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_bteri"] +[ext_resource type="SpriteFrames" uid="uid://bcnhyin0aufl1" path="res://resource/spriteFrames/bullet/Bullet0003.tres" id="3_qvo0u"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_v77gw"] +resource_local_to_scene = true +shader = ExtResource("2_bteri") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_p0wfd"] +resource_local_to_scene = true +shader = ExtResource("2_bteri") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_c0onq"] +size = Vector2(6, 3.125) + +[node name="Bullet0003" type="CharacterBody2D" node_paths=PackedStringArray("CollisionArea", "ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 2 +script = ExtResource("1_h6lfm") +CollisionArea = NodePath("AnimatedSprite/CollisionArea") +ShadowSprite = NodePath("ShadowSprite") +AnimatedSprite = NodePath("AnimatedSprite") +Collision = NodePath("Collision") + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_v77gw") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +modulate = Color(1.6, 1.6, 1.6, 1) +material = SubResource("ShaderMaterial_p0wfd") +sprite_frames = ExtResource("3_qvo0u") + +[node name="CollisionArea" type="Area2D" parent="AnimatedSprite"] +visible = false +collision_layer = 0 +collision_mask = 0 +monitorable = false + +[node name="CollisionShape2D" type="CollisionShape2D" parent="AnimatedSprite/CollisionArea"] +position = Vector2(1, 0) +shape = SubResource("RectangleShape2D_c0onq") + +[node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_c0onq") diff --git a/DungeonShooting_Godot/prefab/bullet/normal/Bullet0004.tscn b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0004.tscn new file mode 100644 index 0000000..c798c13 --- /dev/null +++ b/DungeonShooting_Godot/prefab/bullet/normal/Bullet0004.tscn @@ -0,0 +1,96 @@ +[gd_scene load_steps=12 format=3 uid="uid://d0h4xfi1oqf1l"] + +[ext_resource type="Script" path="res://src/game/activity/bullet/normal/BoomBullet.cs" id="1_1jbgr"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_w1qob"] +[ext_resource type="SpriteFrames" uid="uid://d3vma1qjo478l" path="res://resource/spriteFrames/bullet/Bullet0004.tres" id="3_bttus"] +[ext_resource type="Texture2D" uid="uid://h7hkgbwj1li" path="res://resource/sprite/effects/common/Smoke.png" id="3_ofn8c"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_v77gw"] +resource_local_to_scene = true +shader = ExtResource("2_w1qob") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_p0wfd"] +resource_local_to_scene = true +shader = ExtResource("2_w1qob") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_c0onq"] +size = Vector2(4, 4) + +[sub_resource type="CanvasItemMaterial" id="CanvasItemMaterial_chi2i"] +particles_animation = true +particles_anim_h_frames = 3 +particles_anim_v_frames = 1 +particles_anim_loop = false + +[sub_resource type="Curve" id="Curve_dt320"] +_data = [Vector2(0, 0.730415), 0.0, 0.0, 0, 0, Vector2(0.245238, 1), 0.0, 0.0, 0, 0, Vector2(1, 0.0235023), 0.0, 0.0, 0, 0] +point_count = 3 + +[sub_resource type="CurveTexture" id="CurveTexture_uftx4"] +curve = SubResource("Curve_dt320") + +[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_kelfq"] +lifetime_randomness = 0.7 +particle_flag_disable_z = true +angle_max = 360.0 +spread = 180.0 +initial_velocity_min = 5.0 +initial_velocity_max = 15.0 +angular_velocity_max = 45.0 +gravity = Vector3(0, 0, 0) +scale_min = 0.15 +scale_max = 0.6 +scale_curve = SubResource("CurveTexture_uftx4") +color = Color(0.619608, 0.619608, 0.619608, 1) +anim_offset_max = 1.0 + +[node name="Bullet0003" type="CharacterBody2D" node_paths=PackedStringArray("CollisionArea", "ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 2 +script = ExtResource("1_1jbgr") +CollisionArea = NodePath("AnimatedSprite/CollisionArea") +ShadowSprite = NodePath("ShadowSprite") +AnimatedSprite = NodePath("AnimatedSprite") +Collision = NodePath("Collision") + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_v77gw") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +material = SubResource("ShaderMaterial_p0wfd") +sprite_frames = ExtResource("3_bttus") +animation = &"move" +frame_progress = 0.0471243 + +[node name="CollisionArea" type="Area2D" parent="AnimatedSprite"] +collision_layer = 0 +collision_mask = 0 +monitorable = false + +[node name="CollisionShape2D" type="CollisionShape2D" parent="AnimatedSprite/CollisionArea"] +position = Vector2(1, 0) +shape = SubResource("RectangleShape2D_c0onq") + +[node name="GPUParticles2D" type="GPUParticles2D" parent="AnimatedSprite"] +material = SubResource("CanvasItemMaterial_chi2i") +amount = 10 +process_material = SubResource("ParticleProcessMaterial_kelfq") +texture = ExtResource("3_ofn8c") +lifetime = 0.5 + +[node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_c0onq") diff --git a/DungeonShooting_Godot/prefab/effect/enemy/Effect0001.tscn b/DungeonShooting_Godot/prefab/effect/enemy/Effect0001.tscn index 6b7176e..4461145 100644 --- a/DungeonShooting_Godot/prefab/effect/enemy/Effect0001.tscn +++ b/DungeonShooting_Godot/prefab/effect/enemy/Effect0001.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=30 format=3 uid="uid://pr88a1phtxgb"] +[gd_scene load_steps=31 format=3 uid="uid://pr88a1phtxgb"] [ext_resource type="Script" path="res://src/game/effects/EnemyDebris.cs" id="1_ttosm"] [ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_h62s7"] @@ -14,6 +14,7 @@ shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_08fn3"] shader = ExtResource("2_h62s7") @@ -23,6 +24,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="AtlasTexture" id="AtlasTexture_cldwb"] atlas = ExtResource("3_6ewaj") @@ -144,6 +146,9 @@ "speed": 5.0 }] +[sub_resource type="CircleShape2D" id="CircleShape2D_0xl2q"] +radius = 4.0 + [sub_resource type="CanvasItemMaterial" id="CanvasItemMaterial_p3lv8"] particles_animation = true particles_anim_h_frames = 3 @@ -165,10 +170,8 @@ [sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_ku1mm"] particle_flag_disable_z = true -gravity = Vector3(0, 0, 0) -orbit_velocity_min = 0.0 -orbit_velocity_max = 0.0 angle_max = 360.0 +gravity = Vector3(0, 0, 0) scale_min = 0.4 scale_max = 1.5 scale_curve = SubResource("CurveTexture_rutlp") @@ -177,6 +180,7 @@ anim_offset_max = 1.0 [node name="Effect0001" type="CharacterBody2D" node_paths=PackedStringArray("ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 128 script = ExtResource("1_ttosm") ShadowSprite = NodePath("ShadowSprite") AnimatedSprite = NodePath("AnimatedSprite") @@ -191,6 +195,7 @@ sprite_frames = SubResource("SpriteFrames_15g84") [node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("CircleShape2D_0xl2q") [node name="GPUParticles2D" type="GPUParticles2D" parent="."] material = SubResource("CanvasItemMaterial_p3lv8") diff --git a/DungeonShooting_Godot/prefab/effect/weapon/ShotFire.tscn b/DungeonShooting_Godot/prefab/effect/weapon/ShotFire.tscn index b0161a5..8a03b47 100644 --- a/DungeonShooting_Godot/prefab/effect/weapon/ShotFire.tscn +++ b/DungeonShooting_Godot/prefab/effect/weapon/ShotFire.tscn @@ -39,10 +39,11 @@ "speed": 20.0 }] -[node name="ShotFire" type="AnimatedSprite2D"] +[node name="ShotFire" type="AnimatedSprite2D" node_paths=PackedStringArray("Particles2D")] modulate = Color(1.6, 1.6, 1.6, 1) sprite_frames = SubResource("SpriteFrames_73j16") autoplay = "default" offset = Vector2(8, 0) script = ExtResource("2_lnwju") DelayTime = 0.2 +Particles2D = [] diff --git a/DungeonShooting_Godot/prefab/effect/weapon/ShotFire2.tscn b/DungeonShooting_Godot/prefab/effect/weapon/ShotFire2.tscn new file mode 100644 index 0000000..d2c9f8b --- /dev/null +++ b/DungeonShooting_Godot/prefab/effect/weapon/ShotFire2.tscn @@ -0,0 +1,49 @@ +[gd_scene load_steps=8 format=3 uid="uid://drcvbo0xam6q"] + +[ext_resource type="Texture2D" uid="uid://cj8gb5dxnk8ov" path="res://resource/sprite/effects/weapon/ShotFire2.png" id="1_ljjfn"] +[ext_resource type="Script" path="res://src/game/effects/AutoDestroySprite.cs" id="2_4ecjw"] + +[sub_resource type="AtlasTexture" id="AtlasTexture_2nk6j"] +atlas = ExtResource("1_ljjfn") +region = Rect2(0, 0, 9, 11) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ht7ag"] +atlas = ExtResource("1_ljjfn") +region = Rect2(9, 0, 9, 11) + +[sub_resource type="AtlasTexture" id="AtlasTexture_jwqy0"] +atlas = ExtResource("1_ljjfn") +region = Rect2(18, 0, 9, 11) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ud7n7"] +atlas = ExtResource("1_ljjfn") +region = Rect2(27, 0, 9, 11) + +[sub_resource type="SpriteFrames" id="SpriteFrames_rry1m"] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": SubResource("AtlasTexture_2nk6j") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ht7ag") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_jwqy0") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ud7n7") +}], +"loop": false, +"name": &"default", +"speed": 20.0 +}] + +[node name="ShotFire2" type="AnimatedSprite2D" node_paths=PackedStringArray("Particles2D")] +modulate = Color(1.6, 1.6, 1.6, 1) +sprite_frames = SubResource("SpriteFrames_rry1m") +autoplay = "default" +offset = Vector2(5.5, 0) +script = ExtResource("2_4ecjw") +DelayTime = 0.2 +Particles2D = [] diff --git a/DungeonShooting_Godot/prefab/map/RoomDoor_E.tscn b/DungeonShooting_Godot/prefab/map/RoomDoor_E.tscn index 3a07eb2..2631c7c 100644 --- a/DungeonShooting_Godot/prefab/map/RoomDoor_E.tscn +++ b/DungeonShooting_Godot/prefab/map/RoomDoor_E.tscn @@ -14,6 +14,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_t4ayq"] resource_local_to_scene = true @@ -24,6 +25,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="RectangleShape2D" id="RectangleShape2D_opsb6"] resource_local_to_scene = true diff --git a/DungeonShooting_Godot/prefab/map/RoomDoor_N.tscn b/DungeonShooting_Godot/prefab/map/RoomDoor_N.tscn index 52a7d64..0c6565e 100644 --- a/DungeonShooting_Godot/prefab/map/RoomDoor_N.tscn +++ b/DungeonShooting_Godot/prefab/map/RoomDoor_N.tscn @@ -13,6 +13,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_t4ayq"] resource_local_to_scene = true @@ -23,6 +24,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="RectangleShape2D" id="RectangleShape2D_opsb6"] resource_local_to_scene = true diff --git a/DungeonShooting_Godot/prefab/map/RoomDoor_S.tscn b/DungeonShooting_Godot/prefab/map/RoomDoor_S.tscn index 6c07aba..a2996d7 100644 --- a/DungeonShooting_Godot/prefab/map/RoomDoor_S.tscn +++ b/DungeonShooting_Godot/prefab/map/RoomDoor_S.tscn @@ -13,6 +13,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_t4ayq"] resource_local_to_scene = true @@ -23,6 +24,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="RectangleShape2D" id="RectangleShape2D_opsb6"] resource_local_to_scene = true diff --git a/DungeonShooting_Godot/prefab/map/RoomDoor_W.tscn b/DungeonShooting_Godot/prefab/map/RoomDoor_W.tscn index d3c5a08..727c632 100644 --- a/DungeonShooting_Godot/prefab/map/RoomDoor_W.tscn +++ b/DungeonShooting_Godot/prefab/map/RoomDoor_W.tscn @@ -14,6 +14,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_t4ayq"] resource_local_to_scene = true @@ -24,6 +25,7 @@ shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="RectangleShape2D" id="RectangleShape2D_2ko2r"] resource_local_to_scene = true diff --git a/DungeonShooting_Godot/prefab/role/Role0001.tscn b/DungeonShooting_Godot/prefab/role/Role0001.tscn index 3da3053..fd8b964 100644 --- a/DungeonShooting_Godot/prefab/role/Role0001.tscn +++ b/DungeonShooting_Godot/prefab/role/Role0001.tscn @@ -14,6 +14,7 @@ shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_8hgu2"] resource_local_to_scene = true @@ -24,6 +25,7 @@ shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [node name="Role0001" node_paths=PackedStringArray("HurtArea", "HurtCollision", "MountPoint", "BackMountPoint", "InteractiveArea", "InteractiveCollision", "MeleeAttackArea", "MeleeAttackCollision", "ShadowSprite", "AnimatedSprite", "Collision") instance=ExtResource("1_10c2n")] collision_layer = 8 diff --git a/DungeonShooting_Godot/prefab/role/RoleTemplate.tscn b/DungeonShooting_Godot/prefab/role/RoleTemplate.tscn index 559a842..584b37c 100644 --- a/DungeonShooting_Godot/prefab/role/RoleTemplate.tscn +++ b/DungeonShooting_Godot/prefab/role/RoleTemplate.tscn @@ -12,6 +12,7 @@ shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_yif6x"] resource_local_to_scene = true @@ -22,6 +23,7 @@ shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="CircleShape2D" id="CircleShape2D_5pj80"] radius = 4.0 diff --git a/DungeonShooting_Godot/prefab/shell/Shell0001.tscn b/DungeonShooting_Godot/prefab/shell/Shell0001.tscn index b798a43..eceaf5d 100644 --- a/DungeonShooting_Godot/prefab/shell/Shell0001.tscn +++ b/DungeonShooting_Godot/prefab/shell/Shell0001.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=6 format=3 uid="uid://bj4yr6ru8nhwr"] +[gd_scene load_steps=7 format=3 uid="uid://bj4yr6ru8nhwr"] [ext_resource type="Script" path="res://src/game/activity/shell/Shell.cs" id="1_2g70c"] [ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_tdny6"] @@ -9,20 +9,25 @@ shader = ExtResource("2_tdny6") shader_parameter/blend = Color(0, 0, 0, 0.470588) shader_parameter/schedule = 1.0 -shader_parameter/alpha = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_7e6fo"] resource_local_to_scene = true shader = ExtResource("2_tdny6") shader_parameter/blend = Color(1, 1, 1, 1) shader_parameter/schedule = 0.0 -shader_parameter/alpha = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_fidao"] +size = Vector2(3.75, 1.25) [node name="Shell0001" type="CharacterBody2D" node_paths=PackedStringArray("ShadowSprite", "AnimatedSprite", "Collision")] collision_layer = 128 @@ -40,3 +45,4 @@ sprite_frames = ExtResource("3_ujn5y") [node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_fidao") diff --git a/DungeonShooting_Godot/prefab/shell/Shell0002.tscn b/DungeonShooting_Godot/prefab/shell/Shell0002.tscn index 1f8893e..7fc2e03 100644 --- a/DungeonShooting_Godot/prefab/shell/Shell0002.tscn +++ b/DungeonShooting_Godot/prefab/shell/Shell0002.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=6 format=3 uid="uid://cdhinm8rnppxt"] +[gd_scene load_steps=7 format=3 uid="uid://cdhinm8rnppxt"] [ext_resource type="Script" path="res://src/game/activity/shell/Shell.cs" id="1_qi64y"] [ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_s28nu"] @@ -9,20 +9,25 @@ shader = ExtResource("2_s28nu") shader_parameter/blend = Color(0, 0, 0, 0.470588) shader_parameter/schedule = 1.0 -shader_parameter/alpha = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_7e6fo"] resource_local_to_scene = true shader = ExtResource("2_s28nu") shader_parameter/blend = Color(1, 1, 1, 1) shader_parameter/schedule = 0.0 -shader_parameter/alpha = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_3ib07"] +size = Vector2(4, 2) [node name="Shell0002" type="CharacterBody2D" node_paths=PackedStringArray("ShadowSprite", "AnimatedSprite", "Collision")] collision_layer = 128 @@ -40,3 +45,4 @@ sprite_frames = ExtResource("3_r560h") [node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_3ib07") diff --git a/DungeonShooting_Godot/prefab/shell/Shell0003.tscn b/DungeonShooting_Godot/prefab/shell/Shell0003.tscn index 4d85f05..fecfbcb 100644 --- a/DungeonShooting_Godot/prefab/shell/Shell0003.tscn +++ b/DungeonShooting_Godot/prefab/shell/Shell0003.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=6 format=3 uid="uid://ba5sxxjaappbj"] +[gd_scene load_steps=7 format=3 uid="uid://ba5sxxjaappbj"] [ext_resource type="Script" path="res://src/game/activity/shell/Shell.cs" id="1_5hfb2"] [ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_586dn"] @@ -9,20 +9,25 @@ shader = ExtResource("2_586dn") shader_parameter/blend = Color(0, 0, 0, 0.470588) shader_parameter/schedule = 1.0 -shader_parameter/alpha = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_7e6fo"] resource_local_to_scene = true shader = ExtResource("2_586dn") shader_parameter/blend = Color(1, 1, 1, 1) shader_parameter/schedule = 0.0 -shader_parameter/alpha = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) shader_parameter/show_outline = false shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_r7wle"] +size = Vector2(4, 2) [node name="Shell0003" type="CharacterBody2D" node_paths=PackedStringArray("ShadowSprite", "AnimatedSprite", "Collision")] collision_layer = 128 @@ -40,3 +45,4 @@ sprite_frames = ExtResource("3_j2kre") [node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_r7wle") diff --git a/DungeonShooting_Godot/prefab/shell/Shell0004.tscn b/DungeonShooting_Godot/prefab/shell/Shell0004.tscn new file mode 100644 index 0000000..42d8fd0 --- /dev/null +++ b/DungeonShooting_Godot/prefab/shell/Shell0004.tscn @@ -0,0 +1,48 @@ +[gd_scene load_steps=7 format=3 uid="uid://ycr5mjr25302"] + +[ext_resource type="Script" path="res://src/game/activity/shell/Shell.cs" id="1_ridlp"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_guwkk"] +[ext_resource type="SpriteFrames" uid="uid://b8b0ye3iv1vwp" path="res://resource/spriteFrames/shell/Shell0004.tres" id="3_1s5f3"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_px12l"] +resource_local_to_scene = true +shader = ExtResource("2_guwkk") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_7e6fo"] +resource_local_to_scene = true +shader = ExtResource("2_guwkk") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = false +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_ighya"] +size = Vector2(4, 3) + +[node name="Shell0004" type="CharacterBody2D" node_paths=PackedStringArray("ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 128 +script = ExtResource("1_ridlp") +ShadowSprite = NodePath("ShadowSprite") +AnimatedSprite = NodePath("AnimatedSprite") +Collision = NodePath("Collision") + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_px12l") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +material = SubResource("ShaderMaterial_7e6fo") +sprite_frames = ExtResource("3_1s5f3") + +[node name="Collision" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_ighya") diff --git a/DungeonShooting_Godot/prefab/ui/Debugger.tscn b/DungeonShooting_Godot/prefab/ui/Debugger.tscn index cf76f5b..fcd8420 100644 --- a/DungeonShooting_Godot/prefab/ui/Debugger.tscn +++ b/DungeonShooting_Godot/prefab/ui/Debugger.tscn @@ -68,3 +68,14 @@ icon = ExtResource("2_acjpv") flat = true icon_alignment = 1 + +[node name="Fps" type="Label" parent="."] +layout_mode = 1 +anchors_preset = 5 +anchor_left = 0.5 +anchor_right = 0.5 +offset_left = -4.5 +offset_right = 4.5 +offset_bottom = 40.0 +grow_horizontal = 2 +text = "FPS:60" diff --git a/DungeonShooting_Godot/prefab/weapon/Weapon0007.tscn b/DungeonShooting_Godot/prefab/weapon/Weapon0007.tscn index 0467857..b4a5c1c 100644 --- a/DungeonShooting_Godot/prefab/weapon/Weapon0007.tscn +++ b/DungeonShooting_Godot/prefab/weapon/Weapon0007.tscn @@ -14,6 +14,7 @@ shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="ShaderMaterial" id="ShaderMaterial_277ni"] resource_local_to_scene = true @@ -24,6 +25,7 @@ shader_parameter/show_outline = true shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true [sub_resource type="RectangleShape2D" id="RectangleShape2D_4pn1i"] size = Vector2(20, 6) diff --git a/DungeonShooting_Godot/prefab/weapon/Weapon0008.tscn b/DungeonShooting_Godot/prefab/weapon/Weapon0008.tscn new file mode 100644 index 0000000..d43a8bc --- /dev/null +++ b/DungeonShooting_Godot/prefab/weapon/Weapon0008.tscn @@ -0,0 +1,136 @@ +[gd_scene load_steps=11 format=3 uid="uid://yt10i80hs3gt"] + +[ext_resource type="Script" path="res://src/game/activity/weapon/gun/Gun.cs" id="1_l63x2"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="1_mhoa7"] +[ext_resource type="SpriteFrames" uid="uid://b2wpy40adyjs6" path="res://resource/spriteFrames/weapon/Weapon0008.tres" id="2_s0xbw"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_cbiyh"] +resource_local_to_scene = true +shader = ExtResource("1_mhoa7") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = true +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_o36tv"] +resource_local_to_scene = true +shader = ExtResource("1_mhoa7") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = true +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_evjpf"] +size = Vector2(12, 6) + +[sub_resource type="Animation" id="Animation_x136i"] +length = 0.001 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("AnimatedSprite:material:shader_parameter/schedule") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath(".:rotation") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} + +[sub_resource type="Animation" id="Animation_3piau"] +resource_name = "floodlight" +length = 3.0 +loop_mode = 1 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("AnimatedSprite:material:shader_parameter/schedule") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0, 2.3, 2.6, 2.7, 3), +"transitions": PackedFloat32Array(1, 1, 1, 1, 1), +"update": 0, +"values": [0, 0, 0.5, 0.5, 0] +} + +[sub_resource type="Animation" id="Animation_8xqs8"] +resource_name = "reloading" +length = 1.3 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath(".:rotation") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0, 0.2, 1.1, 1.3), +"transitions": PackedFloat32Array(1, 1, 1, 1), +"update": 0, +"values": [0.0, -0.436332, -0.436332, 0.0] +} + +[sub_resource type="AnimationLibrary" id="AnimationLibrary_trkjd"] +_data = { +"RESET": SubResource("Animation_x136i"), +"floodlight": SubResource("Animation_3piau"), +"reloading": SubResource("Animation_8xqs8") +} + +[node name="Weapon0008" type="CharacterBody2D" node_paths=PackedStringArray("FirePoint", "ShellPoint", "GripPoint", "AnimationPlayer", "ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 4 +script = ExtResource("1_l63x2") +FirePoint = NodePath("AnimatedSprite/FirePoint") +ShellPoint = NodePath("AnimatedSprite/ShellPoint") +GripPoint = NodePath("GripPoint") +AnimationPlayer = NodePath("AnimationPlayer") +ShadowSprite = NodePath("ShadowSprite") +AnimatedSprite = NodePath("AnimatedSprite") +Collision = NodePath("Collision") + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_cbiyh") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +modulate = Color(1.9, 1.9, 1.9, 1) +material = SubResource("ShaderMaterial_o36tv") +sprite_frames = ExtResource("2_s0xbw") +animation = &"reloading" + +[node name="ShellPoint" type="Marker2D" parent="AnimatedSprite"] +position = Vector2(-2, -3) + +[node name="FirePoint" type="Marker2D" parent="AnimatedSprite"] +position = Vector2(7, -1.5) + +[node name="GripPoint" type="Marker2D" parent="."] +position = Vector2(-5, 0) + +[node name="Collision" type="CollisionShape2D" parent="."] +position = Vector2(1, 0) +shape = SubResource("RectangleShape2D_evjpf") + +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +libraries = { +"": SubResource("AnimationLibrary_trkjd") +} diff --git a/DungeonShooting_Godot/prefab/weapon/Weapon0009.tscn b/DungeonShooting_Godot/prefab/weapon/Weapon0009.tscn new file mode 100644 index 0000000..e8a8c26 --- /dev/null +++ b/DungeonShooting_Godot/prefab/weapon/Weapon0009.tscn @@ -0,0 +1,185 @@ +[gd_scene load_steps=11 format=3 uid="uid://2lb2h8qunqyu"] + +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="1_6fbtx"] +[ext_resource type="Script" path="res://src/game/activity/weapon/gun/Gun.cs" id="1_eprgt"] +[ext_resource type="SpriteFrames" uid="uid://c0xwj3kpk02ua" path="res://resource/spriteFrames/weapon/Weapon0009.tres" id="2_4kxpd"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_cbiyh"] +resource_local_to_scene = true +shader = ExtResource("1_6fbtx") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = true +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_o36tv"] +resource_local_to_scene = true +shader = ExtResource("1_6fbtx") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0.0 +shader_parameter/modulate = Color(1, 1, 1, 1) +shader_parameter/show_outline = true +shader_parameter/outline_color = Color(0, 0, 0, 1) +shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_jbuu3"] +size = Vector2(18, 6) + +[sub_resource type="Animation" id="Animation_x136i"] +length = 0.001 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("AnimatedSprite:material:shader_parameter/schedule") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath(".:rotation") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [0.0] +} +tracks/2/type = "value" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("AnimatedSprite:animation") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [&"reloading_frame"] +} +tracks/3/type = "value" +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/path = NodePath("AnimatedSprite:frame") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [0] +} + +[sub_resource type="Animation" id="Animation_3piau"] +resource_name = "floodlight" +length = 3.0 +loop_mode = 1 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath("AnimatedSprite:material:shader_parameter/schedule") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0, 2.3, 2.6, 2.7, 3), +"transitions": PackedFloat32Array(1, 1, 1, 1, 1), +"update": 0, +"values": [0, 0, 0.5, 0.5, 0] +} + +[sub_resource type="Animation" id="Animation_juv2q"] +resource_name = "reloading" +length = 1.5 +step = 0.02 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath(".:rotation") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0, 0.14, 0.2, 1.14, 1.2, 1.36, 1.5), +"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1), +"update": 0, +"values": [0.0, -0.523599, 0.0, 0.0, -0.349066, -0.349066, 0.0] +} +tracks/1/type = "value" +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/path = NodePath("AnimatedSprite:animation") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/keys = { +"times": PackedFloat32Array(0), +"transitions": PackedFloat32Array(1), +"update": 1, +"values": [&"reloading_frame"] +} +tracks/2/type = "value" +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/path = NodePath("AnimatedSprite:frame") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/keys = { +"times": PackedFloat32Array(0, 0.22, 0.24, 1.22, 1.24), +"transitions": PackedFloat32Array(1, 1, 1, 1, 1), +"update": 1, +"values": [0, 1, 2, 3, 4] +} + +[sub_resource type="AnimationLibrary" id="AnimationLibrary_trkjd"] +_data = { +"RESET": SubResource("Animation_x136i"), +"floodlight": SubResource("Animation_3piau"), +"reloading": SubResource("Animation_juv2q") +} + +[node name="Weapon0009" type="CharacterBody2D" node_paths=PackedStringArray("FirePoint", "ShellPoint", "GripPoint", "AnimationPlayer", "ShadowSprite", "AnimatedSprite", "Collision")] +collision_layer = 4 +script = ExtResource("1_eprgt") +FirePoint = NodePath("AnimatedSprite/FirePoint") +ShellPoint = NodePath("AnimatedSprite/ShellPoint") +GripPoint = NodePath("GripPoint") +AnimationPlayer = NodePath("AnimationPlayer") +ShadowSprite = NodePath("ShadowSprite") +AnimatedSprite = NodePath("AnimatedSprite") +Collision = NodePath("Collision") + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_cbiyh") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +material = SubResource("ShaderMaterial_o36tv") +sprite_frames = ExtResource("2_4kxpd") +animation = &"reloading_frame" + +[node name="ShellPoint" type="Marker2D" parent="AnimatedSprite"] +position = Vector2(-2, -2) + +[node name="FirePoint" type="Marker2D" parent="AnimatedSprite"] +position = Vector2(13, -0.5) + +[node name="GripPoint" type="Marker2D" parent="."] +position = Vector2(-6, 1) + +[node name="Collision" type="CollisionShape2D" parent="."] +visible = false +position = Vector2(0, 1) +shape = SubResource("RectangleShape2D_jbuu3") + +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +libraries = { +"": SubResource("AnimationLibrary_trkjd") +} diff --git a/DungeonShooting_Godot/project.godot b/DungeonShooting_Godot/project.godot index 8f16079..83159ea 100644 --- a/DungeonShooting_Godot/project.godot +++ b/DungeonShooting_Godot/project.godot @@ -192,7 +192,7 @@ 2d_physics/layer_5="enemy" 2d_physics/layer_6="affiliation" 2d_physics/layer_7="onHead" -2d_physics/layer_8="shell" +2d_physics/layer_8="debris" 2d_physics/layer_9="throwing" [mono] diff --git a/DungeonShooting_Godot/resource/config/ActivityBase.json b/DungeonShooting_Godot/resource/config/ActivityBase.json new file mode 100644 index 0000000..99ef530 --- /dev/null +++ b/DungeonShooting_Godot/resource/config/ActivityBase.json @@ -0,0 +1,434 @@ +[ + { + "Id": "role0001", + "Type": 3, + "Name": "\u73A9\u5BB6", + "Intro": "\u73A9\u5BB6", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/role/Role0001.tscn", + "Icon": "res://resource/sprite/role/role0001/Role0001_Icon.png", + "ShowInMapEditor": false + }, + { + "Id": "enemy0001", + "Type": 4, + "Name": "\u654C\u4EBA", + "Intro": "\u654C\u4EBA", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/role/Enemy0001.tscn", + "Icon": "res://resource/sprite/role/enemy0001/enemy0001_Icon.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0001", + "Type": 5, + "Name": "\u6B65\u67AA", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0001.tscn", + "Icon": "res://resource/sprite/weapon/weapon0001/Weapon0001.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0002", + "Type": 5, + "Name": "\u9730\u5F39\u67AA", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0002.tscn", + "Icon": "res://resource/sprite/weapon/weapon0002/Weapon0002.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0003", + "Type": 5, + "Name": "\u624B\u67AA", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0003.tscn", + "Icon": "res://resource/sprite/weapon/weapon0003/Weapon0003.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0004", + "Type": 5, + "Name": "\u5200", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0004.tscn", + "Icon": "res://resource/sprite/weapon/knife1.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0005", + "Type": 5, + "Name": "\u72D9\u51FB\u67AA", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0005.tscn", + "Icon": "res://resource/sprite/weapon/weapon0005/Weapon0005.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0006", + "Type": 5, + "Name": "\u51B2\u950B\u67AA", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0006.tscn", + "Icon": "res://resource/sprite/weapon/weapon0006/Weapon0006.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0007", + "Type": 5, + "Name": "\u6C64\u59C6\u900A\u51B2\u950B\u67AA", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0007.tscn", + "Icon": "res://resource/sprite/weapon/weapon0007/Weapon0007.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0008", + "Type": 5, + "Name": "\u6FC0\u5149\u624B\u67AA", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0008.tscn", + "Icon": "res://resource/sprite/weapon/weapon0008/Weapon0008.png", + "ShowInMapEditor": true + }, + { + "Id": "weapon0009", + "Type": 5, + "Name": "\u69B4\u5F39\u53D1\u5C04\u5668", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/weapon/Weapon0009.tscn", + "Icon": "res://resource/sprite/weapon/weapon0009/Weapon0009.png", + "ShowInMapEditor": true + }, + { + "Id": "bullet0001", + "Type": 6, + "Name": "", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/bullet/normal/Bullet0001.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "bullet0002", + "Type": 6, + "Name": "", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/bullet/normal/Bullet0002.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "bullet0003", + "Type": 6, + "Name": "", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/bullet/normal/Bullet0003.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "bullet0004", + "Type": 6, + "Name": "\u69B4\u5F39\u70AE", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "0002", + "Prefab": "res://prefab/bullet/normal/Bullet0004.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "shell0001", + "Type": 7, + "Name": "", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/shell/Shell0001.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "shell0002", + "Type": 7, + "Name": "", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/shell/Shell0002.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "shell0003", + "Type": 7, + "Name": "", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/shell/Shell0003.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "shell0004", + "Type": 7, + "Name": "", + "Intro": "", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/shell/Shell0004.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "effect0001", + "Type": 8, + "Name": "", + "Intro": "\u654C\u4EBA\u6B7B\u4EA1\u788E\u7247", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/effect/enemy/Effect0001.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "prop0001", + "Type": 9, + "Name": "\u978B\u5B50", + "Intro": "\u63D0\u9AD8\u79FB\u52A8\u901F\u5EA6", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/effect/enemy/Effect0001.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0001.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0002", + "Type": 9, + "Name": "\u5FC3\u4E4B\u5BB9\u5668", + "Intro": "\u63D0\u9AD8\u8840\u91CF\u4E0A\u9650", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0002.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0002.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0003", + "Type": 9, + "Name": "\u62A4\u76FE", + "Intro": "\u53EF\u4EE5\u62B5\u6321\u5B50\u5F39\uFF0C\u968F\u65F6\u95F4\u63A8\u79FB\u81EA\u52A8\u6062\u590D", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0003.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0003.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0004", + "Type": 9, + "Name": "\u62A4\u76FE\u8BA1\u65F6\u5668", + "Intro": "\u63D0\u9AD8\u62A4\u76FE\u6062\u590D\u901F\u5EA6", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0004.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0004.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0005", + "Type": 9, + "Name": "\u6740\u4F24\u5F39", + "Intro": "\u63D0\u9AD8\u5B50\u5F39\u4F24\u5BB3", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0005.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0005.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0006", + "Type": 9, + "Name": "\u7EA2\u5B9D\u77F3\u6212\u6307", + "Intro": "\u53D7\u4F24\u540E\u5EF6\u957F\u65E0\u654C\u65F6\u95F4", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0006.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0006.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0007", + "Type": 9, + "Name": "\u5907\u7528\u62A4\u76FE", + "Intro": "\u53D7\u4F24\u65F6\u6709\u4E00\u5B9A\u6982\u7387\u62B5\u6D88\u4F24\u5BB3", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0007.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0007.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0008", + "Type": 9, + "Name": "\u773C\u955C", + "Intro": "\u63D0\u9AD8\u6B66\u5668\u7CBE\u51C6\u5EA6", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0008.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0008.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0009", + "Type": 9, + "Name": "\u9AD8\u901F\u5B50\u5F39", + "Intro": "\u63D0\u9AD8\u5B50\u5F39\u901F\u5EA6\u548C\u5C04\u7A0B", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0009.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0009.png", + "ShowInMapEditor": true + }, + { + "Id": "prop0010", + "Type": 9, + "Name": "\u5206\u88C2\u5B50\u5F39", + "Intro": "\u5B50\u5F39\u6570\u91CF\u7FFB\u500D, \u4F46\u662F\u7CBE\u51C6\u5EA6\u548C\u4F24\u5BB3\u964D\u4F4E", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/buff/BuffProp0010.tscn", + "Icon": "res://resource/sprite/prop/buff/BuffProp0010.png", + "ShowInMapEditor": true + }, + { + "Id": "prop5000", + "Type": 9, + "Name": "\u533B\u836F\u7BB1", + "Intro": "\u4F7F\u7528\u540E\u56DE\u590D\u4E00\u9897\u7EA2\u5FC3", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/active/ActiveProp5000.tscn", + "Icon": "res://resource/sprite/prop/active/ActiveProp5000.png", + "ShowInMapEditor": true + }, + { + "Id": "prop5001", + "Type": 9, + "Name": "\u5F39\u836F\u7BB1", + "Intro": "\u4F7F\u7528\u540E\u8865\u5145\u5F53\u524D\u6B66\u5668\u5907\u7528\u5F39\u836F", + "Details": "", + "IsStatic": false, + "__Material": "", + "Prefab": "res://prefab/prop/active/ActiveProp5001.tscn", + "Icon": "res://resource/sprite/prop/active/ActiveProp5001.png", + "ShowInMapEditor": true + }, + { + "Id": "other_door_e", + "Type": 99, + "Name": "", + "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u4E1C\u4FA7)", + "Details": "", + "IsStatic": true, + "__Material": "", + "Prefab": "res://prefab/map/RoomDoor_E.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "other_door_w", + "Type": 99, + "Name": "", + "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u897F\u4FA7)", + "Details": "", + "IsStatic": true, + "__Material": "", + "Prefab": "res://prefab/map/RoomDoor_W.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "other_door_s", + "Type": 99, + "Name": "", + "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u5357\u4FA7)", + "Details": "", + "IsStatic": true, + "__Material": "", + "Prefab": "res://prefab/map/RoomDoor_S.tscn", + "Icon": "", + "ShowInMapEditor": false + }, + { + "Id": "other_door_n", + "Type": 99, + "Name": "", + "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u5317\u4FA7)", + "Details": "", + "IsStatic": true, + "__Material": "", + "Prefab": "res://prefab/map/RoomDoor_N.tscn", + "Icon": "", + "ShowInMapEditor": false + } +] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/config/ActivityMaterial.json b/DungeonShooting_Godot/resource/config/ActivityMaterial.json new file mode 100644 index 0000000..a6cffda --- /dev/null +++ b/DungeonShooting_Godot/resource/config/ActivityMaterial.json @@ -0,0 +1,24 @@ +[ + { + "Id": "0001", + "Remark": "\u9ED8\u8BA4\u6750\u8D28\u5C5E\u6027", + "Friction": 140, + "RotationFriction": 140, + "Bounce": true, + "BounceStrength": 0.5, + "FallBounceStrength": 0.5, + "FallBounceSpeed": 0.75, + "FallBounceRotation": 0.5 + }, + { + "Id": "0002", + "Remark": "\u7403\u4F53\u6750\u8D28\uFF0C\u6469\u64E6\u529B\u8F83\u4F4E", + "Friction": 40, + "RotationFriction": 40, + "Bounce": true, + "BounceStrength": 0.7, + "FallBounceStrength": 0.7, + "FallBounceSpeed": 0.85, + "FallBounceRotation": 0.85 + } +] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/config/ActivityObject.json b/DungeonShooting_Godot/resource/config/ActivityObject.json deleted file mode 100644 index 49cb525..0000000 --- a/DungeonShooting_Godot/resource/config/ActivityObject.json +++ /dev/null @@ -1,322 +0,0 @@ -[ - { - "Id": "role0001", - "Type": 3, - "Name": "\u73A9\u5BB6", - "Intro": "\u73A9\u5BB6", - "Details": "", - "Prefab": "res://prefab/role/Role0001.tscn", - "Icon": "res://resource/sprite/role/role0001/Role0001_Icon.png", - "ShowInMapEditor": false - }, - { - "Id": "enemy0001", - "Type": 4, - "Name": "\u654C\u4EBA", - "Intro": "\u654C\u4EBA", - "Details": "", - "Prefab": "res://prefab/role/Enemy0001.tscn", - "Icon": "res://resource/sprite/role/enemy0001/enemy0001_Icon.png", - "ShowInMapEditor": true - }, - { - "Id": "weapon0001", - "Type": 5, - "Name": "\u6B65\u67AA", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/weapon/Weapon0001.tscn", - "Icon": "res://resource/sprite/weapon/weapon0001/Weapon0001.png", - "ShowInMapEditor": true - }, - { - "Id": "weapon0002", - "Type": 5, - "Name": "\u9730\u5F39\u67AA", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/weapon/Weapon0002.tscn", - "Icon": "res://resource/sprite/weapon/weapon0002/Weapon0002.png", - "ShowInMapEditor": true - }, - { - "Id": "weapon0003", - "Type": 5, - "Name": "\u624B\u67AA", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/weapon/Weapon0003.tscn", - "Icon": "res://resource/sprite/weapon/weapon0003/Weapon0003.png", - "ShowInMapEditor": true - }, - { - "Id": "weapon0004", - "Type": 5, - "Name": "\u5200", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/weapon/Weapon0004.tscn", - "Icon": "res://resource/sprite/weapon/knife1.png", - "ShowInMapEditor": true - }, - { - "Id": "weapon0005", - "Type": 5, - "Name": "\u72D9\u51FB\u67AA", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/weapon/Weapon0005.tscn", - "Icon": "res://resource/sprite/weapon/weapon0005/Weapon0005.png", - "ShowInMapEditor": true - }, - { - "Id": "weapon0006", - "Type": 5, - "Name": "\u51B2\u950B\u67AA", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/weapon/Weapon0006.tscn", - "Icon": "res://resource/sprite/weapon/weapon0006/Weapon0006.png", - "ShowInMapEditor": true - }, - { - "Id": "weapon0007", - "Type": 5, - "Name": "\u6C64\u59C6\u900A\u51B2\u950B\u67AA", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/weapon/Weapon0007.tscn", - "Icon": "res://resource/sprite/weapon/weapon0007/Weapon0007.png", - "ShowInMapEditor": true - }, - { - "Id": "bullet0001", - "Type": 6, - "Name": "", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/bullet/Bullet0001.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "bullet0002", - "Type": 6, - "Name": "", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/bullet/Bullet0002.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "bullet0003", - "Type": 6, - "Name": "", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/bullet/Bullet0003.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "shell0001", - "Type": 7, - "Name": "", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/shell/Shell0001.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "shell0002", - "Type": 7, - "Name": "", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/shell/Shell0002.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "shell0003", - "Type": 7, - "Name": "", - "Intro": "", - "Details": "", - "Prefab": "res://prefab/shell/Shell0003.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "effect0001", - "Type": 8, - "Name": "", - "Intro": "\u654C\u4EBA\u6B7B\u4EA1\u788E\u7247", - "Details": "", - "Prefab": "res://prefab/effect/enemy/Effect0001.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "prop0001", - "Type": 9, - "Name": "\u978B\u5B50", - "Intro": "\u63D0\u9AD8\u79FB\u52A8\u901F\u5EA6", - "Details": "", - "Prefab": "res://prefab/effect/enemy/Effect0001.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0001.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0002", - "Type": 9, - "Name": "\u5FC3\u4E4B\u5BB9\u5668", - "Intro": "\u63D0\u9AD8\u8840\u91CF\u4E0A\u9650", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0002.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0002.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0003", - "Type": 9, - "Name": "\u62A4\u76FE", - "Intro": "\u53EF\u4EE5\u62B5\u6321\u5B50\u5F39\uFF0C\u968F\u65F6\u95F4\u63A8\u79FB\u81EA\u52A8\u6062\u590D", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0003.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0003.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0004", - "Type": 9, - "Name": "\u62A4\u76FE\u8BA1\u65F6\u5668", - "Intro": "\u63D0\u9AD8\u62A4\u76FE\u6062\u590D\u901F\u5EA6", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0004.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0004.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0005", - "Type": 9, - "Name": "\u6740\u4F24\u5F39", - "Intro": "\u63D0\u9AD8\u5B50\u5F39\u4F24\u5BB3", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0005.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0005.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0006", - "Type": 9, - "Name": "\u7EA2\u5B9D\u77F3\u6212\u6307", - "Intro": "\u53D7\u4F24\u540E\u5EF6\u957F\u65E0\u654C\u65F6\u95F4", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0006.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0006.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0007", - "Type": 9, - "Name": "\u5907\u7528\u62A4\u76FE", - "Intro": "\u53D7\u4F24\u65F6\u6709\u4E00\u5B9A\u6982\u7387\u62B5\u6D88\u4F24\u5BB3", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0007.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0007.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0008", - "Type": 9, - "Name": "\u773C\u955C", - "Intro": "\u63D0\u9AD8\u6B66\u5668\u7CBE\u51C6\u5EA6", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0008.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0008.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0009", - "Type": 9, - "Name": "\u9AD8\u901F\u5B50\u5F39", - "Intro": "\u63D0\u9AD8\u5B50\u5F39\u901F\u5EA6\u548C\u5C04\u7A0B", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0009.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0009.png", - "ShowInMapEditor": true - }, - { - "Id": "prop0010", - "Type": 9, - "Name": "\u5206\u88C2\u5B50\u5F39", - "Intro": "\u5B50\u5F39\u6570\u91CF\u7FFB\u500D, \u4F46\u662F\u7CBE\u51C6\u5EA6\u548C\u4F24\u5BB3\u964D\u4F4E", - "Details": "", - "Prefab": "res://prefab/prop/buff/BuffProp0010.tscn", - "Icon": "res://resource/sprite/prop/buff/BuffProp0010.png", - "ShowInMapEditor": true - }, - { - "Id": "prop5000", - "Type": 9, - "Name": "\u533B\u836F\u7BB1", - "Intro": "\u4F7F\u7528\u540E\u56DE\u590D\u4E00\u9897\u7EA2\u5FC3", - "Details": "", - "Prefab": "res://prefab/prop/active/ActiveProp5000.tscn", - "Icon": "res://resource/sprite/prop/active/ActiveProp5000.png", - "ShowInMapEditor": true - }, - { - "Id": "prop5001", - "Type": 9, - "Name": "\u5F39\u836F\u7BB1", - "Intro": "\u4F7F\u7528\u540E\u8865\u5145\u5F53\u524D\u6B66\u5668\u5907\u7528\u5F39\u836F", - "Details": "", - "Prefab": "res://prefab/prop/active/ActiveProp5001.tscn", - "Icon": "res://resource/sprite/prop/active/ActiveProp5001.png", - "ShowInMapEditor": true - }, - { - "Id": "other_door_e", - "Type": 99, - "Name": "", - "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u4E1C\u4FA7)", - "Details": "", - "Prefab": "res://prefab/map/RoomDoor_E.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "other_door_w", - "Type": 99, - "Name": "", - "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u897F\u4FA7)", - "Details": "", - "Prefab": "res://prefab/map/RoomDoor_W.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "other_door_s", - "Type": 99, - "Name": "", - "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u5357\u4FA7)", - "Details": "", - "Prefab": "res://prefab/map/RoomDoor_S.tscn", - "Icon": "", - "ShowInMapEditor": false - }, - { - "Id": "other_door_n", - "Type": 99, - "Name": "", - "Intro": "\u5730\u7262\u623F\u95F4\u7684\u95E8(\u5317\u4FA7)", - "Details": "", - "Prefab": "res://prefab/map/RoomDoor_N.tscn", - "Icon": "", - "ShowInMapEditor": false - } -] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/config/AiAttackAttr.json b/DungeonShooting_Godot/resource/config/AiAttackAttr.json index 010c512..3d27a46 100644 --- a/DungeonShooting_Godot/resource/config/AiAttackAttr.json +++ b/DungeonShooting_Godot/resource/config/AiAttackAttr.json @@ -64,5 +64,27 @@ "AttackLockAngle": false, "BulletSpeedScale": 0.35, "AmmoConsumptionProbability": 0 + }, + { + "Id": "0007", + "Remark": "\u6FC0\u5149\u6B66\u5668", + "FiringStand": true, + "ShowSubline": true, + "LockingTime": 1.5, + "LockAngleTime": 0.5, + "AttackLockAngle": true, + "BulletSpeedScale": 1, + "AmmoConsumptionProbability": 0 + }, + { + "Id": "0008", + "Remark": "\u69B4\u5F39\u70AE", + "FiringStand": true, + "ShowSubline": false, + "LockingTime": 1.5, + "LockAngleTime": 0.5, + "AttackLockAngle": true, + "BulletSpeedScale": 0.8, + "AmmoConsumptionProbability": 0 } ] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/config/BulletBase.json b/DungeonShooting_Godot/resource/config/BulletBase.json new file mode 100644 index 0000000..babab79 --- /dev/null +++ b/DungeonShooting_Godot/resource/config/BulletBase.json @@ -0,0 +1,233 @@ +[ + { + "Id": "0001", + "Name": "\u5B50\u5F391", + "Type": 1, + "Prefab": "bullet0001", + "HarmRange": [ + 4 + ], + "RepelRnage": [ + 20 + ], + "DeviationAngleRange": [ + 0 + ], + "SpeedRange": [ + 320, + 350 + ], + "LifeTimeRange": [ + -1 + ], + "DistanceRange": [ + 300, + 400 + ], + "UseGravity": false, + "VerticalSpeed": [ + 0 + ], + "BounceCount": [ + 0 + ], + "StrikeDestroy": true + }, + { + "Id": "0002", + "Name": "\u5B50\u5F392", + "Type": 1, + "Prefab": "bullet0002", + "HarmRange": [ + 4 + ], + "RepelRnage": [ + 30 + ], + "DeviationAngleRange": [ + -10, + 10 + ], + "SpeedRange": [ + 280, + 380 + ], + "LifeTimeRange": [ + -1 + ], + "DistanceRange": [ + 200, + 250 + ], + "UseGravity": false, + "VerticalSpeed": [ + 0 + ], + "BounceCount": [ + 0 + ], + "StrikeDestroy": true + }, + { + "Id": "0003", + "Name": "\u5B50\u5F393", + "Type": 1, + "Prefab": "bullet0003", + "HarmRange": [ + 3 + ], + "RepelRnage": [ + 10 + ], + "DeviationAngleRange": [ + 0 + ], + "SpeedRange": [ + 320, + 340 + ], + "LifeTimeRange": [ + -1 + ], + "DistanceRange": [ + 300, + 400 + ], + "UseGravity": false, + "VerticalSpeed": [ + 0 + ], + "BounceCount": [ + 0 + ], + "StrikeDestroy": true + }, + { + "Id": "0004", + "Name": "\u72D9\u51FB\u67AA\u5B50\u5F39", + "Type": 1, + "Prefab": "bullet0001", + "HarmRange": [ + 20 + ], + "RepelRnage": [ + 200 + ], + "DeviationAngleRange": [ + 0 + ], + "SpeedRange": [ + 600, + 600 + ], + "LifeTimeRange": [ + -1 + ], + "DistanceRange": [ + 600, + 600 + ], + "UseGravity": false, + "VerticalSpeed": [ + 0 + ], + "BounceCount": [ + 0 + ], + "StrikeDestroy": true + }, + { + "Id": "0005", + "Name": "\u69B4\u5F39\u70AE", + "Type": 1, + "Prefab": "bullet0004", + "HarmRange": [ + 30 + ], + "RepelRnage": [ + 0 + ], + "DeviationAngleRange": [ + 0 + ], + "SpeedRange": [ + 180, + 180 + ], + "LifeTimeRange": [ + -1 + ], + "DistanceRange": [ + 270, + 360 + ], + "UseGravity": true, + "VerticalSpeed": [ + 70 + ], + "BounceCount": [ + 999 + ], + "StrikeDestroy": true + }, + { + "Id": "1001", + "Name": "\u6FC0\u51491", + "Type": 2, + "Prefab": "res://prefab/bullet/laser/Laser0001.tscn", + "HarmRange": [ + 5 + ], + "RepelRnage": [ + 0 + ], + "DeviationAngleRange": [ + 0 + ], + "SpeedRange": [ + 300, + 330 + ], + "LifeTimeRange": [ + -1 + ], + "DistanceRange": [ + 600, + 600 + ], + "UseGravity": false, + "VerticalSpeed": null, + "BounceCount": [ + 0 + ], + "StrikeDestroy": false + }, + { + "Id": "2001", + "Name": "\u5200\u4F24\u5BB3", + "Type": 3, + "Prefab": "", + "HarmRange": [ + 25 + ], + "RepelRnage": [ + 150 + ], + "DeviationAngleRange": [ + 0 + ], + "SpeedRange": [ + 350 + ], + "LifeTimeRange": [ + -1 + ], + "DistanceRange": [ + 35 + ], + "UseGravity": false, + "VerticalSpeed": null, + "BounceCount": null, + "StrikeDestroy": false + } +] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/config/Sound.json b/DungeonShooting_Godot/resource/config/Sound.json index 9d7050d..73d3cb1 100644 --- a/DungeonShooting_Godot/resource/config/Sound.json +++ b/DungeonShooting_Godot/resource/config/Sound.json @@ -14,7 +14,7 @@ { "Id": "shooting0003", "Path": "res://resource/sound/sfx/shooting/Shooting0003.ogg", - "Volume": 0.8, + "Volume": 0.7, "Remark": "\u9730\u5F39\u67AA" }, { @@ -48,6 +48,24 @@ "Remark": "\u72D9\u51FB\u67AA" }, { + "Id": "shooting0009", + "Path": "res://resource/sound/sfx/shooting/Shooting0009.ogg", + "Volume": 1, + "Remark": "\u6FC0\u5149\u6B66\u5668" + }, + { + "Id": "shooting0010", + "Path": "res://resource/sound/sfx/shooting/Shooting0010.ogg", + "Volume": 1.2, + "Remark": "\u6FC0\u5149\u6B66\u5668" + }, + { + "Id": "shooting0011", + "Path": "res://resource/sound/sfx/shooting/Shooting0011.ogg", + "Volume": 1.8, + "Remark": "\u69B4\u5F39\u53D1\u5C04\u5668" + }, + { "Id": "reloading0001", "Path": "res://resource/sound/sfx/reloading/Reloading0001.ogg", "Volume": 1, @@ -60,6 +78,12 @@ "Remark": "\u9730\u5F39\u67AA\u5355\u72EC\u88C5\u5F39" }, { + "Id": "reloading0003", + "Path": "res://resource/sound/sfx/reloading/Reloading0003.ogg", + "Volume": 1.2, + "Remark": "\u69B4\u5F39\u53D1\u5C04\u5668\u88C5\u5F39" + }, + { "Id": "reloadBegin0002", "Path": "res://resource/sound/sfx/reloading/Reloading_begin0002.ogg", "Volume": 1, @@ -102,12 +126,36 @@ "Remark": "" }, { + "Id": "reloadBegin0011", + "Path": "res://resource/sound/sfx/reloading/Reloading_begin0011.ogg", + "Volume": 1, + "Remark": "\u6FC0\u5149\u6B66\u5668" + }, + { + "Id": "reloadBegin0012", + "Path": "res://resource/sound/sfx/reloading/Reloading_begin0012.ogg", + "Volume": 1.2, + "Remark": "" + }, + { "Id": "reloadFinish0002", "Path": "res://resource/sound/sfx/reloading/Reloading_finish0002.ogg", "Volume": 1, "Remark": "\u9730\u5F39\u67AA" }, { + "Id": "reloadFinish0003", + "Path": "res://resource/sound/sfx/reloading/Reloading_finish0003.ogg", + "Volume": 1, + "Remark": "\u6FC0\u5149\u6B66\u5668" + }, + { + "Id": "reloadFinish0004", + "Path": "res://resource/sound/sfx/reloading/Reloading_finish0004.ogg", + "Volume": 1.2, + "Remark": "" + }, + { "Id": "beLoaded0001", "Path": "res://resource/sound/sfx/beLoaded/BeLoaded0001.ogg", "Volume": 1, @@ -208,5 +256,29 @@ "Path": "res://resource/sound/sfx/beLoaded/BeLoaded0017.ogg", "Volume": 1, "Remark": "" + }, + { + "Id": "explosion0001", + "Path": "res://resource/sound/sfx/explosion/Explosion0001.ogg", + "Volume": 1.2, + "Remark": "\u7206\u70B8" + }, + { + "Id": "explosion0002", + "Path": "res://resource/sound/sfx/explosion/Explosion0002.ogg", + "Volume": 1.2, + "Remark": "\u7206\u70B8" + }, + { + "Id": "explosion0003", + "Path": "res://resource/sound/sfx/explosion/Explosion0003.ogg", + "Volume": 1.2, + "Remark": "\u7206\u70B8" + }, + { + "Id": "collision0001", + "Path": "res://resource/sound/sfx/collision/Collision0001.ogg", + "Volume": 0.7, + "Remark": "\u78B0\u649E" } ] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/config/Weapon.json b/DungeonShooting_Godot/resource/config/Weapon.json deleted file mode 100644 index 11a4daf..0000000 --- a/DungeonShooting_Godot/resource/config/Weapon.json +++ /dev/null @@ -1,1272 +0,0 @@ -[ - { - "Id": "0001", - "WeaponId": "weapon0001", - "Remark": "\u6B65\u67AA", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": true, - "AmmoCapacity": 30, - "MaxAmmoCapacity": 420, - "StandbyAmmoCapacity": 390, - "ReloadTime": 2.2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 0, - "StartFiringSpeed": 480, - "FinalFiringSpeed": 480, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 5, - "FinalScatteringRange": 45, - "ScatteringRangeAddValue": 3, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.5, - "CameraShake": 2, - "BacklashRange": [ - 2, - 4 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 10, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 4 - ], - "RepelRnage": [ - 20 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 320, - 350 - ], - "BulletDistanceRange": [ - 300, - 400 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0005", - "__BeginReloadSound": "reloadBegin0004", - "BeginReloadSoundDelayTime": 0.2, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0011", - "ReloadFinishSoundAdvanceTime": 0.4, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "0002", - "__AiAttackAttr": "" - }, - { - "Id": "0002", - "WeaponId": "", - "Remark": "\u6B65\u67AA", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 30, - "MaxAmmoCapacity": 420, - "StandbyAmmoCapacity": 390, - "ReloadTime": 2.2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 3 - ], - "TriggerInterval": 3, - "StartFiringSpeed": 480, - "FinalFiringSpeed": 480, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 5, - "FinalScatteringRange": 45, - "ScatteringRangeAddValue": 3, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.5, - "CameraShake": 2, - "BacklashRange": [ - 2, - 4 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 10, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 4 - ], - "RepelRnage": [ - 20 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 320, - 350 - ], - "BulletDistanceRange": [ - 300, - 400 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0005", - "__BeginReloadSound": "reloadBegin0004", - "BeginReloadSoundDelayTime": 0.2, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0011", - "ReloadFinishSoundAdvanceTime": 0.4, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "", - "__AiAttackAttr": "0001" - }, - { - "Id": "0003", - "WeaponId": "weapon0002", - "Remark": "\u9730\u5F39\u67AA", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 7, - "MaxAmmoCapacity": 140, - "StandbyAmmoCapacity": 133, - "ReloadTime": 0.4, - "AloneReload": true, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0.6, - "AloneReloadFinishIntervalTime": 0.6, - "AloneReloadCanShoot": true, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": true, - "AutoManualBeLoaded": true, - "BeLoadedTime": 0.6, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 0, - "StartFiringSpeed": 120, - "FinalFiringSpeed": 120, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 5 - ], - "DelayedTime": 0, - "StartScatteringRange": 12, - "FinalScatteringRange": 30, - "ScatteringRangeAddValue": 20, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.5, - "CameraShake": 4, - "BacklashRange": [ - 5, - 6 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 15, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0002", - "HarmRange": [ - 4 - ], - "RepelRnage": [ - 30 - ], - "BulletDeviationAngleRange": [ - -10, - 10 - ], - "BulletSpeedRange": [ - 280, - 380 - ], - "BulletDistanceRange": [ - 200, - 250 - ], - "ShellId": "shell0002", - "ThrowShellDelayTime": 0.2, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0003", - "__BeginReloadSound": "reloadBegin0002", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "reloading0002", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "reloadFinish0002", - "ReloadFinishSoundAdvanceTime": 0.3, - "__BeLoadedSound": "beLoaded0005", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "0004", - "__AiAttackAttr": "" - }, - { - "Id": "0004", - "WeaponId": "", - "Remark": "\u9730\u5F39\u67AA", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 7, - "MaxAmmoCapacity": 140, - "StandbyAmmoCapacity": 133, - "ReloadTime": 0.4, - "AloneReload": true, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0.6, - "AloneReloadFinishIntervalTime": 0.6, - "AloneReloadCanShoot": true, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": true, - "AutoManualBeLoaded": true, - "BeLoadedTime": 0.6, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 3.5, - "StartFiringSpeed": 120, - "FinalFiringSpeed": 120, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 5 - ], - "DelayedTime": 0, - "StartScatteringRange": 12, - "FinalScatteringRange": 30, - "ScatteringRangeAddValue": 20, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.5, - "CameraShake": 4, - "BacklashRange": [ - 5, - 6 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 15, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0002", - "HarmRange": [ - 4 - ], - "RepelRnage": [ - 30 - ], - "BulletDeviationAngleRange": [ - -10, - 10 - ], - "BulletSpeedRange": [ - 280, - 380 - ], - "BulletDistanceRange": [ - 200, - 250 - ], - "ShellId": "shell0002", - "ThrowShellDelayTime": 0.2, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0003", - "__BeginReloadSound": "reloadBegin0002", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "reloading0002", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "reloadFinish0002", - "ReloadFinishSoundAdvanceTime": 0.3, - "__BeLoadedSound": "beLoaded0005", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "", - "__AiAttackAttr": "0002" - }, - { - "Id": "0005", - "WeaponId": "weapon0003", - "Remark": "\u624B\u67AA", - "Weight": 20, - "WeightType": 1, - "ContinuousShoot": false, - "AmmoCapacity": 12, - "MaxAmmoCapacity": 180, - "StandbyAmmoCapacity": 168, - "ReloadTime": 1.5, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0.05, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 0, - "StartFiringSpeed": 460, - "FinalFiringSpeed": 460, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 5, - "FinalScatteringRange": 25, - "ScatteringRangeAddValue": 4, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.5, - "CameraShake": 4, - "BacklashRange": [ - 3, - 5 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 20, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 4 - ], - "RepelRnage": [ - 20 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 320, - 350 - ], - "BulletDistanceRange": [ - 250, - 300 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0004", - "__BeginReloadSound": "reloading0001", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0015", - "ReloadFinishSoundAdvanceTime": 0.43, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "0006", - "__AiAttackAttr": "" - }, - { - "Id": "0006", - "WeaponId": "", - "Remark": "\u624B\u67AA", - "Weight": 20, - "WeightType": 1, - "ContinuousShoot": false, - "AmmoCapacity": 12, - "MaxAmmoCapacity": 180, - "StandbyAmmoCapacity": 168, - "ReloadTime": 1.5, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0.05, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 2, - "StartFiringSpeed": 300, - "FinalFiringSpeed": 300, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 5, - "FinalScatteringRange": 25, - "ScatteringRangeAddValue": 4, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.5, - "CameraShake": 4, - "BacklashRange": [ - 3, - 5 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 20, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 4 - ], - "RepelRnage": [ - 20 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 320, - 350 - ], - "BulletDistanceRange": [ - 250, - 300 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0004", - "__BeginReloadSound": "reloading0001", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0015", - "ReloadFinishSoundAdvanceTime": 0.43, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "", - "__AiAttackAttr": "0003" - }, - { - "Id": "0007", - "WeaponId": "weapon0004", - "Remark": "\u5200", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 180, - "MaxAmmoCapacity": 180, - "StandbyAmmoCapacity": 180, - "ReloadTime": 2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": true, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 0, - "StartFiringSpeed": 180, - "FinalFiringSpeed": 180, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 0, - "FinalScatteringRange": 0, - "ScatteringRangeAddValue": 0, - "ScatteringRangeBackSpeed": 0, - "ScatteringRangeBackDelayTime": 0, - "CameraShake": 7, - "BacklashRange": [ - -8 - ], - "BacklashRegressionSpeed": 24, - "UpliftAngle": -95, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 25 - ], - "RepelRnage": [ - 150 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 350 - ], - "BulletDistanceRange": [ - 35 - ], - "ShellId": "", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "", - "__BeginReloadSound": "", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "", - "ReloadFinishSoundAdvanceTime": 0, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "0008", - "__AiAttackAttr": "" - }, - { - "Id": "0008", - "WeaponId": "", - "Remark": "\u5200", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 180, - "MaxAmmoCapacity": 180, - "StandbyAmmoCapacity": 180, - "ReloadTime": 2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": true, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 3, - "StartFiringSpeed": 180, - "FinalFiringSpeed": 180, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 0, - "FinalScatteringRange": 0, - "ScatteringRangeAddValue": 0, - "ScatteringRangeBackSpeed": 0, - "ScatteringRangeBackDelayTime": 0, - "CameraShake": 7, - "BacklashRange": [ - -8 - ], - "BacklashRegressionSpeed": 24, - "UpliftAngle": -95, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 25 - ], - "RepelRnage": [ - 150 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 350 - ], - "BulletDistanceRange": [ - 35 - ], - "ShellId": "", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "", - "__BeginReloadSound": "", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "", - "ReloadFinishSoundAdvanceTime": 0, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "", - "__AiAttackAttr": "0004" - }, - { - "Id": "0009", - "WeaponId": "weapon0005", - "Remark": "\u72D9\u51FB\u67AA", - "Weight": 50, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 10, - "MaxAmmoCapacity": 80, - "StandbyAmmoCapacity": 70, - "ReloadTime": 3, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": true, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0.9, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 0, - "StartFiringSpeed": 150, - "FinalFiringSpeed": 150, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 3, - "FinalScatteringRange": 60, - "ScatteringRangeAddValue": 40, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.8, - "CameraShake": 5, - "BacklashRange": [ - 5, - 7 - ], - "BacklashRegressionSpeed": 20, - "UpliftAngle": 15, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 30 - ], - "RepelRnage": [ - 250 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 600, - 620 - ], - "BulletDistanceRange": [ - 700, - 900 - ], - "ShellId": "shell0003", - "ThrowShellDelayTime": 0.2, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0008", - "__BeginReloadSound": "reloadBegin0009", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0007", - "ReloadFinishSoundAdvanceTime": 1, - "__BeLoadedSound": "beLoaded0007", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "0010", - "__AiAttackAttr": "" - }, - { - "Id": "0010", - "WeaponId": "", - "Remark": "\u72D9\u51FB\u67AA", - "Weight": 50, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 10, - "MaxAmmoCapacity": 80, - "StandbyAmmoCapacity": 70, - "ReloadTime": 3, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": true, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0.9, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 5, - "StartFiringSpeed": 150, - "FinalFiringSpeed": 150, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 3, - "FinalScatteringRange": 60, - "ScatteringRangeAddValue": 40, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.8, - "CameraShake": 5, - "BacklashRange": [ - 5, - 7 - ], - "BacklashRegressionSpeed": 20, - "UpliftAngle": 15, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0001", - "HarmRange": [ - 30 - ], - "RepelRnage": [ - 250 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 600, - 620 - ], - "BulletDistanceRange": [ - 700, - 900 - ], - "ShellId": "shell0003", - "ThrowShellDelayTime": 0.2, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0008", - "__BeginReloadSound": "reloadBegin0009", - "BeginReloadSoundDelayTime": 0, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0007", - "ReloadFinishSoundAdvanceTime": 1, - "__BeLoadedSound": "beLoaded0007", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "", - "__AiAttackAttr": "0005" - }, - { - "Id": "0011", - "WeaponId": "weapon0006", - "Remark": "\u51B2\u950B\u67AA", - "Weight": 30, - "WeightType": 2, - "ContinuousShoot": true, - "AmmoCapacity": 20, - "MaxAmmoCapacity": 600, - "StandbyAmmoCapacity": 580, - "ReloadTime": 2.2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 0, - "StartFiringSpeed": 700, - "FinalFiringSpeed": 700, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 3, - "FinalScatteringRange": 30, - "ScatteringRangeAddValue": 2, - "ScatteringRangeBackSpeed": 40, - "ScatteringRangeBackDelayTime": 0.3, - "CameraShake": 2, - "BacklashRange": [ - 1, - 2 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 5, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0002", - "HarmRange": [ - 3 - ], - "RepelRnage": [ - 10 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 320, - 340 - ], - "BulletDistanceRange": [ - 300, - 400 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0002", - "__BeginReloadSound": "reloadBegin0005", - "BeginReloadSoundDelayTime": 0.2, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0016", - "ReloadFinishSoundAdvanceTime": 0.5, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "0012", - "__AiAttackAttr": "" - }, - { - "Id": "0012", - "WeaponId": "", - "Remark": "\u51B2\u950B\u67AA", - "Weight": 30, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 20, - "MaxAmmoCapacity": 600, - "StandbyAmmoCapacity": 580, - "ReloadTime": 2.2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 5 - ], - "TriggerInterval": 3.5, - "StartFiringSpeed": 700, - "FinalFiringSpeed": 700, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 3, - "FinalScatteringRange": 30, - "ScatteringRangeAddValue": 2, - "ScatteringRangeBackSpeed": 30, - "ScatteringRangeBackDelayTime": 0.3, - "CameraShake": 2, - "BacklashRange": [ - 1, - 2 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 5, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0002", - "HarmRange": [ - 3 - ], - "RepelRnage": [ - 10 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 320, - 340 - ], - "BulletDistanceRange": [ - 300, - 400 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0002", - "__BeginReloadSound": "reloadBegin0005", - "BeginReloadSoundDelayTime": 0.2, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0016", - "ReloadFinishSoundAdvanceTime": 0.5, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "", - "__AiAttackAttr": "0004" - }, - { - "Id": "0013", - "WeaponId": "weapon0007", - "Remark": "\u6C64\u59C6\u900A\u51B2\u950B\u67AA", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": true, - "AmmoCapacity": 60, - "MaxAmmoCapacity": 600, - "StandbyAmmoCapacity": 540, - "ReloadTime": 2.2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 1 - ], - "TriggerInterval": 0, - "StartFiringSpeed": 700, - "FinalFiringSpeed": 700, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 6, - "FinalScatteringRange": 60, - "ScatteringRangeAddValue": 3, - "ScatteringRangeBackSpeed": 50, - "ScatteringRangeBackDelayTime": 0.3, - "CameraShake": 2, - "BacklashRange": [ - 1, - 2 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 5, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0003", - "HarmRange": [ - 3 - ], - "RepelRnage": [ - 15 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 300, - 330 - ], - "BulletDistanceRange": [ - 270, - 360 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0007", - "__BeginReloadSound": "reloadBegin0006", - "BeginReloadSoundDelayTime": 0.2, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0017", - "ReloadFinishSoundAdvanceTime": 0.65, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "0014", - "__AiAttackAttr": "" - }, - { - "Id": "0014", - "WeaponId": "", - "Remark": "\u6C64\u59C6\u900A\u51B2\u950B\u67AA", - "Weight": 40, - "WeightType": 2, - "ContinuousShoot": false, - "AmmoCapacity": 60, - "MaxAmmoCapacity": 600, - "StandbyAmmoCapacity": 540, - "ReloadTime": 2.2, - "AloneReload": false, - "AloneReloadCount": 1, - "AloneReloadBeginIntervalTime": 0, - "AloneReloadFinishIntervalTime": 0, - "AloneReloadCanShoot": false, - "LooseShoot": false, - "MinChargeTime": 0, - "ManualBeLoaded": false, - "AutoManualBeLoaded": false, - "BeLoadedTime": 0, - "ContinuousCountRange": [ - 10 - ], - "TriggerInterval": 5, - "StartFiringSpeed": 200, - "FinalFiringSpeed": 200, - "FiringSpeedAddSpeed": 0, - "FiringSpeedBackSpeed": 0, - "FireBulletCountRange": [ - 1 - ], - "DelayedTime": 0, - "StartScatteringRange": 10, - "FinalScatteringRange": 30, - "ScatteringRangeAddValue": 3, - "ScatteringRangeBackSpeed": 50, - "ScatteringRangeBackDelayTime": 0.3, - "CameraShake": 2, - "BacklashRange": [ - 1, - 2 - ], - "BacklashRegressionSpeed": 35, - "UpliftAngle": 5, - "DefaultAngle": 0, - "UpliftAngleRestore": 1, - "BulletId": "bullet0003", - "HarmRange": [ - 3 - ], - "RepelRnage": [ - 15 - ], - "BulletDeviationAngleRange": [ - 0 - ], - "BulletSpeedRange": [ - 300, - 330 - ], - "BulletDistanceRange": [ - 270, - 360 - ], - "ShellId": "shell0001", - "ThrowShellDelayTime": 0, - "ThrowCollisionSize": { - "X": 20, - "Y": 15 - }, - "CanMeleeAttack": true, - "MeleeAttackHarmRange": [ - 10 - ], - "MeleeAttackRepelRnage": [ - 100 - ], - "__ShootSound": "shooting0007", - "__BeginReloadSound": "reloadBegin0006", - "BeginReloadSoundDelayTime": 0.2, - "__ReloadSound": "", - "ReloadSoundDelayTime": 0, - "__ReloadFinishSound": "beLoaded0017", - "ReloadFinishSoundAdvanceTime": 0.65, - "__BeLoadedSound": "", - "BeLoadedSoundDelayTime": 0, - "__OtherSoundMap": null, - "__AiUseAttribute": "", - "__AiAttackAttr": "0006" - } -] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/config/WeaponBase.json b/DungeonShooting_Godot/resource/config/WeaponBase.json new file mode 100644 index 0000000..4e75043 --- /dev/null +++ b/DungeonShooting_Godot/resource/config/WeaponBase.json @@ -0,0 +1,1368 @@ +[ + { + "Id": "0001", + "__Activity": "weapon0001", + "Remark": "\u6B65\u67AA", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": true, + "AmmoCapacity": 30, + "MaxAmmoCapacity": 420, + "StandbyAmmoCapacity": 390, + "ReloadTime": 2.2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 480, + "FinalFiringSpeed": 480, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 5, + "FinalScatteringRange": 45, + "ScatteringRangeAddValue": 3, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 2, + "BacklashRange": [ + 2, + 4 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 10, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0001", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0005", + "__BeginReloadSound": "reloadBegin0004", + "BeginReloadSoundDelayTime": 0.2, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0011", + "ReloadFinishSoundAdvanceTime": 0.4, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0002", + "__AiAttackAttr": "" + }, + { + "Id": "0002", + "__Activity": "", + "Remark": "\u6B65\u67AA", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 30, + "MaxAmmoCapacity": 420, + "StandbyAmmoCapacity": 390, + "ReloadTime": 2.2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 3 + ], + "TriggerInterval": 3, + "StartFiringSpeed": 480, + "FinalFiringSpeed": 480, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 5, + "FinalScatteringRange": 45, + "ScatteringRangeAddValue": 3, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 2, + "BacklashRange": [ + 2, + 4 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 10, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0001", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0005", + "__BeginReloadSound": "reloadBegin0004", + "BeginReloadSoundDelayTime": 0.2, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0011", + "ReloadFinishSoundAdvanceTime": 0.4, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0001" + }, + { + "Id": "0003", + "__Activity": "weapon0002", + "Remark": "\u9730\u5F39\u67AA", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 7, + "MaxAmmoCapacity": 140, + "StandbyAmmoCapacity": 133, + "ReloadTime": 0.4, + "AloneReload": true, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0.6, + "AloneReloadFinishIntervalTime": 0.6, + "AloneReloadCanShoot": true, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": true, + "AutoManualBeLoaded": true, + "BeLoadedTime": 0.6, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 120, + "FinalFiringSpeed": 120, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 5 + ], + "DelayedTime": 0, + "StartScatteringRange": 12, + "FinalScatteringRange": 30, + "ScatteringRangeAddValue": 20, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 4, + "BacklashRange": [ + 5, + 6 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 15, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0002", + "__Shell": "shell0002", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0.2, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0003", + "__BeginReloadSound": "reloadBegin0002", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "reloading0002", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "reloadFinish0002", + "ReloadFinishSoundAdvanceTime": 0.3, + "__BeLoadedSound": "beLoaded0005", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0004", + "__AiAttackAttr": "" + }, + { + "Id": "0004", + "__Activity": "", + "Remark": "\u9730\u5F39\u67AA", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 7, + "MaxAmmoCapacity": 140, + "StandbyAmmoCapacity": 133, + "ReloadTime": 0.4, + "AloneReload": true, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0.6, + "AloneReloadFinishIntervalTime": 0.6, + "AloneReloadCanShoot": true, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": true, + "AutoManualBeLoaded": true, + "BeLoadedTime": 0.6, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 3.5, + "StartFiringSpeed": 120, + "FinalFiringSpeed": 120, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 5 + ], + "DelayedTime": 0, + "StartScatteringRange": 12, + "FinalScatteringRange": 30, + "ScatteringRangeAddValue": 20, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 4, + "BacklashRange": [ + 5, + 6 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 15, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0002", + "__Shell": "shell0002", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0.2, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0003", + "__BeginReloadSound": "reloadBegin0002", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "reloading0002", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "reloadFinish0002", + "ReloadFinishSoundAdvanceTime": 0.3, + "__BeLoadedSound": "beLoaded0005", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0002" + }, + { + "Id": "0005", + "__Activity": "weapon0003", + "Remark": "\u624B\u67AA", + "Weight": 20, + "WeightType": 1, + "ContinuousShoot": false, + "AmmoCapacity": 12, + "MaxAmmoCapacity": 180, + "StandbyAmmoCapacity": 168, + "ReloadTime": 1.5, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0.05, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 460, + "FinalFiringSpeed": 460, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 5, + "FinalScatteringRange": 25, + "ScatteringRangeAddValue": 4, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 4, + "BacklashRange": [ + 3, + 5 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 20, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0001", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0004", + "__BeginReloadSound": "reloading0001", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0015", + "ReloadFinishSoundAdvanceTime": 0.43, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0006", + "__AiAttackAttr": "" + }, + { + "Id": "0006", + "__Activity": "", + "Remark": "\u624B\u67AA", + "Weight": 20, + "WeightType": 1, + "ContinuousShoot": false, + "AmmoCapacity": 12, + "MaxAmmoCapacity": 180, + "StandbyAmmoCapacity": 168, + "ReloadTime": 1.5, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0.05, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 1.3, + "StartFiringSpeed": 300, + "FinalFiringSpeed": 300, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 5, + "FinalScatteringRange": 25, + "ScatteringRangeAddValue": 4, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 4, + "BacklashRange": [ + 3, + 5 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 20, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0001", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0004", + "__BeginReloadSound": "reloading0001", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0015", + "ReloadFinishSoundAdvanceTime": 0.43, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0003" + }, + { + "Id": "0007", + "__Activity": "weapon0004", + "Remark": "\u5200", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 180, + "MaxAmmoCapacity": 180, + "StandbyAmmoCapacity": 180, + "ReloadTime": 2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": true, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 180, + "FinalFiringSpeed": 180, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 0, + "FinalScatteringRange": 0, + "ScatteringRangeAddValue": 0, + "ScatteringRangeBackSpeed": 0, + "ScatteringRangeBackDelayTime": 0, + "CameraShake": 7, + "BacklashRange": [ + -8 + ], + "BacklashRegressionSpeed": 24, + "UpliftAngle": -95, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "", + "__Bullet": "2001", + "__Shell": "", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "", + "__BeginReloadSound": "", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "", + "ReloadFinishSoundAdvanceTime": 0, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0008", + "__AiAttackAttr": "" + }, + { + "Id": "0008", + "__Activity": "", + "Remark": "\u5200", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 180, + "MaxAmmoCapacity": 180, + "StandbyAmmoCapacity": 180, + "ReloadTime": 2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": true, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 3, + "StartFiringSpeed": 180, + "FinalFiringSpeed": 180, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 0, + "FinalScatteringRange": 0, + "ScatteringRangeAddValue": 0, + "ScatteringRangeBackSpeed": 0, + "ScatteringRangeBackDelayTime": 0, + "CameraShake": 7, + "BacklashRange": [ + -8 + ], + "BacklashRegressionSpeed": 24, + "UpliftAngle": -95, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "", + "__Bullet": "2001", + "__Shell": "", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "", + "__BeginReloadSound": "", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "", + "ReloadFinishSoundAdvanceTime": 0, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0004" + }, + { + "Id": "0009", + "__Activity": "weapon0005", + "Remark": "\u72D9\u51FB\u67AA", + "Weight": 50, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 10, + "MaxAmmoCapacity": 80, + "StandbyAmmoCapacity": 70, + "ReloadTime": 3, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": true, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0.9, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 150, + "FinalFiringSpeed": 150, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 3, + "FinalScatteringRange": 60, + "ScatteringRangeAddValue": 40, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.8, + "CameraShake": 5, + "BacklashRange": [ + 5, + 7 + ], + "BacklashRegressionSpeed": 20, + "UpliftAngle": 15, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0004", + "__Shell": "shell0003", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0.2, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0008", + "__BeginReloadSound": "reloadBegin0009", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0007", + "ReloadFinishSoundAdvanceTime": 1, + "__BeLoadedSound": "beLoaded0007", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0010", + "__AiAttackAttr": "" + }, + { + "Id": "0010", + "__Activity": "", + "Remark": "\u72D9\u51FB\u67AA", + "Weight": 50, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 10, + "MaxAmmoCapacity": 80, + "StandbyAmmoCapacity": 70, + "ReloadTime": 3, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": true, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0.9, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 5, + "StartFiringSpeed": 150, + "FinalFiringSpeed": 150, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 3, + "FinalScatteringRange": 60, + "ScatteringRangeAddValue": 40, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.8, + "CameraShake": 5, + "BacklashRange": [ + 5, + 7 + ], + "BacklashRegressionSpeed": 20, + "UpliftAngle": 15, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0004", + "__Shell": "shell0003", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0.2, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0008", + "__BeginReloadSound": "reloadBegin0009", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0007", + "ReloadFinishSoundAdvanceTime": 1, + "__BeLoadedSound": "beLoaded0007", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0005" + }, + { + "Id": "0011", + "__Activity": "weapon0006", + "Remark": "\u51B2\u950B\u67AA", + "Weight": 30, + "WeightType": 2, + "ContinuousShoot": true, + "AmmoCapacity": 20, + "MaxAmmoCapacity": 600, + "StandbyAmmoCapacity": 580, + "ReloadTime": 2.2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 700, + "FinalFiringSpeed": 700, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 3, + "FinalScatteringRange": 30, + "ScatteringRangeAddValue": 2, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.3, + "CameraShake": 2, + "BacklashRange": [ + 1, + 2 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 5, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0002", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0002", + "__BeginReloadSound": "reloadBegin0005", + "BeginReloadSoundDelayTime": 0.2, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0016", + "ReloadFinishSoundAdvanceTime": 0.5, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0012", + "__AiAttackAttr": "" + }, + { + "Id": "0012", + "__Activity": "", + "Remark": "\u51B2\u950B\u67AA", + "Weight": 30, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 20, + "MaxAmmoCapacity": 600, + "StandbyAmmoCapacity": 580, + "ReloadTime": 2.2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 5 + ], + "TriggerInterval": 3.5, + "StartFiringSpeed": 700, + "FinalFiringSpeed": 700, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 3, + "FinalScatteringRange": 30, + "ScatteringRangeAddValue": 2, + "ScatteringRangeBackSpeed": 30, + "ScatteringRangeBackDelayTime": 0.3, + "CameraShake": 2, + "BacklashRange": [ + 1, + 2 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 5, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0002", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0002", + "__BeginReloadSound": "reloadBegin0005", + "BeginReloadSoundDelayTime": 0.2, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0016", + "ReloadFinishSoundAdvanceTime": 0.5, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0004" + }, + { + "Id": "0013", + "__Activity": "weapon0007", + "Remark": "\u6C64\u59C6\u900A\u51B2\u950B\u67AA", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": true, + "AmmoCapacity": 60, + "MaxAmmoCapacity": 600, + "StandbyAmmoCapacity": 540, + "ReloadTime": 2.2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 700, + "FinalFiringSpeed": 700, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 6, + "FinalScatteringRange": 60, + "ScatteringRangeAddValue": 3, + "ScatteringRangeBackSpeed": 50, + "ScatteringRangeBackDelayTime": 0.3, + "CameraShake": 2, + "BacklashRange": [ + 1, + 2 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 5, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0003", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0007", + "__BeginReloadSound": "reloadBegin0006", + "BeginReloadSoundDelayTime": 0.2, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0017", + "ReloadFinishSoundAdvanceTime": 0.65, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0014", + "__AiAttackAttr": "" + }, + { + "Id": "0014", + "__Activity": "", + "Remark": "\u6C64\u59C6\u900A\u51B2\u950B\u67AA", + "Weight": 40, + "WeightType": 2, + "ContinuousShoot": false, + "AmmoCapacity": 60, + "MaxAmmoCapacity": 600, + "StandbyAmmoCapacity": 540, + "ReloadTime": 2.2, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 10 + ], + "TriggerInterval": 4.5, + "StartFiringSpeed": 200, + "FinalFiringSpeed": 200, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 10, + "FinalScatteringRange": 30, + "ScatteringRangeAddValue": 3, + "ScatteringRangeBackSpeed": 50, + "ScatteringRangeBackDelayTime": 0.3, + "CameraShake": 2, + "BacklashRange": [ + 1, + 2 + ], + "BacklashRegressionSpeed": 35, + "UpliftAngle": 5, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0003", + "__Shell": "shell0001", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0007", + "__BeginReloadSound": "reloadBegin0006", + "BeginReloadSoundDelayTime": 0.2, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "beLoaded0017", + "ReloadFinishSoundAdvanceTime": 0.65, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0006" + }, + { + "Id": "0015", + "__Activity": "weapon0008", + "Remark": "\u6FC0\u5149\u624B\u67AA", + "Weight": 40, + "WeightType": 1, + "ContinuousShoot": false, + "AmmoCapacity": 10, + "MaxAmmoCapacity": 240, + "StandbyAmmoCapacity": 120, + "ReloadTime": 1.8, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 300, + "FinalFiringSpeed": 300, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 0, + "FinalScatteringRange": 20, + "ScatteringRangeAddValue": 4, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 2, + "BacklashRange": [ + 2, + 3 + ], + "BacklashRegressionSpeed": 25, + "UpliftAngle": 13, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire2.tscn", + "__Bullet": "1001", + "__Shell": "", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0010", + "__BeginReloadSound": "reloadBegin0011", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "reloadFinish0003", + "ReloadFinishSoundAdvanceTime": 0.8, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0016", + "__AiAttackAttr": "" + }, + { + "Id": "0016", + "__Activity": "", + "Remark": "\u6FC0\u5149\u624B\u67AA", + "Weight": 40, + "WeightType": 1, + "ContinuousShoot": false, + "AmmoCapacity": 10, + "MaxAmmoCapacity": 240, + "StandbyAmmoCapacity": 120, + "ReloadTime": 1.8, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 4, + "StartFiringSpeed": 300, + "FinalFiringSpeed": 300, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 0, + "FinalScatteringRange": 20, + "ScatteringRangeAddValue": 4, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 2, + "BacklashRange": [ + 2, + 3 + ], + "BacklashRegressionSpeed": 25, + "UpliftAngle": 13, + "DefaultAngle": 0, + "UpliftAngleRestore": 1, + "FireEffect": "res://prefab/effect/weapon/ShotFire2.tscn", + "__Bullet": "1001", + "__Shell": "", + "ReloadThrowShell": false, + "ThrowShellDelayTime": 0, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0010", + "__BeginReloadSound": "reloadBegin0011", + "BeginReloadSoundDelayTime": 0, + "__ReloadSound": "", + "ReloadSoundDelayTime": 0, + "__ReloadFinishSound": "reloadFinish0003", + "ReloadFinishSoundAdvanceTime": 0.8, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0007" + }, + { + "Id": "0017", + "__Activity": "weapon0009", + "Remark": "\u69B4\u5F39\u53D1\u5C04\u5668", + "Weight": 40, + "WeightType": 1, + "ContinuousShoot": false, + "AmmoCapacity": 1, + "MaxAmmoCapacity": 50, + "StandbyAmmoCapacity": 25, + "ReloadTime": 1.5, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 0, + "StartFiringSpeed": 60, + "FinalFiringSpeed": 60, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 3, + "FinalScatteringRange": 8, + "ScatteringRangeAddValue": 5, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 2, + "BacklashRange": [ + 2, + 3 + ], + "BacklashRegressionSpeed": 20, + "UpliftAngle": 16, + "DefaultAngle": 0, + "UpliftAngleRestore": 3, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0005", + "__Shell": "shell0004", + "ReloadThrowShell": true, + "ThrowShellDelayTime": 0.46, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0011", + "__BeginReloadSound": "reloadBegin0012", + "BeginReloadSoundDelayTime": 0.24, + "__ReloadSound": "reloading0003", + "ReloadSoundDelayTime": 0.8, + "__ReloadFinishSound": "reloadFinish0004", + "ReloadFinishSoundAdvanceTime": 0.26, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "0018", + "__AiAttackAttr": "" + }, + { + "Id": "0018", + "__Activity": "", + "Remark": "\u69B4\u5F39\u53D1\u5C04\u5668", + "Weight": 40, + "WeightType": 1, + "ContinuousShoot": false, + "AmmoCapacity": 1, + "MaxAmmoCapacity": 50, + "StandbyAmmoCapacity": 25, + "ReloadTime": 1.5, + "AloneReload": false, + "AloneReloadCount": 1, + "AloneReloadBeginIntervalTime": 0, + "AloneReloadFinishIntervalTime": 0, + "AloneReloadCanShoot": false, + "LooseShoot": false, + "MinChargeTime": 0, + "ManualBeLoaded": false, + "AutoManualBeLoaded": false, + "BeLoadedTime": 0, + "ContinuousCountRange": [ + 1 + ], + "TriggerInterval": 5, + "StartFiringSpeed": 60, + "FinalFiringSpeed": 60, + "FiringSpeedAddSpeed": 0, + "FiringSpeedBackSpeed": 0, + "FireBulletCountRange": [ + 1 + ], + "DelayedTime": 0, + "StartScatteringRange": 3, + "FinalScatteringRange": 8, + "ScatteringRangeAddValue": 5, + "ScatteringRangeBackSpeed": 40, + "ScatteringRangeBackDelayTime": 0.5, + "CameraShake": 2, + "BacklashRange": [ + 2, + 3 + ], + "BacklashRegressionSpeed": 20, + "UpliftAngle": 16, + "DefaultAngle": 0, + "UpliftAngleRestore": 3, + "FireEffect": "res://prefab/effect/weapon/ShotFire.tscn", + "__Bullet": "0005", + "__Shell": "shell0004", + "ReloadThrowShell": true, + "ThrowShellDelayTime": 0.46, + "ThrowCollisionSize": { + "X": 20, + "Y": 15 + }, + "CanMeleeAttack": true, + "MeleeAttackHarmRange": [ + 10 + ], + "MeleeAttackRepelRnage": [ + 100 + ], + "__ShootSound": "shooting0011", + "__BeginReloadSound": "reloadBegin0012", + "BeginReloadSoundDelayTime": 0.24, + "__ReloadSound": "reloading0003", + "ReloadSoundDelayTime": 0.8, + "__ReloadFinishSound": "reloadFinish0004", + "ReloadFinishSoundAdvanceTime": 0.26, + "__BeLoadedSound": "", + "BeLoadedSoundDelayTime": 0, + "__OtherSoundMap": null, + "__AiUseAttribute": "", + "__AiAttackAttr": "0008" + } +] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/GroupConfig.json b/DungeonShooting_Godot/resource/map/tileMaps/GroupConfig.json index d9e69c2..d515189 100644 --- a/DungeonShooting_Godot/resource/map/tileMaps/GroupConfig.json +++ b/DungeonShooting_Godot/resource/map/tileMaps/GroupConfig.json @@ -13,6 +13,14 @@ { "ErrorType": 0, "Path": "resource/map/tileMaps/TestGroup1/battle/Battle3" + }, + { + "ErrorType": 0, + "Path": "resource/map/tileMaps/TestGroup1/battle/Battle4" + }, + { + "ErrorType": 0, + "Path": "resource/map/tileMaps/TestGroup1/battle/Battle5" } ], "InletList": [ diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preinstall.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preinstall.json new file mode 100644 index 0000000..3ca0692 --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preinstall.json @@ -0,0 +1 @@ +[{"Name":"Test1","Weight":100,"Remark":"","WaveList":[[{"Position":{"X":-138,"Y":82},"Size":{"X":36,"Y":48},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":null},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":60,"Y":145},"Size":{"X":40,"Y":51},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0008","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":-66,"Y":-6},"Size":{"X":51,"Y":49},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0008","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":-2,"Y":-54},"Size":{"X":75,"Y":37},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0008","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]}],[{"Position":{"X":-182,"Y":105},"Size":{"X":59,"Y":26},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0005","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":-162,"Y":27},"Size":{"X":42,"Y":37},"SpecialMarkType":0,"DelayTime":0.5,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0003","CurrAmmon":"12","ResidueAmmo":"12"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":48,"Y":21},"Size":{"X":16,"Y":91},"SpecialMarkType":0,"DelayTime":1,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0005","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":-52,"Y":155},"Size":{"X":106,"Y":41},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0008","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]}]]}] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preview.png b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preview.png new file mode 100644 index 0000000..952d28b --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preview.png Binary files differ diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preview.png.import b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preview.png.import new file mode 100644 index 0000000..9e4ef59 --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/Preview.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://x2ytkmtkn53s" +path="res://.godot/imported/Preview.png-8f3c76ec034bcd9156b51bf3b67fca71.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/map/tileMaps/TestGroup1/battle/Battle4/Preview.png" +dest_files=["res://.godot/imported/Preview.png-8f3c76ec034bcd9156b51bf3b67fca71.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/RoomInfo.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/RoomInfo.json new file mode 100644 index 0000000..a698207 --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/RoomInfo.json @@ -0,0 +1 @@ +{"Position":{"X":-16,"Y":-15},"Size":{"X":26,"Y":31},"DoorAreaInfos":[{"Direction":0,"Start":128,"End":272},{"Direction":2,"Start":144,"End":304},{"Direction":1,"Start":208,"End":368},{"Direction":3,"Start":80,"End":192}],"GroupName":"TestGroup1","RoomType":0,"RoomName":"Battle4","Weight":100,"Remark":""} \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/TileInfo.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/TileInfo.json new file mode 100644 index 0000000..859f5fd --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle4/TileInfo.json @@ -0,0 +1 @@ +{"NavigationList":[{"Type":0,"Points":[-152,-216,-56,-216,-56,-88,136,-88,136,48,104,48,104,208,56,208,56,240,-88,240,-88,192,-136,192,-136,144,-232,144,-232,-8,-120,-8,-120,-48,-152,-48]},{"Type":1,"Points":[-24,-16,24,-16,24,88,8,88,8,104,-8,104,-8,120,-88,120,-88,32,-40,32,-40,48,-24,48]}],"Floor":[-2,-2,0,0,8,-1,-2,0,0,8,0,-2,0,0,8,1,-2,0,0,8,2,-2,0,0,8,3,-2,0,0,8,4,-2,0,0,8,5,-2,0,0,8,6,-2,0,0,8,7,-2,0,0,8,-8,-6,0,0,8,-8,-5,0,0,8,-8,-4,0,0,8,-8,-3,0,0,8,-8,-2,0,0,8,-8,-1,0,0,8,-8,0,0,0,8,-8,1,0,0,8,-8,2,0,0,8,-7,-6,0,0,8,-7,-5,0,0,8,-7,-4,0,0,8,-7,-3,0,0,8,-7,-2,0,0,8,-7,-1,0,0,8,-7,0,0,0,8,-7,1,0,0,8,-7,2,0,0,8,-6,-6,0,0,8,-6,-5,0,0,8,-6,-4,0,0,8,-6,-3,0,0,8,-6,-2,0,0,8,-6,-1,0,0,8,-6,0,0,0,8,-6,1,0,0,8,-6,2,0,0,8,-5,-6,0,0,8,-5,-5,0,0,8,-5,-4,0,0,8,-5,-3,0,0,8,-5,-2,0,0,8,-5,-1,0,0,8,-5,0,0,0,8,-5,1,0,0,8,-4,-6,0,0,8,-4,-5,0,0,8,-4,-4,0,0,8,-4,-3,0,0,8,-4,-2,0,0,8,-4,-1,0,0,8,-4,0,0,0,8,-4,1,0,0,8,-3,-6,0,0,8,-3,-5,0,0,8,-3,-4,0,0,8,-3,-3,0,0,8,-3,-2,0,0,8,-3,-1,0,0,8,-3,0,0,0,8,-3,1,0,0,8,-2,-6,0,0,8,-2,-5,0,0,8,-2,-4,0,0,8,-2,-3,0,0,8,-2,-1,0,0,8,-2,0,0,0,8,-2,1,0,0,8,-2,2,0,0,8,-1,-6,0,0,8,-1,-5,0,0,8,-1,-4,0,0,8,-1,-3,0,0,8,0,-6,0,0,8,0,-5,0,0,8,0,-4,0,0,8,0,-3,0,0,8,1,-6,0,0,8,1,-5,0,0,8,1,-4,0,0,8,1,-3,0,0,8,1,-1,0,0,8,1,0,0,0,8,1,1,0,0,8,1,2,0,0,8,2,-6,0,0,8,2,-5,0,0,8,2,-4,0,0,8,2,-3,0,0,8,2,-1,0,0,8,2,0,0,0,8,2,1,0,0,8,2,2,0,0,8,3,-6,0,0,8,3,-5,0,0,8,3,-4,0,0,8,3,-3,0,0,8,3,-1,0,0,8,3,0,0,0,8,3,1,0,0,8,3,2,0,0,8,4,-6,0,0,8,4,-5,0,0,8,4,-4,0,0,8,4,-3,0,0,8,4,-1,0,0,8,4,0,0,0,8,4,1,0,0,8,4,2,0,0,8,5,-6,0,0,8,5,-5,0,0,8,5,-4,0,0,8,5,-3,0,0,8,5,-1,0,0,8,5,0,0,0,8,5,1,0,0,8,5,2,0,0,8,6,-6,0,0,8,6,-5,0,0,8,6,-4,0,0,8,6,-3,0,0,8,6,-1,0,0,8,6,0,0,0,8,6,1,0,0,8,6,2,0,0,8,7,-6,0,0,8,7,-5,0,0,8,7,-4,0,0,8,7,-3,0,0,8,7,-1,0,0,8,7,0,0,0,8,7,1,0,0,8,7,2,0,0,8,8,-6,0,0,8,8,-5,0,0,8,8,-4,0,0,8,8,-3,0,0,8,8,-2,0,0,8,8,-1,0,0,8,8,0,0,0,8,8,1,0,0,8,8,2,0,0,8,0,5,0,0,8,0,6,0,0,8,0,7,0,0,8,0,8,0,0,8,1,3,0,0,8,1,4,0,0,8,1,5,0,0,8,1,6,0,0,8,1,7,0,0,8,1,8,0,0,8,2,3,0,0,8,2,4,0,0,8,2,5,0,0,8,2,6,0,0,8,2,7,0,0,8,2,8,0,0,8,3,3,0,0,8,3,4,0,0,8,3,5,0,0,8,3,6,0,0,8,3,7,0,0,8,3,8,0,0,8,4,3,0,0,8,4,4,0,0,8,4,5,0,0,8,4,6,0,0,8,4,7,0,0,8,4,8,0,0,8,5,3,0,0,8,5,4,0,0,8,5,5,0,0,8,5,6,0,0,8,5,7,0,0,8,5,8,0,0,8,6,3,0,0,8,6,4,0,0,8,6,5,0,0,8,6,6,0,0,8,6,7,0,0,8,6,8,0,0,8,-10,-14,0,0,8,-10,-13,0,0,8,-10,-12,0,0,8,-10,-11,0,0,8,-10,-10,0,0,8,-10,-9,0,0,8,-10,-8,0,0,8,-10,-7,0,0,8,-10,-6,0,0,8,-10,-5,0,0,8,-10,-4,0,0,8,-9,-14,0,0,8,-9,-13,0,0,8,-9,-12,0,0,8,-9,-11,0,0,8,-9,-10,0,0,8,-9,-9,0,0,8,-9,-8,0,0,8,-9,-7,0,0,8,-9,-6,0,0,8,-9,-5,0,0,8,-9,-4,0,0,8,-8,-14,0,0,8,-8,-13,0,0,8,-8,-12,0,0,8,-8,-11,0,0,8,-8,-10,0,0,8,-8,-9,0,0,8,-8,-8,0,0,8,-8,-7,0,0,8,-7,-14,0,0,8,-7,-13,0,0,8,-7,-12,0,0,8,-7,-11,0,0,8,-7,-10,0,0,8,-7,-9,0,0,8,-7,-8,0,0,8,-7,-7,0,0,8,-6,-14,0,0,8,-6,-13,0,0,8,-6,-12,0,0,8,-6,-11,0,0,8,-6,-10,0,0,8,-6,-9,0,0,8,-6,-8,0,0,8,-6,-7,0,0,8,-5,-14,0,0,8,-5,-13,0,0,8,-5,-12,0,0,8,-5,-11,0,0,8,-5,-10,0,0,8,-5,-9,0,0,8,-5,-8,0,0,8,-5,-7,0,0,8,-4,-14,0,0,8,-4,-13,0,0,8,-4,-12,0,0,8,-4,-11,0,0,8,-4,-10,0,0,8,-4,-9,0,0,8,-4,-8,0,0,8,-4,-7,0,0,8,-15,-1,0,0,8,-15,0,0,0,8,-15,1,0,0,8,-15,2,0,0,8,-15,3,0,0,8,-15,4,0,0,8,-15,5,0,0,8,-15,6,0,0,8,-15,7,0,0,8,-15,8,0,0,8,-14,-1,0,0,8,-14,0,0,0,8,-14,1,0,0,8,-14,2,0,0,8,-14,3,0,0,8,-14,4,0,0,8,-14,5,0,0,8,-14,6,0,0,8,-14,7,0,0,8,-14,8,0,0,8,-13,-1,0,0,8,-13,0,0,0,8,-13,1,0,0,8,-13,2,0,0,8,-13,3,0,0,8,-13,4,0,0,8,-13,5,0,0,8,-13,6,0,0,8,-13,7,0,0,8,-13,8,0,0,8,-12,-1,0,0,8,-12,0,0,0,8,-12,1,0,0,8,-12,2,0,0,8,-12,3,0,0,8,-12,4,0,0,8,-12,5,0,0,8,-12,6,0,0,8,-12,7,0,0,8,-12,8,0,0,8,-11,-1,0,0,8,-11,0,0,0,8,-11,1,0,0,8,-11,2,0,0,8,-11,3,0,0,8,-11,4,0,0,8,-11,5,0,0,8,-11,6,0,0,8,-11,7,0,0,8,-11,8,0,0,8,-10,-1,0,0,8,-10,0,0,0,8,-10,1,0,0,8,-10,2,0,0,8,-10,3,0,0,8,-10,4,0,0,8,-10,5,0,0,8,-10,6,0,0,8,-10,7,0,0,8,-10,8,0,0,8,-9,-1,0,0,8,-9,0,0,0,8,-9,1,0,0,8,-9,2,0,0,8,-9,3,0,0,8,-9,4,0,0,8,-9,5,0,0,8,-9,6,0,0,8,-9,7,0,0,8,-9,8,0,0,8,-8,3,0,0,8,-8,4,0,0,8,-8,5,0,0,8,-8,6,0,0,8,-8,7,0,0,8,-8,8,0,0,8,-7,3,0,0,8,-7,4,0,0,8,-7,5,0,0,8,-7,6,0,0,8,-7,7,0,0,8,-7,8,0,0,8,-6,3,0,0,8,-6,4,0,0,8,-6,5,0,0,8,-6,6,0,0,8,-6,7,0,0,8,-6,8,0,0,8,-5,7,0,0,8,-5,8,0,0,8,-4,7,0,0,8,-4,8,0,0,8,-4,9,0,0,8,-4,10,0,0,8,-4,11,0,0,8,-4,12,0,0,8,-3,7,0,0,8,-3,8,0,0,8,-3,9,0,0,8,-3,10,0,0,8,-3,11,0,0,8,-3,12,0,0,8,-2,7,0,0,8,-2,8,0,0,8,-2,9,0,0,8,-2,10,0,0,8,-2,11,0,0,8,-2,12,0,0,8,-1,6,0,0,8,-1,7,0,0,8,-1,8,0,0,8,-1,9,0,0,8,-1,10,0,0,8,-1,11,0,0,8,-1,12,0,0,8,0,9,0,0,8,0,10,0,0,8,0,11,0,0,8,0,12,0,0,8,1,9,0,0,8,1,10,0,0,8,1,11,0,0,8,1,12,0,0,8,2,9,0,0,8,2,10,0,0,8,2,11,0,0,8,2,12,0,0,8,-6,9,0,0,8,-6,10,0,0,8,-6,11,0,0,8,-6,12,0,0,8,-6,13,0,0,8,-6,14,0,0,8,-5,9,0,0,8,-5,10,0,0,8,-5,11,0,0,8,-5,12,0,0,8,-5,13,0,0,8,-5,14,0,0,8,-4,13,0,0,8,-4,14,0,0,8,-9,9,0,0,8,-9,10,0,0,8,-9,11,0,0,8,-8,9,0,0,8,-8,10,0,0,8,-8,11,0,0,8,-7,9,0,0,8,-7,10,0,0,8,-7,11,0,0,8,3,9,0,0,8,3,10,0,0,8,3,11,0,0,8,3,12,0,0,8,4,9,0,0,8,4,10,0,0,8,4,11,0,0,8,4,12,0,0,8,5,9,0,0,8,5,10,0,0,8,5,11,0,0,8,5,12,0,0,8,6,9,0,0,8,6,10,0,0,8,6,11,0,0,8,6,12,0,0,8,-3,13,0,0,8,-3,14,0,0,8,-2,13,0,0,8,-2,14,0,0,8,-1,13,0,0,8,-1,14,0,0,8,0,13,0,0,8,0,14,0,0,8,1,13,0,0,8,1,14,0,0,8,2,13,0,0,8,2,14,0,0,8,3,13,0,0,8,3,14,0,0,8,-3,2,0,0,8],"Middle":[-15,-2,0,2,7,-14,-2,0,2,7,-13,-2,0,2,7,-12,-2,0,2,7,-11,-2,0,2,7,-10,-15,0,2,7,-10,-2,0,2,7,-9,-15,0,2,7,-9,-2,0,3,7,-8,-15,0,2,7,-7,-15,0,2,7,-6,-15,0,2,7,-5,-15,0,2,7,-5,6,0,1,7,-4,-15,0,2,7,-4,6,0,2,7,-3,-7,0,1,7,-3,6,0,2,7,-2,-7,0,2,7,-2,6,0,3,7,-1,-7,0,2,7,-1,5,0,3,7,0,-7,0,2,7,0,4,0,3,7,1,-7,0,2,7,2,-7,0,2,7,3,-7,0,2,7,4,-7,0,2,7,5,-7,0,2,7,6,-7,0,2,7,7,-7,0,2,7,8,-7,0,2,7],"Top":[-16,-2,0,3,4,-16,-1,0,3,3,-16,0,0,3,3,-16,1,0,3,3,-16,2,0,3,3,-16,3,0,3,3,-16,4,0,3,3,-16,5,0,3,3,-16,6,0,3,3,-16,7,0,3,3,-16,8,0,3,3,-16,9,0,11,2,-15,9,0,2,2,-14,9,0,2,2,-13,9,0,2,2,-12,9,0,2,2,-11,-15,0,3,4,-11,-14,0,3,3,-11,-13,0,3,3,-11,-12,0,3,3,-11,-11,0,3,3,-11,-10,0,3,3,-11,-9,0,3,3,-11,-8,0,3,3,-11,-7,0,3,3,-11,-6,0,3,3,-11,-5,0,3,3,-11,-4,0,3,3,-11,-3,0,11,2,-11,9,0,2,2,-10,-3,0,2,2,-10,9,0,3,2,-10,10,0,3,3,-10,11,0,3,3,-10,12,0,11,2,-9,-3,0,3,2,-9,12,0,2,2,-8,12,0,2,2,-7,12,0,3,2,-7,13,0,3,3,-7,14,0,3,3,-7,15,0,11,2,-6,15,0,2,2,-5,2,0,1,2,-5,3,0,1,3,-5,4,0,1,3,-5,5,0,1,3,-5,15,0,2,2,-4,2,0,3,2,-4,3,0,11,2,-4,15,0,2,2,-3,-15,0,1,4,-3,-14,0,1,3,-3,-13,0,1,3,-3,-12,0,1,3,-3,-11,0,1,3,-3,-10,0,1,3,-3,-9,0,1,3,-3,-8,0,1,3,-3,3,0,2,2,-3,15,0,2,2,-2,3,0,2,2,-2,5,0,3,4,-2,15,0,2,2,-1,-1,0,1,2,-1,0,0,1,3,-1,1,0,1,3,-1,2,0,1,3,-1,3,0,13,2,-1,4,0,3,4,-1,15,0,2,2,0,-1,0,3,2,0,0,0,3,3,0,1,0,3,3,0,2,0,3,3,0,3,0,3,3,0,15,0,2,2,1,15,0,2,2,2,15,0,2,2,3,15,0,2,2,4,13,0,1,2,4,14,0,1,3,4,15,0,13,2,5,13,0,2,2,6,13,0,2,2,7,3,0,1,2,7,4,0,1,3,7,5,0,1,3,7,6,0,1,3,7,7,0,1,3,7,8,0,1,3,7,9,0,1,3,7,10,0,1,3,7,11,0,1,3,7,12,0,1,3,7,13,0,13,2,8,3,0,2,2,9,-7,0,1,4,9,-6,0,1,3,9,-5,0,1,3,9,-4,0,1,3,9,-3,0,1,3,9,-2,0,1,3,9,-1,0,1,3,9,0,0,1,3,9,1,0,1,3,9,2,0,1,3,9,3,0,13,2]} \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preinstall.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preinstall.json new file mode 100644 index 0000000..bf4f6af --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preinstall.json @@ -0,0 +1 @@ +[{"Name":"test1","Weight":100,"Remark":"","WaveList":[[{"Position":{"X":51,"Y":90},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0009","CurrAmmon":"1","ResidueAmmo":"1"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":11,"Y":228},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0002","CurrAmmon":"7","ResidueAmmo":"7"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":103,"Y":173},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0009","CurrAmmon":"1","ResidueAmmo":"1"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":66,"Y":-4},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0007","CurrAmmon":"60","ResidueAmmo":"60"},"Altitude":0,"VerticalSpeed":0}]}],[{"Position":{"X":-1,"Y":119},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":null},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":185,"Y":110},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":null},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":-44,"Y":-39},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0.5,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0008","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":116,"Y":229},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":1,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0008","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":-73,"Y":226},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0009","CurrAmmon":"1","ResidueAmmo":"1"},"Altitude":0,"VerticalSpeed":0}]}],[{"Position":{"X":65,"Y":208},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0.5,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":null},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":71,"Y":33},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":1,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":null},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":-65,"Y":102},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":1.5,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0002","CurrAmmon":"7","ResidueAmmo":"7"},"Altitude":0,"VerticalSpeed":0}]},{"Position":{"X":119,"Y":115},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0002","CurrAmmon":"7","ResidueAmmo":"7"},"Altitude":0,"VerticalSpeed":0}]}]]}] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preview.png b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preview.png new file mode 100644 index 0000000..d263705 --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preview.png Binary files differ diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preview.png.import b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preview.png.import new file mode 100644 index 0000000..41fdf86 --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/Preview.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://w8enumbscx08" +path="res://.godot/imported/Preview.png-57faf91d48bfaedc5b04c411842f9580.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/map/tileMaps/TestGroup1/battle/Battle5/Preview.png" +dest_files=["res://.godot/imported/Preview.png-57faf91d48bfaedc5b04c411842f9580.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/RoomInfo.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/RoomInfo.json new file mode 100644 index 0000000..1fba846 --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/RoomInfo.json @@ -0,0 +1 @@ +{"Position":{"X":-10,"Y":-8},"Size":{"X":28,"Y":30},"DoorAreaInfos":[{"Direction":3,"Start":0,"End":192},{"Direction":3,"Start":272,"End":400},{"Direction":0,"Start":128,"End":384},{"Direction":2,"Start":144,"End":336},{"Direction":1,"Start":288,"End":400},{"Direction":1,"Start":0,"End":160}],"GroupName":"TestGroup1","RoomType":0,"RoomName":"Battle5","Weight":100,"Remark":""} \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/TileInfo.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/TileInfo.json new file mode 100644 index 0000000..be4573e --- /dev/null +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Battle5/TileInfo.json @@ -0,0 +1 @@ +{"NavigationList":[{"Type":0,"Points":[-136,-104,40,-104,40,-40,136,-40,136,-104,248,-104,248,24,264,24,264,272,184,272,184,336,8,336,8,272,-40,272,-40,288,-136,288,-136,184,-88,184,-88,128,-120,128,-120,48,-136,48]},{"Type":1,"Points":[-40,16,24,16,24,72,-40,72]},{"Type":1,"Points":[104,16,168,16,168,72,104,72]},{"Type":1,"Points":[-24,144,40,144,40,200,-24,200]},{"Type":1,"Points":[136,160,200,160,200,216,136,216]}],"Floor":[-9,-7,0,0,8,-9,-6,0,0,8,-9,-5,0,0,8,-9,-4,0,0,8,-9,-3,0,0,8,-9,-2,0,0,8,-9,-1,0,0,8,-9,0,0,0,8,-9,1,0,0,8,-9,2,0,0,8,-8,-7,0,0,8,-8,-6,0,0,8,-8,-5,0,0,8,-8,-4,0,0,8,-8,-3,0,0,8,-8,-2,0,0,8,-8,-1,0,0,8,-8,0,0,0,8,-8,1,0,0,8,-8,2,0,0,8,-7,-7,0,0,8,-7,-6,0,0,8,-7,-5,0,0,8,-7,-4,0,0,8,-7,-3,0,0,8,-7,-2,0,0,8,-7,-1,0,0,8,-7,0,0,0,8,-7,1,0,0,8,-7,2,0,0,8,-6,-7,0,0,8,-6,-6,0,0,8,-6,-5,0,0,8,-6,-4,0,0,8,-6,-3,0,0,8,-6,-2,0,0,8,-6,-1,0,0,8,-6,0,0,0,8,-6,1,0,0,8,-6,2,0,0,8,-5,-7,0,0,8,-5,-6,0,0,8,-5,-5,0,0,8,-5,-4,0,0,8,-5,-3,0,0,8,-5,-2,0,0,8,-5,-1,0,0,8,-5,0,0,0,8,-5,1,0,0,8,-5,2,0,0,8,-4,-7,0,0,8,-4,-6,0,0,8,-4,-5,0,0,8,-4,-4,0,0,8,-4,-3,0,0,8,-4,-2,0,0,8,-4,-1,0,0,8,-4,0,0,0,8,-4,1,0,0,8,-4,2,0,0,8,-3,-7,0,0,8,-3,-6,0,0,8,-3,-5,0,0,8,-3,-4,0,0,8,-3,-3,0,0,8,-3,-2,0,0,8,-3,-1,0,0,8,-3,0,0,0,8,-3,1,0,0,8,-3,2,0,0,8,-2,-7,0,0,8,-2,-6,0,0,8,-2,-5,0,0,8,-2,-4,0,0,8,-2,-3,0,0,8,-2,-2,0,0,8,-2,-1,0,0,8,-2,0,0,0,8,-1,-7,0,0,8,-1,-6,0,0,8,-1,-5,0,0,8,-1,-4,0,0,8,-1,-3,0,0,8,-1,-2,0,0,8,-1,-1,0,0,8,-1,0,0,0,8,0,-7,0,0,8,0,-6,0,0,8,0,-5,0,0,8,0,-4,0,0,8,0,-3,0,0,8,0,-2,0,0,8,0,-1,0,0,8,0,0,0,0,8,1,-7,0,0,8,1,-6,0,0,8,1,-5,0,0,8,1,-4,0,0,8,1,-3,0,0,8,1,-2,0,0,8,1,-1,0,0,8,1,0,0,0,8,1,1,0,0,8,1,2,0,0,8,2,-7,0,0,8,2,-6,0,0,8,2,-5,0,0,8,2,-4,0,0,8,2,-3,0,0,8,2,-2,0,0,8,2,-1,0,0,8,2,0,0,0,8,2,1,0,0,8,2,2,0,0,8,1,3,0,0,8,1,4,0,0,8,1,5,0,0,8,1,6,0,0,8,1,7,0,0,8,1,8,0,0,8,2,3,0,0,8,2,4,0,0,8,2,5,0,0,8,2,6,0,0,8,2,7,0,0,8,2,8,0,0,8,2,9,0,0,8,2,10,0,0,8,2,11,0,0,8,3,1,0,0,8,3,2,0,0,8,3,3,0,0,8,3,4,0,0,8,3,5,0,0,8,3,6,0,0,8,3,7,0,0,8,3,8,0,0,8,3,9,0,0,8,3,10,0,0,8,3,11,0,0,8,4,1,0,0,8,4,2,0,0,8,4,3,0,0,8,4,4,0,0,8,4,5,0,0,8,4,6,0,0,8,4,7,0,0,8,4,8,0,0,8,4,9,0,0,8,4,10,0,0,8,4,11,0,0,8,5,1,0,0,8,5,2,0,0,8,5,3,0,0,8,5,4,0,0,8,5,5,0,0,8,5,6,0,0,8,5,7,0,0,8,5,8,0,0,8,5,9,0,0,8,5,10,0,0,8,5,11,0,0,8,6,1,0,0,8,6,2,0,0,8,6,3,0,0,8,6,4,0,0,8,6,5,0,0,8,6,6,0,0,8,6,7,0,0,8,6,8,0,0,8,6,9,0,0,8,6,10,0,0,8,6,11,0,0,8,7,4,0,0,8,7,5,0,0,8,7,6,0,0,8,7,7,0,0,8,7,8,0,0,8,7,9,0,0,8,7,10,0,0,8,7,11,0,0,8,8,4,0,0,8,8,5,0,0,8,8,6,0,0,8,8,7,0,0,8,8,8,0,0,8,8,9,0,0,8,8,10,0,0,8,8,11,0,0,8,9,4,0,0,8,9,5,0,0,8,9,6,0,0,8,9,7,0,0,8,9,8,0,0,8,9,9,0,0,8,10,1,0,0,8,10,2,0,0,8,10,3,0,0,8,10,4,0,0,8,10,5,0,0,8,10,6,0,0,8,10,7,0,0,8,10,8,0,0,8,10,9,0,0,8,11,1,0,0,8,11,2,0,0,8,11,3,0,0,8,11,4,0,0,8,11,5,0,0,8,11,6,0,0,8,11,7,0,0,8,11,8,0,0,8,11,9,0,0,8,12,1,0,0,8,12,2,0,0,8,12,3,0,0,8,12,4,0,0,8,12,5,0,0,8,12,6,0,0,8,12,7,0,0,8,12,8,0,0,8,12,9,0,0,8,12,10,0,0,8,12,11,0,0,8,13,1,0,0,8,13,2,0,0,8,13,3,0,0,8,13,4,0,0,8,13,5,0,0,8,13,6,0,0,8,13,7,0,0,8,13,8,0,0,8,13,9,0,0,8,13,10,0,0,8,13,11,0,0,8,14,1,0,0,8,14,2,0,0,8,14,3,0,0,8,14,4,0,0,8,14,5,0,0,8,14,6,0,0,8,14,7,0,0,8,14,8,0,0,8,14,9,0,0,8,14,10,0,0,8,14,11,0,0,8,15,1,0,0,8,15,2,0,0,8,15,3,0,0,8,15,4,0,0,8,15,5,0,0,8,15,6,0,0,8,15,7,0,0,8,15,8,0,0,8,15,9,0,0,8,15,10,0,0,8,15,11,0,0,8,16,1,0,0,8,16,2,0,0,8,16,3,0,0,8,16,4,0,0,8,16,5,0,0,8,16,6,0,0,8,16,7,0,0,8,16,8,0,0,8,16,9,0,0,8,16,10,0,0,8,16,11,0,0,8,-8,3,0,0,8,-8,4,0,0,8,-8,5,0,0,8,-8,6,0,0,8,-8,7,0,0,8,-7,3,0,0,8,-7,4,0,0,8,-7,5,0,0,8,-7,6,0,0,8,-7,7,0,0,8,-6,3,0,0,8,-6,4,0,0,8,-6,5,0,0,8,-6,6,0,0,8,-6,7,0,0,8,-5,3,0,0,8,-5,4,0,0,8,-5,5,0,0,8,-5,6,0,0,8,-5,7,0,0,8,-4,3,0,0,8,-4,4,0,0,8,-4,5,0,0,8,-4,6,0,0,8,-4,7,0,0,8,-3,3,0,0,8,-3,4,0,0,8,-3,5,0,0,8,-3,6,0,0,8,-3,7,0,0,8,-2,4,0,0,8,-2,5,0,0,8,-2,6,0,0,8,-2,7,0,0,8,-1,4,0,0,8,-1,5,0,0,8,-1,6,0,0,8,-1,7,0,0,8,0,4,0,0,8,0,5,0,0,8,0,6,0,0,8,0,7,0,0,8,-6,8,0,0,8,-6,9,0,0,8,-6,10,0,0,8,-6,11,0,0,8,-6,12,0,0,8,-6,13,0,0,8,-5,8,0,0,8,-5,9,0,0,8,-5,10,0,0,8,-5,11,0,0,8,-5,12,0,0,8,-5,13,0,0,8,-4,8,0,0,8,-4,9,0,0,8,-4,10,0,0,8,-4,11,0,0,8,-4,12,0,0,8,-4,13,0,0,8,-3,8,0,0,8,-3,9,0,0,8,-3,10,0,0,8,-3,11,0,0,8,-3,12,0,0,8,-3,13,0,0,8,-2,8,0,0,8,-2,9,0,0,8,-2,10,0,0,8,-2,11,0,0,8,-2,12,0,0,8,-2,13,0,0,8,-2,14,0,0,8,-2,15,0,0,8,-2,16,0,0,8,-1,8,0,0,8,-1,12,0,0,8,-1,13,0,0,8,-1,14,0,0,8,-1,15,0,0,8,-1,16,0,0,8,0,8,0,0,8,0,12,0,0,8,0,13,0,0,8,0,14,0,0,8,0,15,0,0,8,0,16,0,0,8,1,12,0,0,8,1,13,0,0,8,1,14,0,0,8,1,15,0,0,8,1,16,0,0,8,0,17,0,0,8,0,18,0,0,8,0,19,0,0,8,0,20,0,0,8,1,17,0,0,8,1,18,0,0,8,1,19,0,0,8,1,20,0,0,8,2,12,0,0,8,2,13,0,0,8,2,14,0,0,8,2,15,0,0,8,2,16,0,0,8,2,17,0,0,8,2,18,0,0,8,2,19,0,0,8,2,20,0,0,8,3,12,0,0,8,3,13,0,0,8,3,14,0,0,8,3,15,0,0,8,3,16,0,0,8,3,17,0,0,8,3,18,0,0,8,3,19,0,0,8,3,20,0,0,8,4,12,0,0,8,4,13,0,0,8,4,14,0,0,8,4,15,0,0,8,4,16,0,0,8,4,17,0,0,8,4,18,0,0,8,4,19,0,0,8,4,20,0,0,8,5,12,0,0,8,5,13,0,0,8,5,14,0,0,8,5,15,0,0,8,5,16,0,0,8,5,17,0,0,8,5,18,0,0,8,5,19,0,0,8,5,20,0,0,8,6,12,0,0,8,6,13,0,0,8,6,14,0,0,8,6,15,0,0,8,6,16,0,0,8,6,17,0,0,8,6,18,0,0,8,6,19,0,0,8,6,20,0,0,8,7,12,0,0,8,7,13,0,0,8,7,14,0,0,8,7,15,0,0,8,7,16,0,0,8,7,17,0,0,8,7,18,0,0,8,7,19,0,0,8,7,20,0,0,8,8,12,0,0,8,8,13,0,0,8,8,14,0,0,8,8,15,0,0,8,8,16,0,0,8,8,17,0,0,8,8,18,0,0,8,8,19,0,0,8,8,20,0,0,8,9,13,0,0,8,9,14,0,0,8,9,15,0,0,8,9,16,0,0,8,9,17,0,0,8,9,18,0,0,8,9,19,0,0,8,9,20,0,0,8,10,13,0,0,8,10,14,0,0,8,10,15,0,0,8,10,16,0,0,8,10,17,0,0,8,10,18,0,0,8,10,19,0,0,8,10,20,0,0,8,11,13,0,0,8,11,14,0,0,8,11,15,0,0,8,11,16,0,0,8,11,17,0,0,8,11,18,0,0,8,11,19,0,0,8,11,20,0,0,8,3,-3,0,0,8,3,-2,0,0,8,3,-1,0,0,8,3,0,0,0,8,4,-3,0,0,8,4,-2,0,0,8,4,-1,0,0,8,4,0,0,0,8,5,-3,0,0,8,5,-2,0,0,8,5,-1,0,0,8,5,0,0,0,8,6,-3,0,0,8,6,-2,0,0,8,6,-1,0,0,8,6,0,0,0,8,7,-3,0,0,8,7,-2,0,0,8,7,-1,0,0,8,7,0,0,0,8,8,-3,0,0,8,8,-2,0,0,8,8,-1,0,0,8,8,0,0,0,8,9,-3,0,0,8,9,-2,0,0,8,9,-1,0,0,8,9,0,0,0,8,10,-2,0,0,8,10,-1,0,0,8,10,0,0,0,8,11,-2,0,0,8,11,-1,0,0,8,11,0,0,0,8,12,-2,0,0,8,12,-1,0,0,8,12,0,0,0,8,13,-2,0,0,8,13,-1,0,0,8,13,0,0,0,8,14,-2,0,0,8,14,-1,0,0,8,14,0,0,0,8,12,12,0,0,8,12,13,0,0,8,12,14,0,0,8,13,12,0,0,8,13,13,0,0,8,13,14,0,0,8,14,12,0,0,8,14,13,0,0,8,14,14,0,0,8,12,15,0,0,8,12,16,0,0,8,13,15,0,0,8,13,16,0,0,8,14,15,0,0,8,14,16,0,0,8,15,14,0,0,8,15,15,0,0,8,15,16,0,0,8,15,12,0,0,8,15,13,0,0,8,16,12,0,0,8,16,13,0,0,8,16,14,0,0,8,16,15,0,0,8,16,16,0,0,8,-9,11,0,0,8,-9,12,0,0,8,-9,13,0,0,8,-9,14,0,0,8,-9,15,0,0,8,-9,16,0,0,8,-9,17,0,0,8,-8,11,0,0,8,-8,12,0,0,8,-8,13,0,0,8,-8,14,0,0,8,-8,15,0,0,8,-8,16,0,0,8,-8,17,0,0,8,-7,11,0,0,8,-7,12,0,0,8,-7,13,0,0,8,-7,14,0,0,8,-7,15,0,0,8,-7,16,0,0,8,-7,17,0,0,8,-6,14,0,0,8,-6,15,0,0,8,-6,16,0,0,8,-6,17,0,0,8,-5,14,0,0,8,-5,15,0,0,8,-5,16,0,0,8,-5,17,0,0,8,-4,14,0,0,8,-4,15,0,0,8,-4,16,0,0,8,-4,17,0,0,8,-3,14,0,0,8,-3,15,0,0,8,-3,16,0,0,8,-3,17,0,0,8,8,-7,0,0,8,8,-6,0,0,8,8,-5,0,0,8,8,-4,0,0,8,9,-7,0,0,8,9,-6,0,0,8,9,-5,0,0,8,9,-4,0,0,8,10,-7,0,0,8,10,-6,0,0,8,10,-5,0,0,8,10,-4,0,0,8,10,-3,0,0,8,11,-7,0,0,8,11,-6,0,0,8,11,-5,0,0,8,11,-4,0,0,8,11,-3,0,0,8,12,-7,0,0,8,12,-6,0,0,8,12,-5,0,0,8,12,-4,0,0,8,12,-3,0,0,8,13,-7,0,0,8,13,-6,0,0,8,13,-5,0,0,8,13,-4,0,0,8,13,-3,0,0,8,14,-7,0,0,8,14,-6,0,0,8,14,-5,0,0,8,14,-4,0,0,8,14,-3,0,0,8,15,-7,0,0,8,15,-6,0,0,8,15,-5,0,0,8,15,-4,0,0,8,15,-3,0,0,8,15,-2,0,0,8,15,-1,0,0,8,15,0,0,0,8],"Middle":[-9,-8,0,2,7,-9,10,0,2,7,-8,-8,0,2,7,-8,10,0,2,7,-7,-8,0,2,7,-7,10,0,3,7,-6,-8,0,2,7,-5,-8,0,2,7,-4,-8,0,2,7,-3,-8,0,2,7,-2,-8,0,2,7,-2,3,0,1,7,-1,-8,0,2,7,-1,3,0,2,7,-1,11,0,1,7,0,-8,0,2,7,0,3,0,3,7,0,11,0,2,7,1,-8,0,2,7,1,11,0,3,7,2,-8,0,2,7,3,-4,0,1,7,4,-4,0,2,7,5,-4,0,2,7,6,-4,0,2,7,7,-4,0,3,7,7,3,0,1,7,8,-8,0,2,7,8,3,0,2,7,9,-8,0,2,7,9,3,0,3,7,9,12,0,1,7,10,-8,0,2,7,10,12,0,2,7,11,-8,0,2,7,11,12,0,3,7,12,-8,0,2,7,13,-8,0,2,7,14,-8,0,2,7,15,-8,0,2,7,16,0,0,1,7],"Top":[-10,-8,0,3,4,-10,-7,0,3,3,-10,-6,0,3,3,-10,-5,0,3,3,-10,-4,0,3,3,-10,-3,0,3,3,-10,-2,0,3,3,-10,-1,0,3,3,-10,0,0,3,3,-10,1,0,3,3,-10,2,0,3,3,-10,3,0,11,2,-10,10,0,3,4,-10,11,0,3,3,-10,12,0,3,3,-10,13,0,3,3,-10,14,0,3,3,-10,15,0,3,3,-10,16,0,3,3,-10,17,0,3,3,-10,18,0,11,2,-9,3,0,3,2,-9,4,0,3,3,-9,5,0,3,3,-9,6,0,3,3,-9,7,0,3,3,-9,8,0,11,2,-9,18,0,2,2,-8,8,0,2,2,-8,18,0,2,2,-7,8,0,3,2,-7,9,0,3,3,-7,18,0,2,2,-6,18,0,2,2,-5,18,0,2,2,-4,18,0,2,2,-3,18,0,2,2,-2,1,0,1,2,-2,2,0,1,3,-2,17,0,1,2,-2,18,0,13,2,-1,1,0,2,2,-1,9,0,1,2,-1,10,0,1,3,-1,17,0,3,2,-1,18,0,3,3,-1,19,0,3,3,-1,20,0,3,3,-1,21,0,11,2,0,1,0,3,2,0,2,0,3,3,0,9,0,2,2,0,21,0,2,2,1,9,0,3,2,1,10,0,3,3,1,21,0,2,2,2,21,0,2,2,3,-8,0,1,4,3,-7,0,1,3,3,-6,0,1,3,3,-5,0,1,3,3,21,0,2,2,4,21,0,2,2,5,21,0,2,2,6,21,0,2,2,7,-8,0,3,4,7,-7,0,3,3,7,-6,0,3,3,7,-5,0,3,3,7,1,0,1,2,7,2,0,1,3,7,21,0,2,2,8,1,0,2,2,8,21,0,2,2,9,1,0,3,2,9,2,0,3,3,9,10,0,1,2,9,11,0,1,3,9,21,0,2,2,10,10,0,2,2,10,21,0,2,2,11,10,0,3,2,11,11,0,3,3,11,21,0,2,2,12,17,0,1,2,12,18,0,1,3,12,19,0,1,3,12,20,0,1,3,12,21,0,13,2,13,17,0,2,2,14,17,0,2,2,15,17,0,2,2,16,-8,0,1,4,16,-7,0,1,3,16,-6,0,1,3,16,-5,0,1,3,16,-4,0,1,3,16,-3,0,1,3,16,-2,0,1,3,16,-1,0,1,3,16,17,0,2,2,17,0,0,1,4,17,1,0,1,3,17,2,0,1,3,17,3,0,1,3,17,4,0,1,3,17,5,0,1,3,17,6,0,1,3,17,7,0,1,3,17,8,0,1,3,17,9,0,1,3,17,10,0,1,3,17,11,0,1,3,17,12,0,1,3,17,13,0,1,3,17,14,0,1,3,17,15,0,1,3,17,16,0,1,3,17,17,0,13,2]} \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preinstall.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preinstall.json index 582ee5f..7a7ca41 100644 --- a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preinstall.json +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preinstall.json @@ -1 +1 @@ -[{"Name":"test1","Weight":100,"Remark":"","WaveList":[[{"Position":{"X":19,"Y":2},"Size":{"X":0,"Y":0},"SpecialMarkType":1,"DelayTime":0,"MarkList":[]},{"Position":{"X":-76,"Y":35},"Size":{"X":0,"Y":0},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0001","Weight":100,"Attr":{"CurrAmmon":"30","ResidueAmmo":"210"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-79,"Y":46},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0002","Weight":100,"Attr":{"CurrAmmon":"7","ResidueAmmo":"70"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-75,"Y":2},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0004","Weight":100,"Attr":{"CurrAmmon":"180","ResidueAmmo":"90"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-75,"Y":67},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0005","Weight":100,"Attr":{"CurrAmmon":"10","ResidueAmmo":"40"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-73,"Y":-18},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0003","Weight":100,"Attr":{"CurrAmmon":"12","ResidueAmmo":"90"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-76,"Y":21},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0006","Weight":100,"Attr":{"CurrAmmon":"20","ResidueAmmo":"300"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-74,"Y":-30},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0007","Weight":100,"Attr":{"CurrAmmon":"60","ResidueAmmo":"300"},"Altitude":8,"VerticalSpeed":0}]}],[{"Position":{"X":55,"Y":67},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"prop0003","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":56,"Y":24},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0.5,"MarkList":[{"Id":"prop5000","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":56,"Y":0},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":1,"MarkList":[{"Id":"prop5001","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":34,"Y":23},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":1.5,"MarkList":[{"Id":"prop0002","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":55,"Y":44},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"prop5001","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":56,"Y":-24},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"prop5001","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-16,"Y":16},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"enemy0001","Weight":100,"Attr":{"Face":"0","Weapon":"weapon0005","CurrAmmon":"10","ResidueAmmo":"10"},"Altitude":0,"VerticalSpeed":0}]}]]}] \ No newline at end of file +[{"Name":"test1","Weight":100,"Remark":"","WaveList":[[{"Position":{"X":19,"Y":2},"Size":{"X":0,"Y":0},"SpecialMarkType":1,"DelayTime":0,"MarkList":[]},{"Position":{"X":24,"Y":-14},"Size":{"X":0,"Y":0},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0001","Weight":100,"Attr":{"CurrAmmon":"30","ResidueAmmo":"210"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":6,"Y":34},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0002","Weight":100,"Attr":{"CurrAmmon":"7","ResidueAmmo":"70"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-42,"Y":9},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0004","Weight":100,"Attr":{"CurrAmmon":"180","ResidueAmmo":"90"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-63,"Y":-18},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0005","Weight":100,"Attr":{"CurrAmmon":"10","ResidueAmmo":"40"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-31,"Y":-16},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0003","Weight":100,"Attr":{"CurrAmmon":"12","ResidueAmmo":"90"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-47,"Y":32},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0006","Weight":100,"Attr":{"CurrAmmon":"20","ResidueAmmo":"300"},"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":2,"Y":-25},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"weapon0007","Weight":100,"Attr":{"CurrAmmon":"60","ResidueAmmo":"300"},"Altitude":8,"VerticalSpeed":0}]}],[{"Position":{"X":57,"Y":56},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"prop0003","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":67,"Y":28},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0.5,"MarkList":[{"Id":"prop5000","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":60,"Y":-19},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":1,"MarkList":[{"Id":"prop5001","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":34,"Y":23},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":1.5,"MarkList":[{"Id":"prop0002","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-11,"Y":8},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"prop0010","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]},{"Position":{"X":-20,"Y":33},"Size":{"X":16,"Y":16},"SpecialMarkType":0,"DelayTime":0,"MarkList":[{"Id":"prop0010","Weight":100,"Attr":null,"Altitude":8,"VerticalSpeed":0}]}]]}] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preview.png b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preview.png index d64d95a..e502322 100644 --- a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preview.png +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/inlet/Start1/Preview.png Binary files differ diff --git a/DungeonShooting_Godot/resource/material/Blend.tres b/DungeonShooting_Godot/resource/material/Blend.tres index 8d6f5b3..b3015f1 100644 --- a/DungeonShooting_Godot/resource/material/Blend.tres +++ b/DungeonShooting_Godot/resource/material/Blend.tres @@ -9,5 +9,6 @@ shader_parameter/schedule = 0.0 shader_parameter/modulate = Color(1, 1, 1, 1) shader_parameter/show_outline = true -shader_parameter/outline_color = Color(0.941176, 0.941176, 0.941176, 1) +shader_parameter/outline_color = Color(0, 0, 0, 1) shader_parameter/outline_rainbow = false +shader_parameter/outline_use_blend = true diff --git a/DungeonShooting_Godot/resource/material/SmokeParticleMaterial.tres b/DungeonShooting_Godot/resource/material/SmokeParticleMaterial.tres index 95ae1df..4470829 100644 --- a/DungeonShooting_Godot/resource/material/SmokeParticleMaterial.tres +++ b/DungeonShooting_Godot/resource/material/SmokeParticleMaterial.tres @@ -11,11 +11,9 @@ [resource] particle_flag_disable_z = true spread = 180.0 -gravity = Vector3(0, 0, 0) initial_velocity_min = 5.0 initial_velocity_max = 35.0 -orbit_velocity_min = 0.0 -orbit_velocity_max = 0.0 +gravity = Vector3(0, 0, 0) scale_min = 0.8 scale_max = 0.8 scale_curve = ExtResource("1_yr5l8") diff --git a/DungeonShooting_Godot/resource/sound/sfx/collision/Collision0001.ogg b/DungeonShooting_Godot/resource/sound/sfx/collision/Collision0001.ogg new file mode 100644 index 0000000..6c4611a --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/collision/Collision0001.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/collision/Collision0001.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/collision/Collision0001.ogg.import new file mode 100644 index 0000000..2eeee7f --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/collision/Collision0001.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://rj811bni34nt" +path="res://.godot/imported/Collision0001.ogg-1ff34918eb3dbf32e125bc036d2c72c7.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/collision/Collision0001.ogg" +dest_files=["res://.godot/imported/Collision0001.ogg-1ff34918eb3dbf32e125bc036d2c72c7.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading0003.ogg b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading0003.ogg new file mode 100644 index 0000000..3d9c9e0 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading0003.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading0003.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading0003.ogg.import new file mode 100644 index 0000000..33ae0aa --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading0003.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://u205d1t1pmd7" +path="res://.godot/imported/Reloading0003.ogg-f999a761b55735706639c26438047167.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/reloading/Reloading0003.ogg" +dest_files=["res://.godot/imported/Reloading0003.ogg-f999a761b55735706639c26438047167.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0011.ogg b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0011.ogg new file mode 100644 index 0000000..824fb1c --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0011.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0011.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0011.ogg.import new file mode 100644 index 0000000..0c3fbf5 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0011.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://beyypyocstosd" +path="res://.godot/imported/Reloading_begin0011.ogg-d40519c860179a2f5de2719034c81b0d.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/reloading/Reloading_begin0011.ogg" +dest_files=["res://.godot/imported/Reloading_begin0011.ogg-d40519c860179a2f5de2719034c81b0d.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0012.ogg b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0012.ogg new file mode 100644 index 0000000..764fe80 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0012.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0012.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0012.ogg.import new file mode 100644 index 0000000..c719b9a --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_begin0012.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://57o7wubot0p" +path="res://.godot/imported/Reloading_begin0012.ogg-0e6c1367e489c60b46da4ca0078a32b2.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/reloading/Reloading_begin0012.ogg" +dest_files=["res://.godot/imported/Reloading_begin0012.ogg-0e6c1367e489c60b46da4ca0078a32b2.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0003.ogg b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0003.ogg new file mode 100644 index 0000000..d35e958 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0003.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0003.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0003.ogg.import new file mode 100644 index 0000000..d3534cd --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0003.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://d2o18o4s88puc" +path="res://.godot/imported/Reloading_finish0003.ogg-d7d55690ff37054db2ba29bb7ef86993.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/reloading/Reloading_finish0003.ogg" +dest_files=["res://.godot/imported/Reloading_finish0003.ogg-d7d55690ff37054db2ba29bb7ef86993.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0004.ogg b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0004.ogg new file mode 100644 index 0000000..18444ac --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0004.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0004.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0004.ogg.import new file mode 100644 index 0000000..5795175 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/reloading/Reloading_finish0004.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://dnyetm6s8gsoc" +path="res://.godot/imported/Reloading_finish0004.ogg-a7065b9324670014184a01ecc1ea8074.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/reloading/Reloading_finish0004.ogg" +dest_files=["res://.godot/imported/Reloading_finish0004.ogg-a7065b9324670014184a01ecc1ea8074.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0009.ogg b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0009.ogg new file mode 100644 index 0000000..f8104f6 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0009.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0009.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0009.ogg.import new file mode 100644 index 0000000..41f9be3 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0009.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://jnac4mnhxtlh" +path="res://.godot/imported/Shooting0009.ogg-58b34f0abb4c6eb9da8e6922d69071b8.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/shooting/Shooting0009.ogg" +dest_files=["res://.godot/imported/Shooting0009.ogg-58b34f0abb4c6eb9da8e6922d69071b8.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0010.ogg b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0010.ogg new file mode 100644 index 0000000..2344f0a --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0010.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0010.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0010.ogg.import new file mode 100644 index 0000000..a2a3e5c --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0010.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://cor7rdht4jq5i" +path="res://.godot/imported/Shooting0010.ogg-11b9eb3bfdf9889c1c25a815c5ce8a05.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/shooting/Shooting0010.ogg" +dest_files=["res://.godot/imported/Shooting0010.ogg-11b9eb3bfdf9889c1c25a815c5ce8a05.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0011.ogg b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0011.ogg new file mode 100644 index 0000000..e2ddabe --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0011.ogg Binary files differ diff --git a/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0011.ogg.import b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0011.ogg.import new file mode 100644 index 0000000..43c67f2 --- /dev/null +++ b/DungeonShooting_Godot/resource/sound/sfx/shooting/Shooting0011.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://dd8iw4672uyyr" +path="res://.godot/imported/Shooting0011.ogg-5ca9f9d8f36d57a9dd35dcc79e364d1f.oggvorbisstr" + +[deps] + +source_file="res://resource/sound/sfx/shooting/Shooting0011.ogg" +dest_files=["res://.godot/imported/Shooting0011.ogg-5ca9f9d8f36d57a9dd35dcc79e364d1f.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/arrow.png b/DungeonShooting_Godot/resource/sprite/bullet/arrow.png deleted file mode 100644 index 4baebfb..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/arrow.png +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/arrow.png.import b/DungeonShooting_Godot/resource/sprite/bullet/arrow.png.import deleted file mode 100644 index 18616dd..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/arrow.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="CompressedTexture2D" -uid="uid://cjb4rq1qavfm6" -path="res://.godot/imported/arrow.png-5f9f0a3c4c243acf30e833eb04add206.ctex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://resource/sprite/bullet/arrow.png" -dest_files=["res://.godot/imported/arrow.png-5f9f0a3c4c243acf30e833eb04add206.ctex"] - -[params] - -compress/mode=0 -compress/high_quality=false -compress/lossy_quality=0.7 -compress/hdr_compression=1 -compress/normal_map=0 -compress/channel_pack=0 -mipmaps/generate=false -mipmaps/limit=-1 -roughness/mode=0 -roughness/src_normal="" -process/fix_alpha_border=true -process/premult_alpha=false -process/normal_map_invert_y=false -process/hdr_as_srgb=false -process/hdr_clamp_exposure=false -process/size_limit=0 -detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet0001.png b/DungeonShooting_Godot/resource/sprite/bullet/bullet0001.png deleted file mode 100644 index 5b488de..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet0001.png +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet0001.png.import b/DungeonShooting_Godot/resource/sprite/bullet/bullet0001.png.import deleted file mode 100644 index fe2ba90..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet0001.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="CompressedTexture2D" -uid="uid://bu0b11hiuecxy" -path="res://.godot/imported/bullet0001.png-09e29b083f51e2b282ac1fb1dd682734.ctex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://resource/sprite/bullet/bullet0001.png" -dest_files=["res://.godot/imported/bullet0001.png-09e29b083f51e2b282ac1fb1dd682734.ctex"] - -[params] - -compress/mode=0 -compress/high_quality=false -compress/lossy_quality=0.7 -compress/hdr_compression=1 -compress/normal_map=0 -compress/channel_pack=0 -mipmaps/generate=false -mipmaps/limit=-1 -roughness/mode=0 -roughness/src_normal="" -process/fix_alpha_border=true -process/premult_alpha=false -process/normal_map_invert_y=false -process/hdr_as_srgb=false -process/hdr_clamp_exposure=false -process/size_limit=0 -detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet0002.png b/DungeonShooting_Godot/resource/sprite/bullet/bullet0002.png deleted file mode 100644 index a76c266..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet0002.png +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet0002.png.import b/DungeonShooting_Godot/resource/sprite/bullet/bullet0002.png.import deleted file mode 100644 index 90b0c71..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet0002.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="CompressedTexture2D" -uid="uid://ctsvj4y1t538u" -path="res://.godot/imported/bullet0002.png-5a53e3706ec2ef023e52e256612c2c94.ctex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://resource/sprite/bullet/bullet0002.png" -dest_files=["res://.godot/imported/bullet0002.png-5a53e3706ec2ef023e52e256612c2c94.ctex"] - -[params] - -compress/mode=0 -compress/high_quality=false -compress/lossy_quality=0.7 -compress/hdr_compression=1 -compress/normal_map=0 -compress/channel_pack=0 -mipmaps/generate=false -mipmaps/limit=-1 -roughness/mode=0 -roughness/src_normal="" -process/fix_alpha_border=true -process/premult_alpha=false -process/normal_map_invert_y=false -process/hdr_as_srgb=false -process/hdr_clamp_exposure=false -process/size_limit=0 -detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet0003.png b/DungeonShooting_Godot/resource/sprite/bullet/bullet0003.png deleted file mode 100644 index 14a69ff..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet0003.png +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet0003.png.import b/DungeonShooting_Godot/resource/sprite/bullet/bullet0003.png.import deleted file mode 100644 index 808d9f3..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet0003.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="CompressedTexture2D" -uid="uid://cs6pa7h8ffvy4" -path="res://.godot/imported/bullet0003.png-968c6a657388df80893fe68898e87dae.ctex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://resource/sprite/bullet/bullet0003.png" -dest_files=["res://.godot/imported/bullet0003.png-968c6a657388df80893fe68898e87dae.ctex"] - -[params] - -compress/mode=0 -compress/high_quality=false -compress/lossy_quality=0.7 -compress/hdr_compression=1 -compress/normal_map=0 -compress/channel_pack=0 -mipmaps/generate=false -mipmaps/limit=-1 -roughness/mode=0 -roughness/src_normal="" -process/fix_alpha_border=true -process/premult_alpha=false -process/normal_map_invert_y=false -process/hdr_as_srgb=false -process/hdr_clamp_exposure=false -process/size_limit=0 -detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet2.png b/DungeonShooting_Godot/resource/sprite/bullet/bullet2.png deleted file mode 100644 index 964f292..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet2.png +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/bullet2.png.import b/DungeonShooting_Godot/resource/sprite/bullet/bullet2.png.import deleted file mode 100644 index 79038a8..0000000 --- a/DungeonShooting_Godot/resource/sprite/bullet/bullet2.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="CompressedTexture2D" -uid="uid://o3iq4myj72q0" -path="res://.godot/imported/bullet2.png-6ca9527061677971732c8192cb1aa209.ctex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://resource/sprite/bullet/bullet2.png" -dest_files=["res://.godot/imported/bullet2.png-6ca9527061677971732c8192cb1aa209.ctex"] - -[params] - -compress/mode=0 -compress/high_quality=false -compress/lossy_quality=0.7 -compress/hdr_compression=1 -compress/normal_map=0 -compress/channel_pack=0 -mipmaps/generate=false -mipmaps/limit=-1 -roughness/mode=0 -roughness/src_normal="" -process/fix_alpha_border=true -process/premult_alpha=false -process/normal_map_invert_y=false -process/hdr_as_srgb=false -process/hdr_clamp_exposure=false -process/size_limit=0 -detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/laser/Laser0001.png b/DungeonShooting_Godot/resource/sprite/bullet/laser/Laser0001.png new file mode 100644 index 0000000..9338ede --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/laser/Laser0001.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/laser/Laser0001.png.import b/DungeonShooting_Godot/resource/sprite/bullet/laser/Laser0001.png.import new file mode 100644 index 0000000..3fdff0b --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/laser/Laser0001.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://clfpbq1c1ilp1" +path="res://.godot/imported/Laser0001.png-a310e56cc700e65c7853874d9765878b.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/bullet/laser/Laser0001.png" +dest_files=["res://.godot/imported/Laser0001.png-a310e56cc700e65c7853874d9765878b.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/arrow.png b/DungeonShooting_Godot/resource/sprite/bullet/normal/arrow.png new file mode 100644 index 0000000..4baebfb --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/arrow.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/arrow.png.import b/DungeonShooting_Godot/resource/sprite/bullet/normal/arrow.png.import new file mode 100644 index 0000000..ffa58c4 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/arrow.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cjb4rq1qavfm6" +path="res://.godot/imported/arrow.png-e6292bc0b86a2f51ddcbf6755de06ee0.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/bullet/normal/arrow.png" +dest_files=["res://.godot/imported/arrow.png-e6292bc0b86a2f51ddcbf6755de06ee0.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0001.png b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0001.png new file mode 100644 index 0000000..5b488de --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0001.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0001.png.import b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0001.png.import new file mode 100644 index 0000000..e261be8 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0001.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bu0b11hiuecxy" +path="res://.godot/imported/bullet0001.png-7d68281aea18b984211b806879504cbe.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/bullet/normal/bullet0001.png" +dest_files=["res://.godot/imported/bullet0001.png-7d68281aea18b984211b806879504cbe.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0002.png b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0002.png new file mode 100644 index 0000000..a76c266 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0002.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0002.png.import b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0002.png.import new file mode 100644 index 0000000..1a5e295 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0002.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ctsvj4y1t538u" +path="res://.godot/imported/bullet0002.png-710d9bc1a4f134ae89c80c46b8499940.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/bullet/normal/bullet0002.png" +dest_files=["res://.godot/imported/bullet0002.png-710d9bc1a4f134ae89c80c46b8499940.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0003.png b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0003.png new file mode 100644 index 0000000..14a69ff --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0003.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0003.png.import b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0003.png.import new file mode 100644 index 0000000..1408d33 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0003.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cs6pa7h8ffvy4" +path="res://.godot/imported/bullet0003.png-0b9ca4e8c8186f2c99bb18564bebed46.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/bullet/normal/bullet0003.png" +dest_files=["res://.godot/imported/bullet0003.png-0b9ca4e8c8186f2c99bb18564bebed46.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0004.png b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0004.png new file mode 100644 index 0000000..bf06757 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0004.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0004.png.import b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0004.png.import new file mode 100644 index 0000000..3b32b1a --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet0004.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://c25xd887txviq" +path="res://.godot/imported/bullet0004.png-998e96e7c171c50fe5b23ce64ab09962.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/bullet/normal/bullet0004.png" +dest_files=["res://.godot/imported/bullet0004.png-998e96e7c171c50fe5b23ce64ab09962.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet2.png b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet2.png new file mode 100644 index 0000000..964f292 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet2.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet2.png.import b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet2.png.import new file mode 100644 index 0000000..d48c9d6 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/bullet/normal/bullet2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://o3iq4myj72q0" +path="res://.godot/imported/bullet2.png-373c2adfe18998d5a55ebea0eaea27a9.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/bullet/normal/bullet2.png" +dest_files=["res://.godot/imported/bullet2.png-373c2adfe18998d5a55ebea0eaea27a9.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/effects/Circle2.png b/DungeonShooting_Godot/resource/sprite/effects/Circle2.png new file mode 100644 index 0000000..c27b68f --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/Circle2.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/effects/Circle2.png.import b/DungeonShooting_Godot/resource/sprite/effects/Circle2.png.import new file mode 100644 index 0000000..dfcc3c1 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/Circle2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://hsevliqnq82n" +path="res://.godot/imported/Circle2.png-ef3a2d65cdf8bc187c245a202bc736dd.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/effects/Circle2.png" +dest_files=["res://.godot/imported/Circle2.png-ef3a2d65cdf8bc187c245a202bc736dd.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/effects/common/Smoke2.png b/DungeonShooting_Godot/resource/sprite/effects/common/Smoke2.png new file mode 100644 index 0000000..af4aa83 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/common/Smoke2.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/effects/common/Smoke2.png.import b/DungeonShooting_Godot/resource/sprite/effects/common/Smoke2.png.import new file mode 100644 index 0000000..f9e9f57 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/common/Smoke2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://rk73piti0qot" +path="res://.godot/imported/Smoke2.png-bfcd0e73871f709da66c76e16b1ccd07.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/effects/common/Smoke2.png" +dest_files=["res://.godot/imported/Smoke2.png-bfcd0e73871f709da66c76e16b1ccd07.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_circle0001.png b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_circle0001.png new file mode 100644 index 0000000..c20e52e --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_circle0001.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_circle0001.png.import b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_circle0001.png.import new file mode 100644 index 0000000..d32a45b --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_circle0001.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ccdflg560oub6" +path="res://.godot/imported/Explode_circle0001.png-226d2b77cea80f656d4eb2869ee47062.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/effects/explode/Explode_circle0001.png" +dest_files=["res://.godot/imported/Explode_circle0001.png-226d2b77cea80f656d4eb2869ee47062.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_line0001.png b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_line0001.png new file mode 100644 index 0000000..b631b3f --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_line0001.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_line0001.png.import b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_line0001.png.import new file mode 100644 index 0000000..0f10321 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_line0001.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cquv6nomd3tpf" +path="res://.godot/imported/Explode_line0001.png-449ac783735384f2465771c25c401693.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/effects/explode/Explode_line0001.png" +dest_files=["res://.godot/imported/Explode_line0001.png-449ac783735384f2465771c25c401693.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_pit0001.png b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_pit0001.png new file mode 100644 index 0000000..281d9ea --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_pit0001.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_pit0001.png.import b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_pit0001.png.import new file mode 100644 index 0000000..2536123 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/explode/Explode_pit0001.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://6p1iq7sgw8lt" +path="res://.godot/imported/Explode_pit0001.png-e0ae86a6c1b6531083be57c318c78f11.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/effects/explode/Explode_pit0001.png" +dest_files=["res://.godot/imported/Explode_pit0001.png-e0ae86a6c1b6531083be57c318c78f11.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/effects/weapon/ShotFire2.png b/DungeonShooting_Godot/resource/sprite/effects/weapon/ShotFire2.png new file mode 100644 index 0000000..2a6b618 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/weapon/ShotFire2.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/effects/weapon/ShotFire2.png.import b/DungeonShooting_Godot/resource/sprite/effects/weapon/ShotFire2.png.import new file mode 100644 index 0000000..109241d --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/effects/weapon/ShotFire2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cj8gb5dxnk8ov" +path="res://.godot/imported/ShotFire2.png-859bcfe4ad8b11b7eb348b8c54ee9e64.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/effects/weapon/ShotFire2.png" +dest_files=["res://.godot/imported/ShotFire2.png-859bcfe4ad8b11b7eb348b8c54ee9e64.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/shell/Shell0004.png b/DungeonShooting_Godot/resource/sprite/shell/Shell0004.png new file mode 100644 index 0000000..c707ae5 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/shell/Shell0004.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/shell/Shell0004.png.import b/DungeonShooting_Godot/resource/sprite/shell/Shell0004.png.import new file mode 100644 index 0000000..fea12d1 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/shell/Shell0004.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://17htwakoupb2" +path="res://.godot/imported/Shell0004.png-c15276d49808c180fa5762fdca11586e.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/shell/Shell0004.png" +dest_files=["res://.godot/imported/Shell0004.png-c15276d49808c180fa5762fdca11586e.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/shell/shellCase.aseprite b/DungeonShooting_Godot/resource/sprite/shell/shellCase.aseprite deleted file mode 100644 index fe6c181..0000000 --- a/DungeonShooting_Godot/resource/sprite/shell/shellCase.aseprite +++ /dev/null Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008.png b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008.png new file mode 100644 index 0000000..47a67d9 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008.png.import b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008.png.import new file mode 100644 index 0000000..ca03629 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cb0n1btxc6wl6" +path="res://.godot/imported/Weapon0008.png-1420c47ea7cc621ba17c45723577d760.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/weapon/weapon0008/Weapon0008.png" +dest_files=["res://.godot/imported/Weapon0008.png-1420c47ea7cc621ba17c45723577d760.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008_reloading.png b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008_reloading.png new file mode 100644 index 0000000..7b3870e --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008_reloading.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008_reloading.png.import b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008_reloading.png.import new file mode 100644 index 0000000..87166a7 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0008/Weapon0008_reloading.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://h2jpooksm65e" +path="res://.godot/imported/Weapon0008_reloading.png-528bf1e7471ece4bfb129941ff134e83.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/weapon/weapon0008/Weapon0008_reloading.png" +dest_files=["res://.godot/imported/Weapon0008_reloading.png-528bf1e7471ece4bfb129941ff134e83.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/Weapon0009_reload.png b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/Weapon0009_reload.png new file mode 100644 index 0000000..e2d8ce4 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/Weapon0009_reload.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/Weapon0009_reload.png.import b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/Weapon0009_reload.png.import new file mode 100644 index 0000000..25ceb9b --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/Weapon0009_reload.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bvw6batqb8dv8" +path="res://.godot/imported/Weapon0009_reload.png-db2c0eea5342ef19729a52cc3bde8e8d.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/weapon/weapon0009/Weapon0009_reload.png" +dest_files=["res://.godot/imported/Weapon0009_reload.png-db2c0eea5342ef19729a52cc3bde8e8d.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/weapon0009.png b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/weapon0009.png new file mode 100644 index 0000000..35ed6f4 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/weapon0009.png Binary files differ diff --git a/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/weapon0009.png.import b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/weapon0009.png.import new file mode 100644 index 0000000..f19320c --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/weapon/weapon0009/weapon0009.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://qd7hufitblaf" +path="res://.godot/imported/weapon0009.png-f160d5b5d752036e5597a2e48024e6b3.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/weapon/weapon0009/weapon0009.png" +dest_files=["res://.godot/imported/weapon0009.png-f160d5b5d752036e5597a2e48024e6b3.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0001.tres b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0001.tres index b8cfbc6..990889c 100644 --- a/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0001.tres +++ b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0001.tres @@ -1,6 +1,7 @@ [gd_resource type="SpriteFrames" load_steps=2 format=3 uid="uid://baoxep7vami72"] -[ext_resource type="Texture2D" uid="uid://bu0b11hiuecxy" path="res://resource/sprite/bullet/bullet0001.png" id="1_ktu7r"] +[ext_resource type="Texture2D" uid="uid://bu0b11hiuecxy" path="res://resource/sprite/bullet/normal/bullet0001.png" id="1_ktu7r"] + [resource] diff --git a/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0002.tres b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0002.tres index 635a03b..140018b 100644 --- a/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0002.tres +++ b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0002.tres @@ -1,6 +1,7 @@ [gd_resource type="SpriteFrames" load_steps=2 format=3 uid="uid://bpeodjqiy3mil"] -[ext_resource type="Texture2D" uid="uid://ctsvj4y1t538u" path="res://resource/sprite/bullet/bullet0002.png" id="1_53f3g"] +[ext_resource type="Texture2D" uid="uid://ctsvj4y1t538u" path="res://resource/sprite/bullet/normal/bullet0002.png" id="1_53f3g"] + [resource] animations = [{ diff --git a/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0003.tres b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0003.tres index 2e724e8..79e09eb 100644 --- a/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0003.tres +++ b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0003.tres @@ -1,6 +1,7 @@ [gd_resource type="SpriteFrames" load_steps=2 format=3 uid="uid://bcnhyin0aufl1"] -[ext_resource type="Texture2D" uid="uid://cs6pa7h8ffvy4" path="res://resource/sprite/bullet/bullet0003.png" id="1_sl01e"] +[ext_resource type="Texture2D" uid="uid://cs6pa7h8ffvy4" path="res://resource/sprite/bullet/normal/bullet0003.png" id="1_sl01e"] + [resource] animations = [{ diff --git a/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0004.tres b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0004.tres new file mode 100644 index 0000000..8ca35b7 --- /dev/null +++ b/DungeonShooting_Godot/resource/spriteFrames/bullet/Bullet0004.tres @@ -0,0 +1,86 @@ +[gd_resource type="SpriteFrames" load_steps=12 format=3 uid="uid://d3vma1qjo478l"] + +[ext_resource type="Texture2D" uid="uid://c25xd887txviq" path="res://resource/sprite/bullet/normal/bullet0004.png" id="1_qrd7l"] + +[sub_resource type="AtlasTexture" id="AtlasTexture_q5ryk"] +atlas = ExtResource("1_qrd7l") +region = Rect2(0, 0, 5, 5) + +[sub_resource type="AtlasTexture" id="AtlasTexture_k2jqk"] +atlas = ExtResource("1_qrd7l") +region = Rect2(0, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_p5if5"] +atlas = ExtResource("1_qrd7l") +region = Rect2(7, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_a88dp"] +atlas = ExtResource("1_qrd7l") +region = Rect2(14, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ewrr5"] +atlas = ExtResource("1_qrd7l") +region = Rect2(21, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_imjsl"] +atlas = ExtResource("1_qrd7l") +region = Rect2(28, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_rkdnv"] +atlas = ExtResource("1_qrd7l") +region = Rect2(35, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_hdnbo"] +atlas = ExtResource("1_qrd7l") +region = Rect2(42, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_l6nrt"] +atlas = ExtResource("1_qrd7l") +region = Rect2(49, 0, 7, 7) + +[sub_resource type="AtlasTexture" id="AtlasTexture_h6vsu"] +atlas = ExtResource("1_qrd7l") +region = Rect2(56, 0, 7, 7) + +[resource] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": SubResource("AtlasTexture_q5ryk") +}], +"loop": true, +"name": &"default", +"speed": 5.0 +}, { +"frames": [{ +"duration": 1.0, +"texture": SubResource("AtlasTexture_k2jqk") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_p5if5") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_a88dp") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ewrr5") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_imjsl") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_rkdnv") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_hdnbo") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_l6nrt") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_h6vsu") +}], +"loop": true, +"name": &"move", +"speed": 10.0 +}] diff --git a/DungeonShooting_Godot/resource/spriteFrames/shell/Shell0004.tres b/DungeonShooting_Godot/resource/spriteFrames/shell/Shell0004.tres new file mode 100644 index 0000000..f1bd70c --- /dev/null +++ b/DungeonShooting_Godot/resource/spriteFrames/shell/Shell0004.tres @@ -0,0 +1,14 @@ +[gd_resource type="SpriteFrames" load_steps=2 format=3 uid="uid://b8b0ye3iv1vwp"] + +[ext_resource type="Texture2D" uid="uid://17htwakoupb2" path="res://resource/sprite/shell/Shell0004.png" id="1_mpyi3"] + +[resource] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": ExtResource("1_mpyi3") +}], +"loop": true, +"name": &"default", +"speed": 5.0 +}] diff --git a/DungeonShooting_Godot/resource/spriteFrames/weapon/Weapon0008.tres b/DungeonShooting_Godot/resource/spriteFrames/weapon/Weapon0008.tres new file mode 100644 index 0000000..1dfc8d7 --- /dev/null +++ b/DungeonShooting_Godot/resource/spriteFrames/weapon/Weapon0008.tres @@ -0,0 +1,153 @@ +[gd_resource type="SpriteFrames" load_steps=22 format=3 uid="uid://b2wpy40adyjs6"] + +[ext_resource type="Texture2D" uid="uid://cb0n1btxc6wl6" path="res://resource/sprite/weapon/weapon0008/Weapon0008.png" id="1_bwp4b"] +[ext_resource type="Texture2D" uid="uid://h2jpooksm65e" path="res://resource/sprite/weapon/weapon0008/Weapon0008_reloading.png" id="2_gep5m"] + +[sub_resource type="AtlasTexture" id="AtlasTexture_u0g6k"] +atlas = ExtResource("2_gep5m") +region = Rect2(0, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_c4u1l"] +atlas = ExtResource("2_gep5m") +region = Rect2(20, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_8gghd"] +atlas = ExtResource("2_gep5m") +region = Rect2(40, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_a47tr"] +atlas = ExtResource("2_gep5m") +region = Rect2(60, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_tw6v8"] +atlas = ExtResource("2_gep5m") +region = Rect2(80, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_jgrsc"] +atlas = ExtResource("2_gep5m") +region = Rect2(100, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_y0oy8"] +atlas = ExtResource("2_gep5m") +region = Rect2(120, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_kdd0i"] +atlas = ExtResource("2_gep5m") +region = Rect2(140, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_hln2b"] +atlas = ExtResource("2_gep5m") +region = Rect2(160, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_8gvf4"] +atlas = ExtResource("2_gep5m") +region = Rect2(180, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_6jcnt"] +atlas = ExtResource("2_gep5m") +region = Rect2(200, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_6slrt"] +atlas = ExtResource("2_gep5m") +region = Rect2(220, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_3if6d"] +atlas = ExtResource("2_gep5m") +region = Rect2(240, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_5x4hi"] +atlas = ExtResource("2_gep5m") +region = Rect2(260, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ot2rb"] +atlas = ExtResource("2_gep5m") +region = Rect2(280, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_3djuj"] +atlas = ExtResource("2_gep5m") +region = Rect2(300, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_83gjo"] +atlas = ExtResource("2_gep5m") +region = Rect2(320, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_hlvls"] +atlas = ExtResource("2_gep5m") +region = Rect2(340, 0, 20, 14) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ol1l8"] +atlas = ExtResource("2_gep5m") +region = Rect2(360, 0, 20, 14) + +[resource] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": ExtResource("1_bwp4b") +}], +"loop": true, +"name": &"default", +"speed": 5.0 +}, { +"frames": [{ +"duration": 1.0, +"texture": SubResource("AtlasTexture_u0g6k") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_c4u1l") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_8gghd") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_a47tr") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_tw6v8") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_jgrsc") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_y0oy8") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_kdd0i") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_hln2b") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_8gvf4") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_6jcnt") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_6slrt") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_3if6d") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_5x4hi") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ot2rb") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_3djuj") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_83gjo") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_hlvls") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ol1l8") +}], +"loop": false, +"name": &"reloading", +"speed": 11.0 +}] diff --git a/DungeonShooting_Godot/resource/spriteFrames/weapon/Weapon0009.tres b/DungeonShooting_Godot/resource/spriteFrames/weapon/Weapon0009.tres new file mode 100644 index 0000000..987a1d4 --- /dev/null +++ b/DungeonShooting_Godot/resource/spriteFrames/weapon/Weapon0009.tres @@ -0,0 +1,55 @@ +[gd_resource type="SpriteFrames" load_steps=8 format=3 uid="uid://c0xwj3kpk02ua"] + +[ext_resource type="Texture2D" uid="uid://qd7hufitblaf" path="res://resource/sprite/weapon/weapon0009/weapon0009.png" id="1_kidjv"] +[ext_resource type="Texture2D" uid="uid://bvw6batqb8dv8" path="res://resource/sprite/weapon/weapon0009/Weapon0009_reload.png" id="2_3282c"] + +[sub_resource type="AtlasTexture" id="AtlasTexture_isstj"] +atlas = ExtResource("2_3282c") +region = Rect2(0, 0, 32, 24) + +[sub_resource type="AtlasTexture" id="AtlasTexture_6v16h"] +atlas = ExtResource("2_3282c") +region = Rect2(32, 0, 32, 24) + +[sub_resource type="AtlasTexture" id="AtlasTexture_jjjl6"] +atlas = ExtResource("2_3282c") +region = Rect2(64, 0, 32, 24) + +[sub_resource type="AtlasTexture" id="AtlasTexture_nykj1"] +atlas = ExtResource("2_3282c") +region = Rect2(96, 0, 32, 24) + +[sub_resource type="AtlasTexture" id="AtlasTexture_6s7uc"] +atlas = ExtResource("2_3282c") +region = Rect2(128, 0, 32, 24) + +[resource] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": ExtResource("1_kidjv") +}], +"loop": false, +"name": &"default", +"speed": 5.0 +}, { +"frames": [{ +"duration": 1.0, +"texture": SubResource("AtlasTexture_isstj") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_6v16h") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_jjjl6") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_nykj1") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_6s7uc") +}], +"loop": true, +"name": &"reloading_frame", +"speed": 5.0 +}] diff --git a/DungeonShooting_Godot/scene/Main.tscn b/DungeonShooting_Godot/scene/Main.tscn index 877b1ff..080a8f2 100644 --- a/DungeonShooting_Godot/scene/Main.tscn +++ b/DungeonShooting_Godot/scene/Main.tscn @@ -47,8 +47,6 @@ [node name="SceneRoot" type="Node2D" parent="ViewCanvas/SubViewportContainer/SubViewport"] [node name="Camera2D" type="Camera2D" parent="ViewCanvas/SubViewportContainer/SubViewport"] -process_callback = 0 -limit_smoothed = true editor_draw_drag_margin = true script = ExtResource("2_2j367") diff --git a/DungeonShooting_Godot/scene/World.tscn b/DungeonShooting_Godot/scene/World.tscn index 69e07d3..76eca4e 100644 --- a/DungeonShooting_Godot/scene/World.tscn +++ b/DungeonShooting_Godot/scene/World.tscn @@ -10,7 +10,6 @@ glow_blend_mode = 1 [node name="World" type="CanvasModulate" node_paths=PackedStringArray("NormalLayer", "YSortLayer", "TileRoot", "StaticSpriteRoot", "AffiliationAreaRoot", "FogMaskRoot")] -color = Color(0, 0, 0, 1) script = ExtResource("1_kt3mm") NormalLayer = NodePath("NormalLayer") YSortLayer = NodePath("YSortLayer") @@ -33,6 +32,7 @@ layer_1/y_sort_enabled = false layer_1/y_sort_origin = 0 layer_1/z_index = 0 +layer_1/navigation_enabled = true layer_1/tile_data = PackedInt32Array() layer_2/name = "Top" layer_2/enabled = true @@ -40,6 +40,7 @@ layer_2/y_sort_enabled = false layer_2/y_sort_origin = 0 layer_2/z_index = 10 +layer_2/navigation_enabled = true layer_2/tile_data = PackedInt32Array() layer_3/name = "AisleFloor" layer_3/enabled = true @@ -47,6 +48,7 @@ layer_3/y_sort_enabled = false layer_3/y_sort_origin = 0 layer_3/z_index = -10 +layer_3/navigation_enabled = true layer_3/tile_data = PackedInt32Array() [node name="StaticSpriteRoot" type="Node2D" parent="."] diff --git a/DungeonShooting_Godot/scene/test/TestCommpont.tscn b/DungeonShooting_Godot/scene/test/TestCommpont.tscn deleted file mode 100644 index 8594977..0000000 --- a/DungeonShooting_Godot/scene/test/TestCommpont.tscn +++ /dev/null @@ -1,10 +0,0 @@ -[gd_scene load_steps=2 format=3 uid="uid://chgfadxc8pqr4"] - -[ext_resource type="Texture2D" uid="uid://uhhfgdhpk7i4" path="res://icon.png" id="1"] - -[node name="Node2D" type="Node2D"] - -[node name="Sprite2D" type="Sprite2D" parent="."] -position = Vector2(200, 102) -scale = Vector2(0.3, 0.3) -texture = ExtResource("1") diff --git a/DungeonShooting_Godot/scene/test/TestDrawSprite.tscn b/DungeonShooting_Godot/scene/test/TestDrawSprite.tscn new file mode 100644 index 0000000..a777b39 --- /dev/null +++ b/DungeonShooting_Godot/scene/test/TestDrawSprite.tscn @@ -0,0 +1,31 @@ +[gd_scene load_steps=3 format=3 uid="uid://gby5bfwuu4kx"] + +[ext_resource type="Script" path="res://src/test/TestDrawSprite.cs" id="1_tplub"] + +[sub_resource type="Curve2D" id="Curve2D_ft6ap"] +_data = { +"points": PackedVector2Array(0, 0, 0, 0, 29, 41, 0, 0, 0, 0, 1547, 34, 0, 0, 0, 0, 1544, 863, 0, 0, 0, 0, 39, 848, 0, 0, 0, 0, 828, 387, 0, 0, 0, 0, 42, 54) +} +point_count = 6 + +[node name="TestDrawSprite" type="Node2D" node_paths=PackedStringArray("FpsLabel", "PathFollow2D")] +script = ExtResource("1_tplub") +FpsLabel = NodePath("CanvasLayer/Fps") +PathFollow2D = NodePath("Path2D/PathFollow2D") + +[node name="CanvasLayer" type="CanvasLayer" parent="."] + +[node name="Fps" type="Label" parent="CanvasLayer"] +offset_left = 34.0 +offset_top = 31.0 +offset_right = 43.0 +offset_bottom = 71.0 + +[node name="Path2D" type="Path2D" parent="."] +curve = SubResource("Curve2D_ft6ap") + +[node name="PathFollow2D" type="PathFollow2D" parent="Path2D"] +position = Vector2(29, 41) +rotation = -0.0046113 + +[node name="Camera2D" type="Camera2D" parent="Path2D/PathFollow2D"] diff --git a/DungeonShooting_Godot/scene/test/TestExpression.tscn b/DungeonShooting_Godot/scene/test/TestExpression.tscn deleted file mode 100644 index 13731e2..0000000 --- a/DungeonShooting_Godot/scene/test/TestExpression.tscn +++ /dev/null @@ -1,9 +0,0 @@ -[gd_scene load_steps=2 format=3 uid="uid://blp7bo6tyoqlr"] - -[ext_resource type="Script" path="res://src/test/TestExpression.cs" id="1_qmchi"] - -[node name="TestExpression" type="Node2D"] -script = ExtResource("1_qmchi") -Str = "0003; -0001(w:100,ca:15,ra:30); -0002(w:120,ca:10,ra:20);" diff --git a/DungeonShooting_Godot/scene/test/TestGenerateDungeon.tscn b/DungeonShooting_Godot/scene/test/TestGenerateDungeon.tscn deleted file mode 100644 index 2b694f5..0000000 --- a/DungeonShooting_Godot/scene/test/TestGenerateDungeon.tscn +++ /dev/null @@ -1,46 +0,0 @@ -[gd_scene load_steps=5 format=3 uid="uid://5bbx1u0od3jm"] - -[ext_resource type="Script" path="res://src/test/TestGenerateDungeon.cs" id="1"] -[ext_resource type="Texture2D" uid="uid://dj8nrd5od4fcl" path="res://resource/map/tileSprite/map1/16x16 dungeon ii wall reconfig v04 spritesheet.png" id="2"] - - - -[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_rvg0t"] -texture = ExtResource("2") -margins = Vector2i(0, 128) -0:0/next_alternative_id = 8 -0:0/0 = 0 -0:0/1 = 1 -0:0/1/flip_h = true -0:0/2 = 2 -0:0/2/flip_v = true -0:0/3 = 3 -0:0/3/flip_h = true -0:0/3/flip_v = true -0:0/4 = 4 -0:0/4/transpose = true -0:0/5 = 5 -0:0/5/flip_h = true -0:0/5/transpose = true -0:0/6 = 6 -0:0/6/flip_v = true -0:0/6/transpose = true -0:0/7 = 7 -0:0/7/flip_h = true -0:0/7/flip_v = true -0:0/7/transpose = true - -[sub_resource type="TileSet" id="1"] -sources/0 = SubResource("TileSetAtlasSource_rvg0t") - -[node name="TestGenerateDungeon" type="Node2D"] -script = ExtResource("1") -TileMapPath = NodePath("TileMap") -Camera3D = NodePath("Camera2D") - -[node name="Camera2D" type="Camera2D" parent="."] - -[node name="TileMap" type="TileMap" parent="."] -z_index = -1 -tile_set = SubResource("1") -format = 2 diff --git a/DungeonShooting_Godot/scene/test/TestGridData.tscn b/DungeonShooting_Godot/scene/test/TestGridData.tscn new file mode 100644 index 0000000..9f00647 --- /dev/null +++ b/DungeonShooting_Godot/scene/test/TestGridData.tscn @@ -0,0 +1,6 @@ +[gd_scene load_steps=2 format=3 uid="uid://b4lwq3384y6c1"] + +[ext_resource type="Script" path="res://src/test/TestGridData.cs" id="1_jtgxu"] + +[node name="TestGridData" type="Node2D"] +script = ExtResource("1_jtgxu") diff --git a/DungeonShooting_Godot/scene/test/TestReadExcel.tscn b/DungeonShooting_Godot/scene/test/TestReadExcel.tscn deleted file mode 100644 index 1ab48cd..0000000 --- a/DungeonShooting_Godot/scene/test/TestReadExcel.tscn +++ /dev/null @@ -1,6 +0,0 @@ -[gd_scene load_steps=2 format=3 uid="uid://deq562id5sngp"] - -[ext_resource type="Script" path="res://src/test/TestReadExcel.cs" id="1_y8vrr"] - -[node name="TestReadExcel" type="Node2D"] -script = ExtResource("1_y8vrr") diff --git a/DungeonShooting_Godot/src/config/ExcelConfig.cs b/DungeonShooting_Godot/src/config/ExcelConfig.cs index 6416ead..f9d7eaf 100644 --- a/DungeonShooting_Godot/src/config/ExcelConfig.cs +++ b/DungeonShooting_Godot/src/config/ExcelConfig.cs @@ -8,13 +8,22 @@ public static partial class ExcelConfig { /// - /// ActivityObject.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 + /// ActivityBase.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 /// - public static List ActivityObject_List { get; private set; } + public static List ActivityBase_List { get; private set; } /// - /// ActivityObject.xlsx表数据集合, 里 Map 形式存储, key 为 Id + /// ActivityBase.xlsx表数据集合, 里 Map 形式存储, key 为 Id /// - public static Dictionary ActivityObject_Map { get; private set; } + public static Dictionary ActivityBase_Map { get; private set; } + + /// + /// ActivityMaterial.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 + /// + public static List ActivityMaterial_List { get; private set; } + /// + /// ActivityMaterial.xlsx表数据集合, 里 Map 形式存储, key 为 Id + /// + public static Dictionary ActivityMaterial_Map { get; private set; } /// /// AiAttackAttr.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 @@ -26,6 +35,15 @@ public static Dictionary AiAttackAttr_Map { get; private set; } /// + /// BulletBase.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 + /// + public static List BulletBase_List { get; private set; } + /// + /// BulletBase.xlsx表数据集合, 里 Map 形式存储, key 为 Id + /// + public static Dictionary BulletBase_Map { get; private set; } + + /// /// Sound.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 /// public static List Sound_List { get; private set; } @@ -35,13 +53,13 @@ public static Dictionary Sound_Map { get; private set; } /// - /// Weapon.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 + /// WeaponBase.xlsx表数据集合, 以 List 形式存储, 数据顺序与 Excel 表相同 /// - public static List Weapon_List { get; private set; } + public static List WeaponBase_List { get; private set; } /// - /// Weapon.xlsx表数据集合, 里 Map 形式存储, key 为 Id + /// WeaponBase.xlsx表数据集合, 里 Map 形式存储, key 为 Id /// - public static Dictionary Weapon_Map { get; private set; } + public static Dictionary WeaponBase_Map { get; private set; } private static bool _init = false; @@ -53,29 +71,50 @@ if (_init) return; _init = true; - _InitActivityObjectConfig(); + _InitActivityBaseConfig(); + _InitActivityMaterialConfig(); _InitAiAttackAttrConfig(); + _InitBulletBaseConfig(); _InitSoundConfig(); - _InitWeaponConfig(); + _InitWeaponBaseConfig(); - _InitWeaponRef(); + _InitActivityBaseRef(); + _InitWeaponBaseRef(); } - private static void _InitActivityObjectConfig() + private static void _InitActivityBaseConfig() { try { - var text = _ReadConfigAsText("res://resource/config/ActivityObject.json"); - ActivityObject_List = JsonSerializer.Deserialize>(text); - ActivityObject_Map = new Dictionary(); - foreach (var item in ActivityObject_List) + var text = _ReadConfigAsText("res://resource/config/ActivityBase.json"); + ActivityBase_List = new List(JsonSerializer.Deserialize>(text)); + ActivityBase_Map = new Dictionary(); + foreach (var item in ActivityBase_List) { - ActivityObject_Map.Add(item.Id, item); + ActivityBase_Map.Add(item.Id, item); } } catch (Exception e) { GD.PrintErr(e.ToString()); - throw new Exception("初始化表'ActivityObject'失败!"); + throw new Exception("初始化表'ActivityBase'失败!"); + } + } + private static void _InitActivityMaterialConfig() + { + try + { + var text = _ReadConfigAsText("res://resource/config/ActivityMaterial.json"); + ActivityMaterial_List = JsonSerializer.Deserialize>(text); + ActivityMaterial_Map = new Dictionary(); + foreach (var item in ActivityMaterial_List) + { + ActivityMaterial_Map.Add(item.Id, item); + } + } + catch (Exception e) + { + GD.PrintErr(e.ToString()); + throw new Exception("初始化表'ActivityMaterial'失败!"); } } private static void _InitAiAttackAttrConfig() @@ -96,6 +135,24 @@ throw new Exception("初始化表'AiAttackAttr'失败!"); } } + private static void _InitBulletBaseConfig() + { + try + { + var text = _ReadConfigAsText("res://resource/config/BulletBase.json"); + BulletBase_List = JsonSerializer.Deserialize>(text); + BulletBase_Map = new Dictionary(); + foreach (var item in BulletBase_List) + { + BulletBase_Map.Add(item.Id, item); + } + } + catch (Exception e) + { + GD.PrintErr(e.ToString()); + throw new Exception("初始化表'BulletBase'失败!"); + } + } private static void _InitSoundConfig() { try @@ -114,31 +171,65 @@ throw new Exception("初始化表'Sound'失败!"); } } - private static void _InitWeaponConfig() + private static void _InitWeaponBaseConfig() { try { - var text = _ReadConfigAsText("res://resource/config/Weapon.json"); - Weapon_List = new List(JsonSerializer.Deserialize>(text)); - Weapon_Map = new Dictionary(); - foreach (var item in Weapon_List) + var text = _ReadConfigAsText("res://resource/config/WeaponBase.json"); + WeaponBase_List = new List(JsonSerializer.Deserialize>(text)); + WeaponBase_Map = new Dictionary(); + foreach (var item in WeaponBase_List) { - Weapon_Map.Add(item.Id, item); + WeaponBase_Map.Add(item.Id, item); } } catch (Exception e) { GD.PrintErr(e.ToString()); - throw new Exception("初始化表'Weapon'失败!"); + throw new Exception("初始化表'WeaponBase'失败!"); } } - private static void _InitWeaponRef() + private static void _InitActivityBaseRef() { - foreach (Ref_Weapon item in Weapon_List) + foreach (Ref_ActivityBase item in ActivityBase_List) { try { + if (!string.IsNullOrEmpty(item.__Material)) + { + item.Material = ActivityMaterial_Map[item.__Material]; + } + + } + catch (Exception e) + { + GD.PrintErr(e.ToString()); + throw new Exception("初始化'ActivityBase'引用其他表数据失败, 当前行id: " + item.Id); + } + } + } + private static void _InitWeaponBaseRef() + { + foreach (Ref_WeaponBase item in WeaponBase_List) + { + try + { + if (!string.IsNullOrEmpty(item.__Activity)) + { + item.Activity = ActivityBase_Map[item.__Activity]; + } + + if (!string.IsNullOrEmpty(item.__Bullet)) + { + item.Bullet = BulletBase_Map[item.__Bullet]; + } + + if (!string.IsNullOrEmpty(item.__Shell)) + { + item.Shell = ActivityBase_Map[item.__Shell]; + } + if (!string.IsNullOrEmpty(item.__ShootSound)) { item.ShootSound = Sound_Map[item.__ShootSound]; @@ -175,7 +266,7 @@ if (!string.IsNullOrEmpty(item.__AiUseAttribute)) { - item.AiUseAttribute = Weapon_Map[item.__AiUseAttribute]; + item.AiUseAttribute = WeaponBase_Map[item.__AiUseAttribute]; } if (!string.IsNullOrEmpty(item.__AiAttackAttr)) @@ -187,7 +278,7 @@ catch (Exception e) { GD.PrintErr(e.ToString()); - throw new Exception("初始化'Weapon'引用其他表数据失败, 当前行id: " + item.Id); + throw new Exception("初始化'WeaponBase'引用其他表数据失败, 当前行id: " + item.Id); } } } diff --git a/DungeonShooting_Godot/src/config/ExcelConfig_ActivityBase.cs b/DungeonShooting_Godot/src/config/ExcelConfig_ActivityBase.cs new file mode 100644 index 0000000..76d7bfb --- /dev/null +++ b/DungeonShooting_Godot/src/config/ExcelConfig_ActivityBase.cs @@ -0,0 +1,107 @@ +using System.Text.Json.Serialization; +using System.Collections.Generic; + +namespace Config; + +public static partial class ExcelConfig +{ + public class ActivityBase + { + /// + /// 物体唯一id
+ /// 需要添加类型前缀 + ///
+ [JsonInclude] + public string Id; + + /// + /// Test(测试对象): 2
+ /// Role(角色): 3
+ /// Enemy(敌人): 4
+ /// Weapon(武器): 5
+ /// Bullet(子弹): 6
+ /// Shell(弹壳): 7
+ /// Effect(特效): 8
+ /// Prop(道具): 9
+ /// Other(其它类型): 99 + ///
+ [JsonInclude] + public int Type; + + /// + /// 物体名称 + /// + [JsonInclude] + public string Name; + + /// + /// 物体简介
+ /// 一句对物体简短的介绍, 比如拾起物体时弹出的描述 + ///
+ [JsonInclude] + public string Intro; + + /// + /// 物体详情
+ /// 在图鉴中的描述 + ///
+ [JsonInclude] + public string Details; + + /// + /// 是否是静态物体 + /// + [JsonInclude] + public bool IsStatic; + + /// + /// 物体使用交互材质
+ /// 如果不填,则默认使用id为0001的材质 + ///
+ public ActivityMaterial Material; + + /// + /// 物体预制场景路径, 场景根节点必须是ActivityObject子类 + /// + [JsonInclude] + public string Prefab; + + /// + /// 物体图标
+ /// 如果不需要在图鉴或者地图编辑器中显示该物体, 则可以不用设置 + ///
+ [JsonInclude] + public string Icon; + + /// + /// 是否在地图编辑器中显示该物体 + /// + [JsonInclude] + public bool ShowInMapEditor; + + /// + /// 返回浅拷贝出的新对象 + /// + public ActivityBase Clone() + { + var inst = new ActivityBase(); + inst.Id = Id; + inst.Type = Type; + inst.Name = Name; + inst.Intro = Intro; + inst.Details = Details; + inst.IsStatic = IsStatic; + inst.Material = Material; + inst.Prefab = Prefab; + inst.Icon = Icon; + inst.ShowInMapEditor = ShowInMapEditor; + return inst; + } + } + private class Ref_ActivityBase : ActivityBase + { + [JsonInclude] + public string __Material; + + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/config/ExcelConfig_ActivityMaterial.cs b/DungeonShooting_Godot/src/config/ExcelConfig_ActivityMaterial.cs new file mode 100644 index 0000000..d0d756b --- /dev/null +++ b/DungeonShooting_Godot/src/config/ExcelConfig_ActivityMaterial.cs @@ -0,0 +1,82 @@ +using System.Text.Json.Serialization; +using System.Collections.Generic; + +namespace Config; + +public static partial class ExcelConfig +{ + public class ActivityMaterial + { + /// + /// 表Id + /// + [JsonInclude] + public string Id; + + /// + /// 备注 + /// + [JsonInclude] + public string Remark; + + /// + /// 摩擦力 + /// + [JsonInclude] + public float Friction; + + /// + /// 旋转摩擦力 + /// + [JsonInclude] + public float RotationFriction; + + /// + /// 落地之后是否回弹 + /// + [JsonInclude] + public bool Bounce; + + /// + /// 物体水平回弹强度 + /// + [JsonInclude] + public float BounceStrength; + + /// + /// 物体下坠回弹的强度 + /// + [JsonInclude] + public float FallBounceStrength; + + /// + /// 物体下坠回弹后的运动速度衰比例 + /// + [JsonInclude] + public float FallBounceSpeed; + + /// + /// 物体下坠回弹后的旋转速度衰减比例 + /// + [JsonInclude] + public float FallBounceRotation; + + /// + /// 返回浅拷贝出的新对象 + /// + public ActivityMaterial Clone() + { + var inst = new ActivityMaterial(); + inst.Id = Id; + inst.Remark = Remark; + inst.Friction = Friction; + inst.RotationFriction = RotationFriction; + inst.Bounce = Bounce; + inst.BounceStrength = BounceStrength; + inst.FallBounceStrength = FallBounceStrength; + inst.FallBounceSpeed = FallBounceSpeed; + inst.FallBounceRotation = FallBounceRotation; + return inst; + } + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/config/ExcelConfig_ActivityObject.cs b/DungeonShooting_Godot/src/config/ExcelConfig_ActivityObject.cs deleted file mode 100644 index 1d3dbe4..0000000 --- a/DungeonShooting_Godot/src/config/ExcelConfig_ActivityObject.cs +++ /dev/null @@ -1,87 +0,0 @@ -using System.Text.Json.Serialization; -using System.Collections.Generic; - -namespace Config; - -public static partial class ExcelConfig -{ - public class ActivityObject - { - /// - /// 物体唯一id
- /// 需要添加类型前缀 - ///
- [JsonInclude] - public string Id; - - /// - /// Test(测试对象): 2
- /// Role(角色): 3
- /// Enemy(敌人): 4
- /// Weapon(武器): 5
- /// Bullet(子弹): 6
- /// Shell(弹壳): 7
- /// Effect(特效): 8
- /// Prop(道具): 9
- /// Other(其它类型): 99 - ///
- [JsonInclude] - public int Type; - - /// - /// 物体名称 - /// - [JsonInclude] - public string Name; - - /// - /// 物体简介
- /// 一句对物体简短的介绍, 比如拾起物体时弹出的描述 - ///
- [JsonInclude] - public string Intro; - - /// - /// 物体详情
- /// 在图鉴中的描述 - ///
- [JsonInclude] - public string Details; - - /// - /// 物体预制场景路径, 场景根节点必须是ActivityObject子类 - /// - [JsonInclude] - public string Prefab; - - /// - /// 物体图标
- /// 如果不需要在图鉴或者地图编辑器中显示该物体, 则可以不用设置 - ///
- [JsonInclude] - public string Icon; - - /// - /// 是否在地图编辑器中显示该物体 - /// - [JsonInclude] - public bool ShowInMapEditor; - - /// - /// 返回浅拷贝出的新对象 - /// - public ActivityObject Clone() - { - var inst = new ActivityObject(); - inst.Id = Id; - inst.Type = Type; - inst.Name = Name; - inst.Intro = Intro; - inst.Details = Details; - inst.Prefab = Prefab; - inst.Icon = Icon; - inst.ShowInMapEditor = ShowInMapEditor; - return inst; - } - } -} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/config/ExcelConfig_BulletBase.cs b/DungeonShooting_Godot/src/config/ExcelConfig_BulletBase.cs new file mode 100644 index 0000000..0f0dcb0 --- /dev/null +++ b/DungeonShooting_Godot/src/config/ExcelConfig_BulletBase.cs @@ -0,0 +1,138 @@ +using System.Text.Json.Serialization; +using System.Collections.Generic; + +namespace Config; + +public static partial class ExcelConfig +{ + public class BulletBase + { + /// + /// 子弹id + /// + [JsonInclude] + public string Id; + + /// + /// 子弹名称 + /// + [JsonInclude] + public string Name; + + /// + /// 子弹类型:
+ /// 实体子弹:1
+ /// 激光子弹:2
+ /// 纯伤害:3 + ///
+ [JsonInclude] + public int Type; + + /// + /// 绑定子弹预制体,根据Type填不同的参数
+ /// Type为1,填ActivityBase表Id
+ /// Type为2,填场景路径
+ /// Type为3,不填 + ///
+ [JsonInclude] + public string Prefab; + + /// + /// 造成的伤害区间
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public int[] HarmRange; + + /// + /// 造成伤害后击退值区间
+ /// 如果发射子弹,则按每发子弹算击退
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] RepelRnage; + + /// + /// 子弹偏移角度区间
+ /// 用于设置子弹偏移朝向, 该属性和射半径效果类似, 但与其不同的是, 散射半径是用来控制枪口朝向的, 而该属性是控制子弹朝向的, 可用于制作霰弹枪子弹效果
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] DeviationAngleRange; + + /// + /// 子弹初速度区间
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] SpeedRange; + + /// + /// 子弹最大存在时间,单位:秒
+ /// 如果值小于等于0时子弹无限期存在
+ /// 只有Type为1时才需要填写
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] LifeTimeRange; + + /// + /// 子弹最大飞行距离区间
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] DistanceRange; + + /// + /// 是否开启重力下坠
+ /// 只有Type为1时有效 + ///
+ [JsonInclude] + public bool UseGravity; + + /// + /// 初始纵轴速度区间
+ /// 只有Type为1时有效
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] VerticalSpeed; + + /// + /// 反弹次数区间
+ /// 只有Type为1或2时有效
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public int[] BounceCount; + + /// + /// 在还有剩余反弹次数时撞到玩家时是否销毁子弹 + /// + [JsonInclude] + public bool StrikeDestroy; + + /// + /// 返回浅拷贝出的新对象 + /// + public BulletBase Clone() + { + var inst = new BulletBase(); + inst.Id = Id; + inst.Name = Name; + inst.Type = Type; + inst.Prefab = Prefab; + inst.HarmRange = HarmRange; + inst.RepelRnage = RepelRnage; + inst.DeviationAngleRange = DeviationAngleRange; + inst.SpeedRange = SpeedRange; + inst.LifeTimeRange = LifeTimeRange; + inst.DistanceRange = DistanceRange; + inst.UseGravity = UseGravity; + inst.VerticalSpeed = VerticalSpeed; + inst.BounceCount = BounceCount; + inst.StrikeDestroy = StrikeDestroy; + return inst; + } + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/config/ExcelConfig_Weapon.cs b/DungeonShooting_Godot/src/config/ExcelConfig_Weapon.cs deleted file mode 100644 index c9dd584..0000000 --- a/DungeonShooting_Godot/src/config/ExcelConfig_Weapon.cs +++ /dev/null @@ -1,499 +0,0 @@ -using System.Text.Json.Serialization; -using System.Collections.Generic; - -namespace Config; - -public static partial class ExcelConfig -{ - public class Weapon - { - /// - /// 武器属性id - /// - [JsonInclude] - public string Id; - - /// - /// 属性绑定武器的Id,如果是Ai使用的数据, 则填空字符串串 - /// - [JsonInclude] - public string WeaponId; - - /// - /// 备注 - /// - [JsonInclude] - public string Remark; - - /// - /// 重量 - /// - [JsonInclude] - public float Weight; - - /// - /// 武器类型:
- /// 1.副武器
- /// 2.主武器
- /// 3.重型武器 - ///
- [JsonInclude] - public byte WeightType; - - /// - /// 是否连续发射, 如果为false, 则每次发射都需要扣动扳机 - /// - [JsonInclude] - public bool ContinuousShoot; - - /// - /// 弹夹容量 - /// - [JsonInclude] - public int AmmoCapacity; - - /// - /// 弹药容量上限 - /// - [JsonInclude] - public int MaxAmmoCapacity; - - /// - /// 默认起始备用弹药数量 - /// - [JsonInclude] - public int StandbyAmmoCapacity; - - /// - /// 装弹时间 (单位: 秒) - /// - [JsonInclude] - public float ReloadTime; - - /// - /// 每粒子弹是否是单独装填, 如果是, 那么每上一发子弹的时间就是 ReloadTime, 可以做霰弹枪装填效果 - /// - [JsonInclude] - public bool AloneReload; - - /// - /// 单独装填时每次装填子弹数量, 必须要将 'AloneReload' 属性设置为 true - /// - [JsonInclude] - public int AloneReloadCount; - - /// - /// 单独装弹模式下,从触发装弹到开始装第一发子弹中间的间隔时间, 必须要将 'AloneReload' 属性设置为 true - /// - [JsonInclude] - public float AloneReloadBeginIntervalTime; - - /// - /// 单独装弹模式下,从装完最后一发子弹到可以射击中间的间隔时间, 必须要将 'AloneReload' 属性设置为 true - /// - [JsonInclude] - public float AloneReloadFinishIntervalTime; - - /// - /// 单独装填的子弹时可以立即射击, 必须要将 'AloneReload' 属性设置为 true - /// - [JsonInclude] - public bool AloneReloadCanShoot; - - /// - /// 是否为松发开火, 也就是松开扳机才开火, 若要启用该属性, 必须将 'ContinuousShoot' 设置为 false - /// - [JsonInclude] - public bool LooseShoot; - - /// - /// 最少需要蓄力多久才能开火, 必须将 'LooseShoot' 设置为 true - /// - [JsonInclude] - public float MinChargeTime; - - /// - /// 单次射击后是否需要手动上膛动作, 必须将 'ContinuousShoot' 设置为 false - /// - [JsonInclude] - public bool ManualBeLoaded; - - /// - /// 手动上膛模式下, 单次射击后是否自动执行上膛操作, 必须将 'ManualBeLoaded' 设置为 true - /// - [JsonInclude] - public bool AutoManualBeLoaded; - - /// - /// 上膛时间, 如果时间为0, 则不会播放上膛动画和音效, 可以视为没有上膛动作, 必须将 'ManualBeLoaded' 设置为 true - /// - [JsonInclude] - public float BeLoadedTime; - - /// - /// 连续发射次数区间, 仅当 'ContinuousShoot' 为 false 时生效
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public int[] ContinuousCountRange; - - /// - /// 按下一次扳机后需要多长时间才能再次感应按下 - /// - [JsonInclude] - public float TriggerInterval; - - /// - /// 初始射速, 初始每分钟能开火次数 - /// - [JsonInclude] - public float StartFiringSpeed; - - /// - /// 最终射速, 最终每分钟能开火次数, 仅当 'ContinuousShoot' 为 true 时生效 - /// - [JsonInclude] - public float FinalFiringSpeed; - - /// - /// 按下扳机并开火后射速每秒增加量 - /// - [JsonInclude] - public float FiringSpeedAddSpeed; - - /// - /// 松开扳机后射速消散速率 - /// - [JsonInclude] - public float FiringSpeedBackSpeed; - - /// - /// 单次开火发射子弹数量区间
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public int[] FireBulletCountRange; - - /// - /// 从按下扳机到发射第一发子弹的延时时, 如果中途松开扳机, 那么延时时间会重新计算, 必须将 'LooseShoot' 设置为 false - /// - [JsonInclude] - public float DelayedTime; - - /// - /// 初始散射半径 - /// - [JsonInclude] - public float StartScatteringRange; - - /// - /// 最终散射半径 - /// - [JsonInclude] - public float FinalScatteringRange; - - /// - /// 每次发射后散射增加值 - /// - [JsonInclude] - public float ScatteringRangeAddValue; - - /// - /// 散射值销退速率 - /// - [JsonInclude] - public float ScatteringRangeBackSpeed; - - /// - /// 开始销退散射值的延时时间 - /// - [JsonInclude] - public float ScatteringRangeBackDelayTime; - - /// - /// 开火后相机抖动强度,只有玩家拾起武器开火才会抖动相机 - /// - [JsonInclude] - public float CameraShake; - - /// - /// 后坐力区间 (仅用于开火后武器身抖动)
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public float[] BacklashRange; - - /// - /// 后坐力偏移回归回归速度 - /// - [JsonInclude] - public float BacklashRegressionSpeed; - - /// - /// 开火后武器口上抬角度 - /// - [JsonInclude] - public float UpliftAngle; - - /// - /// 武器默认上抬角度 - /// - [JsonInclude] - public float DefaultAngle; - - /// - /// 开火后武器口角度恢复速度倍数 - /// - [JsonInclude] - public float UpliftAngleRestore; - - /// - /// 默认射出的子弹id - /// - [JsonInclude] - public string BulletId; - - /// - /// 造成的伤害区间
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public int[] HarmRange; - - /// - /// 造成伤害后击退值区间
- /// 如果发射子弹,则按每发子弹算击退
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public float[] RepelRnage; - - /// - /// 子弹偏移角度区间
- /// 用于设置子弹偏移朝向, 该属性和射半径效果类似, 但与其不同的是, 散射半径是用来控制枪口朝向的, 而该属性是控制子弹朝向的, 可用于制作霰弹枪子弹效果
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public float[] BulletDeviationAngleRange; - - /// - /// 子弹初速度区间
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public float[] BulletSpeedRange; - - /// - /// 子弹飞行距离区间
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public float[] BulletDistanceRange; - - /// - /// 默认抛出的弹壳 - /// - [JsonInclude] - public string ShellId; - - /// - /// 投抛弹壳的延时时间, 在射击或者上膛后会触发抛弹壳效果
- /// 如果为负数, 则不自动抛弹 - ///
- [JsonInclude] - public float ThrowShellDelayTime; - - /// - /// 投抛状态下物体碰撞器大小 - /// - [JsonInclude] - public SerializeVector2 ThrowCollisionSize; - - /// - /// 是否可以触发近战攻击 - /// - [JsonInclude] - public bool CanMeleeAttack; - - /// - /// 近战攻击伤害区间
- /// 格式为格式为[value]或者[min,max] - ///
- [JsonInclude] - public int[] MeleeAttackHarmRange; - - /// - /// 近战攻击造成伤害后击退值区间
- /// 格式为[value]或者[min,max] - ///
- [JsonInclude] - public float[] MeleeAttackRepelRnage; - - /// - /// 射击音效 - /// - public Sound ShootSound; - - /// - /// 开始换弹音效 - /// - public Sound BeginReloadSound; - - /// - /// 开始换弹音效延时时间 - /// - [JsonInclude] - public float BeginReloadSoundDelayTime; - - /// - /// 换弹音效 - /// - public Sound ReloadSound; - - /// - /// 换弹音效延时时间 - /// - [JsonInclude] - public float ReloadSoundDelayTime; - - /// - /// 换弹结束音效 - /// - public Sound ReloadFinishSound; - - /// - /// 换弹结束音效在换弹结束前多久开始
- /// 注意: 如果'AloneReload'为true, 那么当前属性的值应该小于'AloneReloadFinishIntervalTime' - ///
- [JsonInclude] - public float ReloadFinishSoundAdvanceTime; - - /// - /// 上膛音效 - /// - public Sound BeLoadedSound; - - /// - /// 上膛音效延时时间, 这个时间应该小于'BeLoadedTime' - /// - [JsonInclude] - public float BeLoadedSoundDelayTime; - - /// - /// 其他音效 - /// - public Dictionary OtherSoundMap; - - /// - /// Ai属性
- /// Ai 使用该武器时的武器数据, 设置该字段, 可让同一把武器在敌人和玩家手上有不同属性
- /// 如果不填则Ai和玩家使用同一种属性 - ///
- public Weapon AiUseAttribute; - - /// - /// Ai使用该武器开火时的一些额外配置属性
- /// 玩家使用的武器不需要填写该字段 - ///
- public AiAttackAttr AiAttackAttr; - - /// - /// 返回浅拷贝出的新对象 - /// - public Weapon Clone() - { - var inst = new Weapon(); - inst.Id = Id; - inst.WeaponId = WeaponId; - inst.Remark = Remark; - inst.Weight = Weight; - inst.WeightType = WeightType; - inst.ContinuousShoot = ContinuousShoot; - inst.AmmoCapacity = AmmoCapacity; - inst.MaxAmmoCapacity = MaxAmmoCapacity; - inst.StandbyAmmoCapacity = StandbyAmmoCapacity; - inst.ReloadTime = ReloadTime; - inst.AloneReload = AloneReload; - inst.AloneReloadCount = AloneReloadCount; - inst.AloneReloadBeginIntervalTime = AloneReloadBeginIntervalTime; - inst.AloneReloadFinishIntervalTime = AloneReloadFinishIntervalTime; - inst.AloneReloadCanShoot = AloneReloadCanShoot; - inst.LooseShoot = LooseShoot; - inst.MinChargeTime = MinChargeTime; - inst.ManualBeLoaded = ManualBeLoaded; - inst.AutoManualBeLoaded = AutoManualBeLoaded; - inst.BeLoadedTime = BeLoadedTime; - inst.ContinuousCountRange = ContinuousCountRange; - inst.TriggerInterval = TriggerInterval; - inst.StartFiringSpeed = StartFiringSpeed; - inst.FinalFiringSpeed = FinalFiringSpeed; - inst.FiringSpeedAddSpeed = FiringSpeedAddSpeed; - inst.FiringSpeedBackSpeed = FiringSpeedBackSpeed; - inst.FireBulletCountRange = FireBulletCountRange; - inst.DelayedTime = DelayedTime; - inst.StartScatteringRange = StartScatteringRange; - inst.FinalScatteringRange = FinalScatteringRange; - inst.ScatteringRangeAddValue = ScatteringRangeAddValue; - inst.ScatteringRangeBackSpeed = ScatteringRangeBackSpeed; - inst.ScatteringRangeBackDelayTime = ScatteringRangeBackDelayTime; - inst.CameraShake = CameraShake; - inst.BacklashRange = BacklashRange; - inst.BacklashRegressionSpeed = BacklashRegressionSpeed; - inst.UpliftAngle = UpliftAngle; - inst.DefaultAngle = DefaultAngle; - inst.UpliftAngleRestore = UpliftAngleRestore; - inst.BulletId = BulletId; - inst.HarmRange = HarmRange; - inst.RepelRnage = RepelRnage; - inst.BulletDeviationAngleRange = BulletDeviationAngleRange; - inst.BulletSpeedRange = BulletSpeedRange; - inst.BulletDistanceRange = BulletDistanceRange; - inst.ShellId = ShellId; - inst.ThrowShellDelayTime = ThrowShellDelayTime; - inst.ThrowCollisionSize = ThrowCollisionSize; - inst.CanMeleeAttack = CanMeleeAttack; - inst.MeleeAttackHarmRange = MeleeAttackHarmRange; - inst.MeleeAttackRepelRnage = MeleeAttackRepelRnage; - inst.ShootSound = ShootSound; - inst.BeginReloadSound = BeginReloadSound; - inst.BeginReloadSoundDelayTime = BeginReloadSoundDelayTime; - inst.ReloadSound = ReloadSound; - inst.ReloadSoundDelayTime = ReloadSoundDelayTime; - inst.ReloadFinishSound = ReloadFinishSound; - inst.ReloadFinishSoundAdvanceTime = ReloadFinishSoundAdvanceTime; - inst.BeLoadedSound = BeLoadedSound; - inst.BeLoadedSoundDelayTime = BeLoadedSoundDelayTime; - inst.OtherSoundMap = OtherSoundMap; - inst.AiUseAttribute = AiUseAttribute; - inst.AiAttackAttr = AiAttackAttr; - return inst; - } - } - private class Ref_Weapon : Weapon - { - [JsonInclude] - public string __ShootSound; - - [JsonInclude] - public string __BeginReloadSound; - - [JsonInclude] - public string __ReloadSound; - - [JsonInclude] - public string __ReloadFinishSound; - - [JsonInclude] - public string __BeLoadedSound; - - [JsonInclude] - public Dictionary __OtherSoundMap; - - [JsonInclude] - public string __AiUseAttribute; - - [JsonInclude] - public string __AiAttackAttr; - - } -} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/config/ExcelConfig_WeaponBase.cs b/DungeonShooting_Godot/src/config/ExcelConfig_WeaponBase.cs new file mode 100644 index 0000000..e45f05e --- /dev/null +++ b/DungeonShooting_Godot/src/config/ExcelConfig_WeaponBase.cs @@ -0,0 +1,476 @@ +using System.Text.Json.Serialization; +using System.Collections.Generic; + +namespace Config; + +public static partial class ExcelConfig +{ + public class WeaponBase + { + /// + /// 武器属性id + /// + [JsonInclude] + public string Id; + + /// + /// 属性绑定武器的Id,这个id时ActivityBase表Id,如果是Ai使用的数据, 则填空字符串串 + /// + public ActivityBase Activity; + + /// + /// 备注 + /// + [JsonInclude] + public string Remark; + + /// + /// 重量 + /// + [JsonInclude] + public float Weight; + + /// + /// 武器类型:
+ /// 1.副武器
+ /// 2.主武器
+ /// 3.重型武器 + ///
+ [JsonInclude] + public byte WeightType; + + /// + /// 是否连续发射, 如果为false, 则每次发射都需要扣动扳机 + /// + [JsonInclude] + public bool ContinuousShoot; + + /// + /// 弹夹容量 + /// + [JsonInclude] + public int AmmoCapacity; + + /// + /// 弹药容量上限 + /// + [JsonInclude] + public int MaxAmmoCapacity; + + /// + /// 默认起始备用弹药数量 + /// + [JsonInclude] + public int StandbyAmmoCapacity; + + /// + /// 装弹时间 (单位: 秒) + /// + [JsonInclude] + public float ReloadTime; + + /// + /// 每粒子弹是否是单独装填, 如果是, 那么每上一发子弹的时间就是 ReloadTime, 可以做霰弹枪装填效果 + /// + [JsonInclude] + public bool AloneReload; + + /// + /// 单独装填时每次装填子弹数量, 必须要将 'AloneReload' 属性设置为 true + /// + [JsonInclude] + public int AloneReloadCount; + + /// + /// 单独装弹模式下,从触发装弹到开始装第一发子弹中间的间隔时间, 必须要将 'AloneReload' 属性设置为 true + /// + [JsonInclude] + public float AloneReloadBeginIntervalTime; + + /// + /// 单独装弹模式下,从装完最后一发子弹到可以射击中间的间隔时间, 必须要将 'AloneReload' 属性设置为 true + /// + [JsonInclude] + public float AloneReloadFinishIntervalTime; + + /// + /// 单独装填的子弹时可以立即射击, 必须要将 'AloneReload' 属性设置为 true + /// + [JsonInclude] + public bool AloneReloadCanShoot; + + /// + /// 是否为松发开火, 也就是松开扳机才开火, 若要启用该属性, 必须将 'ContinuousShoot' 设置为 false + /// + [JsonInclude] + public bool LooseShoot; + + /// + /// 最少需要蓄力多久才能开火, 必须将 'LooseShoot' 设置为 true + /// + [JsonInclude] + public float MinChargeTime; + + /// + /// 单次射击后是否需要手动上膛动作, 必须将 'ContinuousShoot' 设置为 false + /// + [JsonInclude] + public bool ManualBeLoaded; + + /// + /// 手动上膛模式下, 单次射击后是否自动执行上膛操作, 必须将 'ManualBeLoaded' 设置为 true + /// + [JsonInclude] + public bool AutoManualBeLoaded; + + /// + /// 上膛时间, 如果时间为0, 则不会播放上膛动画和音效, 可以视为没有上膛动作, 必须将 'ManualBeLoaded' 设置为 true + /// + [JsonInclude] + public float BeLoadedTime; + + /// + /// 连续发射次数区间, 仅当 'ContinuousShoot' 为 false 时生效
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public int[] ContinuousCountRange; + + /// + /// 按下一次扳机后需要多长时间才能再次感应按下 + /// + [JsonInclude] + public float TriggerInterval; + + /// + /// 初始射速, 初始每分钟能开火次数 + /// + [JsonInclude] + public float StartFiringSpeed; + + /// + /// 最终射速, 最终每分钟能开火次数, 仅当 'ContinuousShoot' 为 true 时生效 + /// + [JsonInclude] + public float FinalFiringSpeed; + + /// + /// 按下扳机并开火后射速每秒增加量 + /// + [JsonInclude] + public float FiringSpeedAddSpeed; + + /// + /// 松开扳机后射速消散速率 + /// + [JsonInclude] + public float FiringSpeedBackSpeed; + + /// + /// 单次开火发射子弹数量区间
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public int[] FireBulletCountRange; + + /// + /// 从按下扳机到发射第一发子弹的延时时, 如果中途松开扳机, 那么延时时间会重新计算, 必须将 'LooseShoot' 设置为 false + /// + [JsonInclude] + public float DelayedTime; + + /// + /// 初始散射半径 + /// + [JsonInclude] + public float StartScatteringRange; + + /// + /// 最终散射半径 + /// + [JsonInclude] + public float FinalScatteringRange; + + /// + /// 每次发射后散射增加值 + /// + [JsonInclude] + public float ScatteringRangeAddValue; + + /// + /// 散射值销退速率 + /// + [JsonInclude] + public float ScatteringRangeBackSpeed; + + /// + /// 开始销退散射值的延时时间 + /// + [JsonInclude] + public float ScatteringRangeBackDelayTime; + + /// + /// 开火后相机抖动强度,只有玩家拾起武器开火才会抖动相机 + /// + [JsonInclude] + public float CameraShake; + + /// + /// 后坐力区间 (仅用于开火后武器身抖动)
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] BacklashRange; + + /// + /// 后坐力偏移回归回归速度 + /// + [JsonInclude] + public float BacklashRegressionSpeed; + + /// + /// 开火后武器口上抬角度 + /// + [JsonInclude] + public float UpliftAngle; + + /// + /// 武器默认上抬角度 + /// + [JsonInclude] + public float DefaultAngle; + + /// + /// 开火后武器口角度恢复速度倍数 + /// + [JsonInclude] + public float UpliftAngleRestore; + + /// + /// 开火特效 + /// + [JsonInclude] + public string FireEffect; + + /// + /// 默认射出的子弹 + /// + public BulletBase Bullet; + + /// + /// 默认抛出的弹壳 + /// + public ActivityBase Shell; + + /// + /// 是否在换弹时才抛弹壳 + /// + [JsonInclude] + public bool ReloadThrowShell; + + /// + /// 投抛弹壳的延时时间 + /// + [JsonInclude] + public float ThrowShellDelayTime; + + /// + /// 投抛状态下物体碰撞器大小 + /// + [JsonInclude] + public SerializeVector2 ThrowCollisionSize; + + /// + /// 是否可以触发近战攻击 + /// + [JsonInclude] + public bool CanMeleeAttack; + + /// + /// 近战攻击伤害区间
+ /// 格式为格式为[value]或者[min,max] + ///
+ [JsonInclude] + public int[] MeleeAttackHarmRange; + + /// + /// 近战攻击造成伤害后击退值区间
+ /// 格式为[value]或者[min,max] + ///
+ [JsonInclude] + public float[] MeleeAttackRepelRnage; + + /// + /// 射击音效 + /// + public Sound ShootSound; + + /// + /// 开始换弹音效 + /// + public Sound BeginReloadSound; + + /// + /// 开始换弹音效延时时间 + /// + [JsonInclude] + public float BeginReloadSoundDelayTime; + + /// + /// 换弹音效,单独装弹时也会出发 + /// + public Sound ReloadSound; + + /// + /// 换弹音效延时时间 + /// + [JsonInclude] + public float ReloadSoundDelayTime; + + /// + /// 换弹结束音效 + /// + public Sound ReloadFinishSound; + + /// + /// 换弹结束音效在换弹结束前多久开始
+ /// 注意: 如果'AloneReload'为true, 那么当前属性的值应该小于'AloneReloadFinishIntervalTime' + ///
+ [JsonInclude] + public float ReloadFinishSoundAdvanceTime; + + /// + /// 上膛音效 + /// + public Sound BeLoadedSound; + + /// + /// 上膛音效延时时间, 这个时间应该小于'BeLoadedTime' + /// + [JsonInclude] + public float BeLoadedSoundDelayTime; + + /// + /// 其他音效 + /// + public Dictionary OtherSoundMap; + + /// + /// Ai属性
+ /// Ai 使用该武器时的武器数据, 设置该字段, 可让同一把武器在敌人和玩家手上有不同属性
+ /// 如果不填则Ai和玩家使用同一种属性 + ///
+ public WeaponBase AiUseAttribute; + + /// + /// Ai使用该武器开火时的一些额外配置属性
+ /// 玩家使用的武器不需要填写该字段 + ///
+ public AiAttackAttr AiAttackAttr; + + /// + /// 返回浅拷贝出的新对象 + /// + public WeaponBase Clone() + { + var inst = new WeaponBase(); + inst.Id = Id; + inst.Activity = Activity; + inst.Remark = Remark; + inst.Weight = Weight; + inst.WeightType = WeightType; + inst.ContinuousShoot = ContinuousShoot; + inst.AmmoCapacity = AmmoCapacity; + inst.MaxAmmoCapacity = MaxAmmoCapacity; + inst.StandbyAmmoCapacity = StandbyAmmoCapacity; + inst.ReloadTime = ReloadTime; + inst.AloneReload = AloneReload; + inst.AloneReloadCount = AloneReloadCount; + inst.AloneReloadBeginIntervalTime = AloneReloadBeginIntervalTime; + inst.AloneReloadFinishIntervalTime = AloneReloadFinishIntervalTime; + inst.AloneReloadCanShoot = AloneReloadCanShoot; + inst.LooseShoot = LooseShoot; + inst.MinChargeTime = MinChargeTime; + inst.ManualBeLoaded = ManualBeLoaded; + inst.AutoManualBeLoaded = AutoManualBeLoaded; + inst.BeLoadedTime = BeLoadedTime; + inst.ContinuousCountRange = ContinuousCountRange; + inst.TriggerInterval = TriggerInterval; + inst.StartFiringSpeed = StartFiringSpeed; + inst.FinalFiringSpeed = FinalFiringSpeed; + inst.FiringSpeedAddSpeed = FiringSpeedAddSpeed; + inst.FiringSpeedBackSpeed = FiringSpeedBackSpeed; + inst.FireBulletCountRange = FireBulletCountRange; + inst.DelayedTime = DelayedTime; + inst.StartScatteringRange = StartScatteringRange; + inst.FinalScatteringRange = FinalScatteringRange; + inst.ScatteringRangeAddValue = ScatteringRangeAddValue; + inst.ScatteringRangeBackSpeed = ScatteringRangeBackSpeed; + inst.ScatteringRangeBackDelayTime = ScatteringRangeBackDelayTime; + inst.CameraShake = CameraShake; + inst.BacklashRange = BacklashRange; + inst.BacklashRegressionSpeed = BacklashRegressionSpeed; + inst.UpliftAngle = UpliftAngle; + inst.DefaultAngle = DefaultAngle; + inst.UpliftAngleRestore = UpliftAngleRestore; + inst.FireEffect = FireEffect; + inst.Bullet = Bullet; + inst.Shell = Shell; + inst.ReloadThrowShell = ReloadThrowShell; + inst.ThrowShellDelayTime = ThrowShellDelayTime; + inst.ThrowCollisionSize = ThrowCollisionSize; + inst.CanMeleeAttack = CanMeleeAttack; + inst.MeleeAttackHarmRange = MeleeAttackHarmRange; + inst.MeleeAttackRepelRnage = MeleeAttackRepelRnage; + inst.ShootSound = ShootSound; + inst.BeginReloadSound = BeginReloadSound; + inst.BeginReloadSoundDelayTime = BeginReloadSoundDelayTime; + inst.ReloadSound = ReloadSound; + inst.ReloadSoundDelayTime = ReloadSoundDelayTime; + inst.ReloadFinishSound = ReloadFinishSound; + inst.ReloadFinishSoundAdvanceTime = ReloadFinishSoundAdvanceTime; + inst.BeLoadedSound = BeLoadedSound; + inst.BeLoadedSoundDelayTime = BeLoadedSoundDelayTime; + inst.OtherSoundMap = OtherSoundMap; + inst.AiUseAttribute = AiUseAttribute; + inst.AiAttackAttr = AiAttackAttr; + return inst; + } + } + private class Ref_WeaponBase : WeaponBase + { + [JsonInclude] + public string __Activity; + + [JsonInclude] + public string __Bullet; + + [JsonInclude] + public string __Shell; + + [JsonInclude] + public string __ShootSound; + + [JsonInclude] + public string __BeginReloadSound; + + [JsonInclude] + public string __ReloadSound; + + [JsonInclude] + public string __ReloadFinishSound; + + [JsonInclude] + public string __BeLoadedSound; + + [JsonInclude] + public Dictionary __OtherSoundMap; + + [JsonInclude] + public string __AiUseAttribute; + + [JsonInclude] + public string __AiAttackAttr; + + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/activity/ActivityMaterial.cs b/DungeonShooting_Godot/src/framework/activity/ActivityMaterial.cs deleted file mode 100644 index 2d561fc..0000000 --- a/DungeonShooting_Godot/src/framework/activity/ActivityMaterial.cs +++ /dev/null @@ -1,8 +0,0 @@ - -/// -/// 物体材质 -/// -public class ActivityMaterial -{ - -} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs b/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs index 03cead3..b077a48 100644 --- a/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs +++ b/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs @@ -20,13 +20,22 @@ /// /// 当前物体对应的配置数据, 如果不是通过 ActivityObject.Create() 函数创建出来的对象那么 ItemConfig 为 null /// - public ExcelConfig.ActivityObject ItemConfig { get; private set; } + public ExcelConfig.ActivityBase ItemConfig { get; private set; } /// /// 是否是静态物体, 如果为true, 则会禁用移动处理 /// - [Export] - public bool IsStatic { get; set; } + public bool IsStatic + { + get => MoveController != null ? !MoveController.Enable : true; + set + { + if (MoveController != null) + { + MoveController.Enable = !value; + } + } + } /// /// 是否显示阴影 @@ -145,26 +154,6 @@ private float _verticalSpeed; /// - /// 落地之后是否回弹 - /// - public bool Bounce { get; set; } = true; - - /// - /// 物体下坠回弹的强度 - /// - public float BounceStrength { get; set; } = 0.5f; - - /// - /// 物体下坠回弹后的运动速度衰减量 - /// - public float BounceSpeed { get; set; } = 0.75f; - - /// - /// 物体下坠回弹后的旋转速度衰减量 - /// - public float BounceRotationSpeed { get; set; } = 0.5f; - - /// /// 投抛状态下物体碰撞器大小, 如果 (x, y) 都小于 0, 则默认使用 AnimatedSprite 的默认动画第一帧的大小 /// [Export] @@ -176,6 +165,11 @@ public bool EnableVerticalMotion { get; set; } = true; /// + /// 撞到墙壁反弹时是否锁定旋转角度, 如果为 false, 则反弹后将直接修改旋转角度 + /// + public bool BounceLockRotation { get; set; } = true; + + /// /// 是否启用物体更新行为, 默认 true, 如果禁用, 则会停止当前物体的 Process(), PhysicsProcess() 调用, 并且禁用 Collision 节点, 禁用后所有组件也同样被禁用行为 /// public bool EnableBehavior @@ -209,7 +203,7 @@ /// /// 物体材质数据 /// - public ActivityMaterial ActivityMaterial { get; private set; } + public ExcelConfig.ActivityMaterial ActivityMaterial { get; private set; } /// /// 所在的 World 对象 @@ -271,8 +265,12 @@ // -------------------------------------------------------------------------------- + //是否正在调用组件 Update 函数 + private bool _updatingComp = false; //组件集合 - private List> _components = new List>(); + private readonly List> _components = new List>(); + //修改的组件集合, value 为 true 表示添加组件, false 表示移除组件 + private readonly List> _changeComponents = new List>(); //上一帧动画名称 private string _prevAnimation; //上一帧动画 @@ -287,7 +285,7 @@ private ShaderMaterial _shadowBlendShaderMaterial; //存储投抛该物体时所产生的数据 - private ActivityFallData _fallData = new ActivityFallData(); + private readonly ActivityFallData _fallData = new ActivityFallData(); //所在层级 private RoomLayerEnum _currLayer; @@ -334,9 +332,12 @@ //描边颜色 private bool _initOutlineColor = false; private Color _outlineColor = new Color(0, 0, 0, 1); + + //冻结显示的Sprite + private FreezeSprite _freezeSprite; //初始化节点 - private void _InitNode(RegisterActivityData activityData, World world) + private void _InitNode(ExcelConfig.ActivityBase config, World world) { #if TOOLS if (!Engine.IsEditorHint()) @@ -347,8 +348,17 @@ } } #endif + if (config.Material == null) + { + ActivityMaterial = ExcelConfig.ActivityMaterial_List[0]; + } + else + { + ActivityMaterial = config.Material; + } + World = world; - ItemConfig = activityData.Config; + ItemConfig = config; Name = GetType().Name + (_instanceIndex++); _blendShaderMaterial = AnimatedSprite.Material as ShaderMaterial; _shadowBlendShaderMaterial = ShadowSprite.Material as ShaderMaterial; @@ -365,7 +375,7 @@ ShadowSprite.Visible = false; MotionMode = MotionModeEnum.Floating; MoveController = AddComponent(); - MoveController.Enable = !IsStatic; + IsStatic = config.IsStatic; OnInit(); } @@ -574,13 +584,6 @@ } /// - /// 每帧调用一次, ProcessOver() 会在组件的 Process() 之后调用 - /// - protected virtual void ProcessOver(float delta) - { - } - - /// /// 每物理帧调用一次, 物体的 PhysicsProcess() 会在组件的 PhysicsProcess() 之前调用 /// protected virtual void PhysicsProcess(float delta) @@ -588,13 +591,6 @@ } /// - /// 每物理帧调用一次, PhysicsProcessOver() 会在组件的 PhysicsProcess() 之后调用 - /// - protected virtual void PhysicsProcessOver(float delta) - { - } - - /// /// 如果开启 debug, 则每帧调用该函数, 可用于绘制文字线段等 /// protected virtual void DebugDraw() @@ -610,6 +606,20 @@ } /// + /// 移动并碰撞到物体时调用该函数, 参数为碰撞数据, 该函数由 MoveController 调用 + /// + public virtual void OnMoveCollision(KinematicCollision2D collision) + { + } + + /// + /// 撞到墙壁反弹时调用该函数, 参数为反弹的角度, 弧度制, 该函数由 MoveController 调用 + /// + public virtual void OnBounce(float rotation) + { + } + + /// /// 返回当物体 CollisionLayer 是否能与 mask 层碰撞 /// public bool CollisionWithMask(uint mask) @@ -752,7 +762,15 @@ public T AddComponent() where T : Component, new() { var component = new T(); - _components.Add(new KeyValuePair(typeof(T), component)); + if (_updatingComp) + { + _changeComponents.Add(new KeyValuePair(component, true)); + } + else + { + _components.Add(new KeyValuePair(typeof(T), component)); + } + component.Master = this; component.Ready(); component.OnEnable(); @@ -765,7 +783,15 @@ public Component AddComponent(Type type) { var component = (Component)Activator.CreateInstance(type); - _components.Add(new KeyValuePair(type, component)); + if (_updatingComp) + { + _changeComponents.Add(new KeyValuePair(component, true)); + } + else + { + _components.Add(new KeyValuePair(type, component)); + } + component.Master = this; component.Ready(); component.OnEnable(); @@ -778,13 +804,26 @@ /// 组件对象 public void RemoveComponent(Component component) { - for (int i = 0; i < _components.Count; i++) + if (component.IsDestroyed) { - if (_components[i].Value == component) + return; + } + + if (_updatingComp) + { + _changeComponents.Add(new KeyValuePair(component, false)); + component.Destroy(); + } + else + { + for (var i = 0; i < _components.Count; i++) { - _components.RemoveAt(i); - component.Destroy(); - return; + if (_components[i].Value == component) + { + _components.RemoveAt(i); + component.Destroy(); + return; + } } } } @@ -803,6 +842,18 @@ } } + if (_updatingComp) + { + for (var i = 0; i < _changeComponents.Count; i++) + { + var temp = _components[i]; + if (temp.Value.GetType() == type) + { + return temp.Value; + } + } + } + return null; } @@ -885,14 +936,14 @@ //更新组件 if (_components.Count > 0) { + _updatingComp = true; if (EnableCustomBehavior) //启用所有组件 { - var arr = _components.ToArray(); - for (int i = 0; i < arr.Length; i++) + for (int i = 0; i < _components.Count; i++) { if (IsDestroyed) return; - var temp = arr[i].Value; - if (temp != null && temp.Master == this && temp.Enable) + var temp = _components[i].Value; + if (temp != null && temp.Enable) { temp.Process(newDelta); } @@ -905,8 +956,58 @@ MoveController.Process(newDelta); } } + _updatingComp = false; + + if (_changeComponents.Count > 0) + { + RefreshComponent(); + } } + // 更新下坠处理逻辑 + UpdateFall(newDelta); + + //阴影 + UpdateShadowSprite(newDelta); + + // Hit 动画 + if (_playHit) + { + if (_playHitSchedule < 0.05f) + { + _blendShaderMaterial.SetShaderParameter("schedule", 1); + } + else if (_playHitSchedule < 0.15f) + { + _blendShaderMaterial.SetShaderParameter("schedule", Mathf.Lerp(1, 0, (_playHitSchedule - 0.05f) / 0.1f)); + } + if (_playHitSchedule >= 0.15f) + { + _blendShaderMaterial.SetShaderParameter("schedule", 0); + _playHitSchedule = 0; + _playHit = false; + } + else + { + _playHitSchedule += newDelta; + } + } + + //协程更新 + ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, newDelta); + + //调试绘制 + if (IsDebug) + { + QueueRedraw(); + } + } + + /// + /// 更新下坠处理逻辑 + /// + public void UpdateFall(float delta) + { // 下坠判定 if (Altitude > 0 || VerticalSpeed != 0) { @@ -922,8 +1023,8 @@ var ysp = VerticalSpeed; - _altitude += VerticalSpeed * newDelta; - _verticalSpeed -= GameConfig.G * newDelta; + _altitude += VerticalSpeed * delta; + _verticalSpeed -= GameConfig.G * delta; //当高度大于16时, 显示在所有物体上 if (Altitude >= 16) @@ -957,28 +1058,28 @@ { //缩放移动速度 //MoveController.ScaleAllForce(BounceSpeed); - _throwForce.Velocity *= BounceSpeed; + _throwForce.Velocity *= ActivityMaterial.FallBounceSpeed; //缩放旋转速度 //MoveController.ScaleAllRotationSpeed(BounceStrength); - _throwForce.RotationSpeed *= BounceRotationSpeed; + _throwForce.RotationSpeed *= ActivityMaterial.FallBounceRotation; } //如果落地高度不够低, 再抛一次 - if (Bounce && (!_hasResilienceVerticalSpeed || _resilienceVerticalSpeed > 5)) + if (ActivityMaterial.Bounce && (!_hasResilienceVerticalSpeed || _resilienceVerticalSpeed > 5)) { if (!_hasResilienceVerticalSpeed) { _hasResilienceVerticalSpeed = true; - _resilienceVerticalSpeed = -VerticalSpeed * BounceStrength; + _resilienceVerticalSpeed = -VerticalSpeed * ActivityMaterial.FallBounceStrength; } else { if (_resilienceVerticalSpeed < 25) { - _resilienceVerticalSpeed = _resilienceVerticalSpeed * BounceStrength * 0.4f; + _resilienceVerticalSpeed = _resilienceVerticalSpeed * ActivityMaterial.FallBounceStrength * 0.4f; } else { - _resilienceVerticalSpeed = _resilienceVerticalSpeed * BounceStrength; + _resilienceVerticalSpeed = _resilienceVerticalSpeed * ActivityMaterial.FallBounceStrength; } } _verticalSpeed = _resilienceVerticalSpeed; @@ -1008,7 +1109,14 @@ } } - //阴影 + } + + /// + /// 更新阴影逻辑 + /// + public void UpdateShadowSprite(float delta) + { + // 阴影 if (ShadowSprite.Visible) { //更新阴影贴图, 使其和动画一致 @@ -1023,48 +1131,15 @@ _prevAnimation = anim; _prevAnimationFrame = frame; - //计算阴影 - CalcShadowTransform(); + if (_freezeSprite == null || !_freezeSprite.IsFrozen) + { + //计算阴影 + CalcShadowTransform(); + } } - // Hit 动画 - if (_playHit) - { - if (_playHitSchedule < 0.05f) - { - _blendShaderMaterial.SetShaderParameter("schedule", 1); - } - else if (_playHitSchedule < 0.15f) - { - _blendShaderMaterial.SetShaderParameter("schedule", Mathf.Lerp(1, 0, (_playHitSchedule - 0.05f) / 0.1f)); - } - if (_playHitSchedule >= 0.15f) - { - _blendShaderMaterial.SetShaderParameter("schedule", 0); - _playHitSchedule = 0; - _playHit = false; - } - else - { - _playHitSchedule += newDelta; - } - } - - //协程更新 - if (_coroutineList != null) - { - ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, newDelta); - } - - ProcessOver(newDelta); - - //调试绘制 - if (IsDebug) - { - QueueRedraw(); - } } - + /// /// 每物理帧调用一次, 为了防止子类覆盖 _PhysicsProcess(), 给 _PhysicsProcess() 加上了 sealed, 子类需要帧循环函数请重写 PhysicsProcess() 函数 /// @@ -1085,14 +1160,14 @@ //更新组件 if (_components.Count > 0) { + _updatingComp = true; if (EnableCustomBehavior) //启用所有组件 { - var arr = _components.ToArray(); - for (int i = 0; i < arr.Length; i++) + for (int i = 0; i < _components.Count; i++) { if (IsDestroyed) return; - var temp = arr[i].Value; - if (temp != null && temp.Master == this && temp.Enable) + var temp = _components[i].Value; + if (temp != null && temp.Enable) { temp.PhysicsProcess(newDelta); } @@ -1105,9 +1180,37 @@ MoveController.PhysicsProcess(newDelta); } } - } + _updatingComp = false; - PhysicsProcessOver(newDelta); + if (_changeComponents.Count > 0) + { + RefreshComponent(); + } + } + } + + //更新新增/移除的组件 + private void RefreshComponent() + { + for (var i = 0; i < _changeComponents.Count; i++) + { + var item = _changeComponents[i]; + if (item.Value) //添加组件 + { + _components.Add(new KeyValuePair(item.Key.GetType(), item.Key)); + } + else //移除组件 + { + for (var j = 0; j < _components.Count; j++) + { + if (_components[i].Value == item.Key) + { + _components.RemoveAt(i); + break; + } + } + } + } } /// @@ -1188,11 +1291,18 @@ QueueFree(); OnDestroy(); + if (_freezeSprite != null) + { + _freezeSprite.Destroy(); + } + var arr = _components.ToArray(); for (var i = 0; i < arr.Length; i++) { arr[i].Value?.Destroy(); } + + _components.Clear(); } /// @@ -1275,7 +1385,7 @@ Collision.Rotation = 0; Collision.Scale = Vector2.One; CollisionMask = 1; - CollisionLayer = PhysicsLayer.Throwing; + CollisionLayer = _fallData.OriginCollisionLayer | PhysicsLayer.Throwing; _fallData.UseOrigin = false; } } @@ -1417,6 +1527,22 @@ _playHit = true; _playHitSchedule = 0; } + + /// + /// 获取当前摩擦力 + /// + public float GetCurrentFriction() + { + return ActivityMaterial.Friction; + } + + /// + /// 获取当前旋转摩擦力 + /// + public float GetCurrentRotationFriction() + { + return ActivityMaterial.RotationFriction; + } public long StartCoroutine(IEnumerator able) { @@ -1437,6 +1563,19 @@ { ProxyCoroutineHandler.ProxyStopAllCoroutine(ref _coroutineList); } + + /// + /// 播放 AnimatedSprite 上的动画, 如果没有这个动画, 则什么也不会发生 + /// + /// 动画名称 + public void PlaySpriteAnimation(string name) + { + var spriteFrames = AnimatedSprite.SpriteFrames; + if (spriteFrames != null && spriteFrames.HasAnimation(name)) + { + AnimatedSprite.Play(name); + } + } /// /// 将当前 ActivityObject 变成静态图像绘制到地面上, 用于优化渲染大量物体
@@ -1458,9 +1597,9 @@ _processingBecomesStaticImage = true; EnableBehavior = false; - var staticImageCanvas = AffiliationArea.RoomInfo.StaticImageCanvas; - var position = staticImageCanvas.ToImageCanvasPosition(GlobalPosition); - staticImageCanvas.CanvasSprite.DrawActivityObjectInCanvas(this, position.X, position.Y, () => + var roomInfo = AffiliationArea.RoomInfo; + var position = roomInfo.ToImageCanvasPosition(GlobalPosition); + roomInfo.StaticImageCanvas.DrawActivityObjectInCanvas(this, position.X, position.Y, () => { Destroy(); }); @@ -1473,4 +1612,28 @@ { return _processingBecomesStaticImage; } + + /// + /// 冻结物体,多余的节点就会被移出场景树,逻辑也会被暂停,用于优化性能 + /// + public void Freeze() + { + if (_freezeSprite == null) + { + _freezeSprite = new FreezeSprite(this); + } + _freezeSprite.Freeze(); + } + + /// + /// 解冻物体, 恢复正常逻辑 + /// + public void Unfreeze() + { + if (_freezeSprite == null) + { + return; + } + _freezeSprite.Unfreeze(); + } } \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/activity/ActivityObject_Create.cs b/DungeonShooting_Godot/src/framework/activity/ActivityObject_Create.cs new file mode 100644 index 0000000..ebc901a --- /dev/null +++ b/DungeonShooting_Godot/src/framework/activity/ActivityObject_Create.cs @@ -0,0 +1,55 @@ + +using System; +using Config; + +public partial class ActivityObject +{ + /// + /// 通过 ActivityBase 实例化 ActivityObject 对象 + /// + public static ActivityObject Create(ExcelConfig.ActivityBase config) + { + var world = GameApplication.Instance.World; + if (world == null) + { + throw new Exception("实例化 ActivityObject 前请先调用 'GameApplication.Instance.CreateNewWorld()' 初始化 World 对象"); + } + var instance = ResourceManager.LoadAndInstantiate(config.Prefab); + instance._InitNode(config, world); + return instance; + } + + /// + /// 通过 ActivityBase 实例化 ActivityObject 对象 + /// + public static T Create(ExcelConfig.ActivityBase config) where T : ActivityObject + { + return (T)Create(config); + } + + /// + /// 通过 ItemId 实例化 ActivityObject 对象 + /// + public static ActivityObject Create(string itemId) + { + if (ExcelConfig.ActivityBase_Map.TryGetValue(itemId, out var config)) + { + return Create(config); + } + Debug.LogError("创建实例失败, 未找到id为'" + itemId + "'的物体!"); + return null; + } + + /// + /// 通过 ItemId 实例化 ActivityObject 对象 + /// + public static T Create(string itemId) where T : ActivityObject + { + var instance = Create(itemId); + if (instance != null) + { + return (T)instance; + } + return null; + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/activity/ActivityObject_Init.cs b/DungeonShooting_Godot/src/framework/activity/ActivityObject_Init.cs index 3ff5957..8372962 100644 --- a/DungeonShooting_Godot/src/framework/activity/ActivityObject_Init.cs +++ b/DungeonShooting_Godot/src/framework/activity/ActivityObject_Init.cs @@ -54,6 +54,16 @@ ///
public const string Id_weapon0007 = "weapon0007"; /// + /// 名称: 激光手枪
+ /// 简介: + ///
+ public const string Id_weapon0008 = "weapon0008"; + /// + /// 名称: 榴弹发射器
+ /// 简介: + ///
+ public const string Id_weapon0009 = "weapon0009"; + /// /// 名称:
/// 简介: ///
@@ -69,6 +79,11 @@ ///
public const string Id_bullet0003 = "bullet0003"; /// + /// 名称: 榴弹炮
+ /// 简介: + ///
+ public const string Id_bullet0004 = "bullet0004"; + /// /// 名称:
/// 简介: ///
@@ -85,6 +100,11 @@ public const string Id_shell0003 = "shell0003"; /// /// 名称:
+ /// 简介: + ///
+ public const string Id_shell0004 = "shell0004"; + /// + /// 名称:
/// 简介: 敌人死亡碎片 ///
public const string Id_effect0001 = "effect0001"; @@ -169,39 +189,4 @@ ///
public const string Id_other_door_n = "other_door_n"; } - private static void _InitRegister() - { - _activityRegisterMap.Add("role0001", new RegisterActivityData("res://prefab/role/Role0001.tscn", ExcelConfig.ActivityObject_Map["role0001"])); - _activityRegisterMap.Add("enemy0001", new RegisterActivityData("res://prefab/role/Enemy0001.tscn", ExcelConfig.ActivityObject_Map["enemy0001"])); - _activityRegisterMap.Add("weapon0001", new RegisterActivityData("res://prefab/weapon/Weapon0001.tscn", ExcelConfig.ActivityObject_Map["weapon0001"])); - _activityRegisterMap.Add("weapon0002", new RegisterActivityData("res://prefab/weapon/Weapon0002.tscn", ExcelConfig.ActivityObject_Map["weapon0002"])); - _activityRegisterMap.Add("weapon0003", new RegisterActivityData("res://prefab/weapon/Weapon0003.tscn", ExcelConfig.ActivityObject_Map["weapon0003"])); - _activityRegisterMap.Add("weapon0004", new RegisterActivityData("res://prefab/weapon/Weapon0004.tscn", ExcelConfig.ActivityObject_Map["weapon0004"])); - _activityRegisterMap.Add("weapon0005", new RegisterActivityData("res://prefab/weapon/Weapon0005.tscn", ExcelConfig.ActivityObject_Map["weapon0005"])); - _activityRegisterMap.Add("weapon0006", new RegisterActivityData("res://prefab/weapon/Weapon0006.tscn", ExcelConfig.ActivityObject_Map["weapon0006"])); - _activityRegisterMap.Add("weapon0007", new RegisterActivityData("res://prefab/weapon/Weapon0007.tscn", ExcelConfig.ActivityObject_Map["weapon0007"])); - _activityRegisterMap.Add("bullet0001", new RegisterActivityData("res://prefab/bullet/Bullet0001.tscn", ExcelConfig.ActivityObject_Map["bullet0001"])); - _activityRegisterMap.Add("bullet0002", new RegisterActivityData("res://prefab/bullet/Bullet0002.tscn", ExcelConfig.ActivityObject_Map["bullet0002"])); - _activityRegisterMap.Add("bullet0003", new RegisterActivityData("res://prefab/bullet/Bullet0003.tscn", ExcelConfig.ActivityObject_Map["bullet0003"])); - _activityRegisterMap.Add("shell0001", new RegisterActivityData("res://prefab/shell/Shell0001.tscn", ExcelConfig.ActivityObject_Map["shell0001"])); - _activityRegisterMap.Add("shell0002", new RegisterActivityData("res://prefab/shell/Shell0002.tscn", ExcelConfig.ActivityObject_Map["shell0002"])); - _activityRegisterMap.Add("shell0003", new RegisterActivityData("res://prefab/shell/Shell0003.tscn", ExcelConfig.ActivityObject_Map["shell0003"])); - _activityRegisterMap.Add("effect0001", new RegisterActivityData("res://prefab/effect/enemy/Effect0001.tscn", ExcelConfig.ActivityObject_Map["effect0001"])); - _activityRegisterMap.Add("prop0001", new RegisterActivityData("res://prefab/effect/enemy/Effect0001.tscn", ExcelConfig.ActivityObject_Map["prop0001"])); - _activityRegisterMap.Add("prop0002", new RegisterActivityData("res://prefab/prop/buff/BuffProp0002.tscn", ExcelConfig.ActivityObject_Map["prop0002"])); - _activityRegisterMap.Add("prop0003", new RegisterActivityData("res://prefab/prop/buff/BuffProp0003.tscn", ExcelConfig.ActivityObject_Map["prop0003"])); - _activityRegisterMap.Add("prop0004", new RegisterActivityData("res://prefab/prop/buff/BuffProp0004.tscn", ExcelConfig.ActivityObject_Map["prop0004"])); - _activityRegisterMap.Add("prop0005", new RegisterActivityData("res://prefab/prop/buff/BuffProp0005.tscn", ExcelConfig.ActivityObject_Map["prop0005"])); - _activityRegisterMap.Add("prop0006", new RegisterActivityData("res://prefab/prop/buff/BuffProp0006.tscn", ExcelConfig.ActivityObject_Map["prop0006"])); - _activityRegisterMap.Add("prop0007", new RegisterActivityData("res://prefab/prop/buff/BuffProp0007.tscn", ExcelConfig.ActivityObject_Map["prop0007"])); - _activityRegisterMap.Add("prop0008", new RegisterActivityData("res://prefab/prop/buff/BuffProp0008.tscn", ExcelConfig.ActivityObject_Map["prop0008"])); - _activityRegisterMap.Add("prop0009", new RegisterActivityData("res://prefab/prop/buff/BuffProp0009.tscn", ExcelConfig.ActivityObject_Map["prop0009"])); - _activityRegisterMap.Add("prop0010", new RegisterActivityData("res://prefab/prop/buff/BuffProp0010.tscn", ExcelConfig.ActivityObject_Map["prop0010"])); - _activityRegisterMap.Add("prop5000", new RegisterActivityData("res://prefab/prop/active/ActiveProp5000.tscn", ExcelConfig.ActivityObject_Map["prop5000"])); - _activityRegisterMap.Add("prop5001", new RegisterActivityData("res://prefab/prop/active/ActiveProp5001.tscn", ExcelConfig.ActivityObject_Map["prop5001"])); - _activityRegisterMap.Add("other_door_e", new RegisterActivityData("res://prefab/map/RoomDoor_E.tscn", ExcelConfig.ActivityObject_Map["other_door_e"])); - _activityRegisterMap.Add("other_door_w", new RegisterActivityData("res://prefab/map/RoomDoor_W.tscn", ExcelConfig.ActivityObject_Map["other_door_w"])); - _activityRegisterMap.Add("other_door_s", new RegisterActivityData("res://prefab/map/RoomDoor_S.tscn", ExcelConfig.ActivityObject_Map["other_door_s"])); - _activityRegisterMap.Add("other_door_n", new RegisterActivityData("res://prefab/map/RoomDoor_N.tscn", ExcelConfig.ActivityObject_Map["other_door_n"])); - } } diff --git a/DungeonShooting_Godot/src/framework/activity/ActivityObject_Register.cs b/DungeonShooting_Godot/src/framework/activity/ActivityObject_Register.cs deleted file mode 100644 index 28a5d5a..0000000 --- a/DungeonShooting_Godot/src/framework/activity/ActivityObject_Register.cs +++ /dev/null @@ -1,72 +0,0 @@ - -using System; -using System.Collections.Generic; -using Config; -using Godot; - -public partial class ActivityObject -{ - private class RegisterActivityData - { - public RegisterActivityData(string path, ExcelConfig.ActivityObject config) - { - Path = path; - Config = config; - } - - public string Path; - public ExcelConfig.ActivityObject Config; - } - - //负责存放所有注册对象数据 - private static Dictionary _activityRegisterMap = new Dictionary(); - private static bool _initState = false; - - /// - /// 初始化调用, 开始扫描当前程序集, 并自动注册 ActivityObject 物体 - /// - public static void InitActivity() - { - if (_initState) - { - return; - } - - _initState = true; - _InitRegister(); - } - - /// - /// 通过 ItemId 实例化 ActivityObject 对象 - /// - public static ActivityObject Create(string itemId) - { - var world = GameApplication.Instance.World; - if (world == null) - { - throw new Exception("实例化 ActivityObject 前请先调用 'GameApplication.Instance.CreateNewWorld()' 初始化 World 对象"); - } - - if (_activityRegisterMap.TryGetValue(itemId, out var config)) - { - var instance = ResourceManager.LoadAndInstantiate(config.Path); - instance._InitNode(config, world); - return instance; - } - Debug.LogError("创建实例失败, 未找到id为'" + itemId + "'的物体!"); - return null; - } - - /// - /// 通过 ItemId 实例化 ActivityObject 对象 - /// - public static T Create(string itemId) where T : ActivityObject - { - var instance = Create(itemId); - if (instance != null) - { - return (T)instance; - } - return null; - } -} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/activity/ExternalForce.cs b/DungeonShooting_Godot/src/framework/activity/ExternalForce.cs index 02ee215..fee637c 100644 --- a/DungeonShooting_Godot/src/framework/activity/ExternalForce.cs +++ b/DungeonShooting_Godot/src/framework/activity/ExternalForce.cs @@ -19,8 +19,8 @@ /// /// 是否在空中也会受到阻力 /// - public bool EnableResistanceInTheAir { get; set; } = true; - + public bool EnableResistanceInTheAir { get; set; } = false; + /// /// 当速度( Velocity 和 RotationSpeed )到达 0 后是否自动销毁, 默认 true /// diff --git a/DungeonShooting_Godot/src/framework/activity/components/MoveController.cs b/DungeonShooting_Godot/src/framework/activity/components/MoveController.cs index 9056451..5575a61 100644 --- a/DungeonShooting_Godot/src/framework/activity/components/MoveController.cs +++ b/DungeonShooting_Godot/src/framework/activity/components/MoveController.cs @@ -30,6 +30,21 @@ } private Vector2 _basisVelocity = Vector2.Zero; + private float _flag = 0; + + /// + /// 是否是静止状态 + /// + public bool IsMotionless() + { + var v = Velocity; + foreach (var externalForce in _forceList) + { + v += externalForce.Velocity; + } + + return v == Vector2.Zero; + } /// /// 缩放所有外力对象的速率, 包括基础速率 @@ -172,6 +187,7 @@ public ExternalForce AddForce(Vector2 velocity) { var force = AddForce("_anonymity_" + _index++); + force.AutoDestroy = true; force.Velocity = velocity; return force; } @@ -304,15 +320,19 @@ //处理旋转 if (rotationSpeed != 0) { - Master.Rotation += rotationSpeed * delta; + Rotation += rotationSpeed * delta; } + var friction = !Master.IsThrowing && Master.Altitude <= 0 ? Master.GetCurrentFriction() : 0; + var rotationFriction = !Master.IsThrowing && Master.Altitude <= 0 ? Mathf.DegToRad(Master.GetCurrentRotationFriction()) : 0; //衰减旋转速率 for (var i = 0; i < _forceList.Count; i++) { var force = _forceList[i]; - if (force.RotationResistance != 0 && (force.EnableResistanceInTheAir || !Master.IsThrowing)) + var num = (force.EnableResistanceInTheAir || !Master.IsThrowing) ? force.RotationResistance : 0; + num += rotationFriction; + if (num != 0) { - force.RotationSpeed = Mathf.MoveToward(force.RotationSpeed, 0, force.RotationResistance * delta); + force.RotationSpeed = Mathf.MoveToward(force.RotationSpeed, 0, num * delta); } } @@ -327,6 +347,11 @@ //新速度 var newVelocity = Master.Velocity; + if (!Master.BounceLockRotation) //跟着反弹角度 + { + Rotation = newVelocity.Angle(); + } + if (newVelocity.X == 0f && _basisVelocity.X * finallyVelocity.X > 0) { _basisVelocity.X = 0; @@ -338,17 +363,35 @@ } //是否撞到物体 - var collision = Master.GetLastSlideCollision(); - if (collision != null) //执行反弹操作 + KinematicCollision2D collision; + _flag -= delta; + if (_flag <= 0 && (collision = Master.GetLastSlideCollision()) != null) //执行反弹操作 { + //调用移动碰撞函数 + Master.OnMoveCollision(collision); + if (Master.IsDestroyed) + { + return; + } + //0.1秒内不能再触发第二次碰撞检测 + _flag = 0.1f; var no = collision.GetNormal().Rotated(Mathf.Pi * 0.5f); - newVelocity = (finallyVelocity - _basisVelocity).Reflect(no); + newVelocity = finallyEf.Reflect(no); + var rotation = newVelocity.Angle(); + + if (!Master.BounceLockRotation) //跟着反弹角度 + { + Rotation = rotation; + } + var length = _forceList.Count; - var v = newVelocity / (length / Master.BounceStrength); + var v = newVelocity / (length / Master.ActivityMaterial.BounceStrength); for (var i = 0; i < _forceList.Count; i++) { _forceList[i].Velocity = v; } + //调用反弹函数 + Master.OnBounce(rotation); } else //没有撞到物体 { @@ -365,9 +408,11 @@ ); //力速度衰减 - if (force.VelocityResistance != 0 && (force.EnableResistanceInTheAir || !Master.IsThrowing)) + var num = (force.EnableResistanceInTheAir || !Master.IsThrowing) ? force.VelocityResistance : 0; + num += friction; + if (num != 0) { - force.Velocity = force.Velocity.MoveToward(Vector2.Zero, force.VelocityResistance * delta); + force.Velocity = force.Velocity.MoveToward(Vector2.Zero, num * delta); } } } diff --git a/DungeonShooting_Godot/src/framework/common/NodeExtend.cs b/DungeonShooting_Godot/src/framework/common/NodeExtend.cs index deee5c1..e9988f0 100644 --- a/DungeonShooting_Godot/src/framework/common/NodeExtend.cs +++ b/DungeonShooting_Godot/src/framework/common/NodeExtend.cs @@ -50,6 +50,16 @@ { GameApplication.Instance.World.GetRoomLayer(layer).AddChild(node); } + + /// + /// 将节点插入的房间物体根节点,延时调用 + /// + /// 实例 + /// 放入的层 + public static void AddToActivityRootDeferred(this Node2D node, RoomLayerEnum layer) + { + GameApplication.Instance.World.GetRoomLayer(layer).CallDeferred(Node.MethodName.AddChild, node); + } /// /// 设置Ui布局方式是否横向扩展, 如果为 true, 则 GridContainer 的宽度会撑满父物体 diff --git a/DungeonShooting_Godot/src/framework/common/SpiralUtil.cs b/DungeonShooting_Godot/src/framework/common/SpiralUtil.cs new file mode 100644 index 0000000..67d8a79 --- /dev/null +++ b/DungeonShooting_Godot/src/framework/common/SpiralUtil.cs @@ -0,0 +1,56 @@ +using Godot; + + +public static class SpiralUtil +{ + /// + /// 螺旋算法 顺时针 + /// 7 8 9 10 + /// 6 1 2 + /// 5 4 3 + /// + private static float[][] SCREW_CLOCKWISE = new float[][] { new float[] { 1, 2, 3, 4 }, new float[] { 4, 1, 2, 3 } }; + + /// + /// 螺旋算法 + /// + /// 当前序列 + /// 返回当前序列应该所在的位置 + public static Vector2I Screw(int index) + { + //总体思路是先找到第几圈 然后再找到第几个拐角 然后用switch + //因为一般序列都是从0开始的,所以此处加一以适应规则 + index++; + //如果求的是中心点 直接返回就行了 + if (index <= 1) return new Vector2I(0, 0); + + //开平方得到当前序列在哪个阶段中(阶段=第几圈*2) + var n = Mathf.Ceil(Mathf.Sqrt(index)); + var step = Mathf.FloorToInt(n / 2) * 2; + //求出当前序列是当前阶段中的第几个数 + var stepIndex = index - (step - 1) * (step - 1); + //求出当前序列在当前阶段中的第几条边上 + var stepStep = Mathf.CeilToInt((float)stepIndex / step); + //当前序列是当前边上第几个数 + var ssi = stepIndex % step; + if (ssi == 0) ssi = step; + + return new Vector2I( + GetValue(step, ssi, SCREW_CLOCKWISE[0][stepStep - 1]), + GetValue(step, ssi, SCREW_CLOCKWISE[1][stepStep - 1]) + ); + } + + private static int GetValue(int step, int ssi, float switchIndex) + { + switch (switchIndex) + { + case 1: return step / 2; + case 2: return step / 2 - ssi; + case 3: return -step / 2; + case 4: return -step / 2 + ssi; + } + + return 0; + } +} diff --git a/DungeonShooting_Godot/src/framework/coroutine/ProxyCoroutineHandler.cs b/DungeonShooting_Godot/src/framework/coroutine/ProxyCoroutineHandler.cs index 8db3fd8..18371c0 100644 --- a/DungeonShooting_Godot/src/framework/coroutine/ProxyCoroutineHandler.cs +++ b/DungeonShooting_Godot/src/framework/coroutine/ProxyCoroutineHandler.cs @@ -15,7 +15,7 @@ /// public static void ProxyUpdateCoroutine(ref List coroutineList, float delta) { - if (coroutineList.Count == 0) + if (coroutineList == null || coroutineList.Count == 0) { return; } diff --git a/DungeonShooting_Godot/src/framework/generator/ExcelGenerator.cs b/DungeonShooting_Godot/src/framework/generator/ExcelGenerator.cs index ee59049..86bfa6d 100644 --- a/DungeonShooting_Godot/src/framework/generator/ExcelGenerator.cs +++ b/DungeonShooting_Godot/src/framework/generator/ExcelGenerator.cs @@ -3,6 +3,7 @@ using System; using System.IO; using System.Text.Json; +using Config; using Godot; using Array = Godot.Collections.Array; @@ -36,11 +37,10 @@ //生成初始化 ActivityObject 代码 private static void GeneratorActivityObjectInit() { - var text = File.ReadAllText("resource/config/ActivityObject.json"); - var array = JsonSerializer.Deserialize[]>(text); + var text = File.ReadAllText($"resource/config/{nameof(ExcelConfig.ActivityBase)}.json"); + var array = JsonSerializer.Deserialize[]>(text); var code1 = ""; - var code2 = ""; foreach (var item in array) { @@ -52,7 +52,6 @@ code1 += $" /// 简介: {intro.Replace("\n", "
\n /// ")}\n"; code1 += $" ///
\n"; code1 += $" public const string Id_{id} = \"{id}\";\n"; - code2 += $" _activityRegisterMap.Add(\"{id}\", new RegisterActivityData(\"{item["Prefab"]}\", ExcelConfig.ActivityObject_Map[\"{id}\"]));\n"; } var str = $"using Config;\n\n"; @@ -68,10 +67,6 @@ str += code1; str += $" }}\n"; - str += $" private static void _InitRegister()\n"; - str += $" {{\n"; - str += code2; - str += $" }}\n"; str += $"}}\n"; File.WriteAllText("src/framework/activity/ActivityObject_Init.cs", str); diff --git a/DungeonShooting_Godot/src/framework/map/AffiliationArea.cs b/DungeonShooting_Godot/src/framework/map/AffiliationArea.cs index 1972ec2..fe66f00 100644 --- a/DungeonShooting_Godot/src/framework/map/AffiliationArea.cs +++ b/DungeonShooting_Godot/src/framework/map/AffiliationArea.cs @@ -29,7 +29,7 @@ /// 玩家是否是第一次进入 ///
public bool IsFirstEnterFlag { get; private set; } = true; - + private bool _init = false; private Vector2 _initSize; private RectangleShape2D _shape; @@ -48,6 +48,7 @@ _initSize = rect2.Size; RoomInfo = roomInfo; + var collisionShape = new CollisionShape2D(); collisionShape.GlobalPosition = rect2.Position + rect2.Size / 2; var shape = new RectangleShape2D(); @@ -63,7 +64,7 @@ Monitoring = true; Monitorable = false; CollisionLayer = PhysicsLayer.None; - CollisionMask = PhysicsLayer.Prop | PhysicsLayer.Player | PhysicsLayer.Enemy | PhysicsLayer.Shell | PhysicsLayer.Throwing; + CollisionMask = PhysicsLayer.Prop | PhysicsLayer.Player | PhysicsLayer.Enemy | PhysicsLayer.Debris | PhysicsLayer.Throwing; BodyEntered += OnBodyEntered; BodyExited += OnBodyExited; diff --git a/DungeonShooting_Godot/src/framework/map/image/FreezeSprite.cs b/DungeonShooting_Godot/src/framework/map/image/FreezeSprite.cs new file mode 100644 index 0000000..34a035c --- /dev/null +++ b/DungeonShooting_Godot/src/framework/map/image/FreezeSprite.cs @@ -0,0 +1,125 @@ + +using Godot; + +/// +/// 用于绘制静止不动的 ActivityObject,从而优化性能 +/// +public class FreezeSprite : IDestroy +{ + public bool IsDestroyed { get; private set; } + + /// + /// 所在位置 + /// + public Vector2 Position { get; private set; } + + /// + /// 所属对象 + /// + public ActivityObject ActivityObject { get; } + + /// + /// 是否已经被冻结 + /// + public bool IsFrozen { get; private set; } + + private Node _spriteParent; + private int _spriteIndex; + private Node _shadowParent; + private int _shadowIndex; + private Node _parent; + + public FreezeSprite(ActivityObject ao) + { + ActivityObject = ao; + _spriteParent = ao.AnimatedSprite.GetParent(); + _shadowParent = ao.ShadowSprite.GetParent(); + } + + /// + /// 冻结精灵,这样 ActivityObject 多余的节点就会被移出场景树,逻辑也会被暂停,从而优化性能 + /// + public void Freeze() + { + if (IsFrozen) + { + return; + } + + var affiliationArea = ActivityObject.AffiliationArea; + if (affiliationArea == null) + { + Debug.LogError("物体的 AffiliationArea 属性为空,不能调用 Freeze() 函数!"); + return; + } + + Position = ActivityObject.Position; + affiliationArea.RoomInfo.StaticSprite.AddFreezeSprite(this); + HandlerFreezeSprite(); + } + + /// + /// 解冻精灵,让 ActivityObject 恢复正常功能 + /// + public void Unfreeze() + { + if (!IsFrozen) + { + return; + } + + IsFrozen = false; + + ActivityObject.AffiliationArea.RoomInfo.StaticSprite.RemoveFreezeSprite(this); + HandlerUnfreezeSprite(); + } + + public void HandlerFreezeSprite() + { + IsFrozen = true; + var affiliationArea = ActivityObject.AffiliationArea; + _spriteIndex = ActivityObject.AnimatedSprite.GetIndex(); + _shadowIndex = ActivityObject.ShadowSprite.GetIndex(); + var staticSprite = affiliationArea.RoomInfo.StaticSprite; + ActivityObject.ShadowSprite.Reparent(staticSprite); + ActivityObject.AnimatedSprite.Reparent(staticSprite); + _parent = ActivityObject.GetParent(); + _parent.RemoveChild(ActivityObject); + } + + public void HandlerUnfreezeSprite() + { + IsFrozen = false; + _parent.CallDeferred(Node.MethodName.AddChild, ActivityObject); + ActivityObject.ShadowSprite.Reparent(_shadowParent); + ActivityObject.AnimatedSprite.Reparent(_spriteParent); + + if (_spriteIndex > _shadowIndex) + { + _shadowParent.MoveChild(ActivityObject.ShadowSprite, _shadowIndex); + _spriteParent.MoveChild(ActivityObject.AnimatedSprite, _spriteIndex); + } + else + { + _spriteParent.MoveChild(ActivityObject.AnimatedSprite, _spriteIndex); + _shadowParent.MoveChild(ActivityObject.ShadowSprite, _shadowIndex); + } + } + + + public void Destroy() + { + if (IsDestroyed) + { + return; + } + + IsDestroyed = true; + if (IsFrozen) + { + ActivityObject.Destroy(); + ActivityObject.AnimatedSprite.QueueFree(); + ActivityObject.ShadowSprite.QueueFree(); + } + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/map/image/RoomStaticImageCanvas.cs b/DungeonShooting_Godot/src/framework/map/image/RoomStaticImageCanvas.cs deleted file mode 100644 index 75b3da7..0000000 --- a/DungeonShooting_Godot/src/framework/map/image/RoomStaticImageCanvas.cs +++ /dev/null @@ -1,42 +0,0 @@ - -using Godot; - -public class RoomStaticImageCanvas : IDestroy -{ - public bool IsDestroyed { get; private set; } - /// - /// 画布节点实例 - /// - public ImageCanvas CanvasSprite { get; } - /// - /// 房间坐标相对于画布坐标偏移量, 单位: 像素 - /// - public Vector2I RoomOffset { get; set; } - - public RoomStaticImageCanvas(Node root, Vector2I position, int width, int height) - { - CanvasSprite = new ImageCanvas(width, height); - //CanvasSprite.Clear(new Color(1, 1, 1, 0.2f)); - CanvasSprite.GlobalPosition = position; - root.AddChild(CanvasSprite); - } - - /// - /// 将世界坐标转为画布下的坐标 - /// - public Vector2 ToImageCanvasPosition(Vector2 pos) - { - return pos - CanvasSprite.GlobalPosition; - } - - public void Destroy() - { - if (IsDestroyed) - { - return; - } - - IsDestroyed = true; - CanvasSprite.Destroy(); - } -} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/map/image/RoomStaticSprite.cs b/DungeonShooting_Godot/src/framework/map/image/RoomStaticSprite.cs new file mode 100644 index 0000000..8eeb2bb --- /dev/null +++ b/DungeonShooting_Godot/src/framework/map/image/RoomStaticSprite.cs @@ -0,0 +1,155 @@ + +using System.Collections.Generic; +using Godot; + +/// +/// RoomInfo 中用于存放静态Sprite的功能类 +/// +public partial class RoomStaticSprite : Node2D, IDestroy +{ + + public bool IsDestroyed { get; private set; } + + private readonly List> _list = new List>(); + private readonly Grid> _grid = new Grid>(); + private readonly RoomInfo _roomInfo; + //网格划分的格子大小 + private readonly Vector2I _step; + //当前残骸数量 + private int _count = 0; + //最大残骸数量 + private int _maxCount = 1000; + //每个格子中最大残骸数量 + private int _stepMaxCount = 30; + private int _num = 0; + + public RoomStaticSprite(RoomInfo roomInfo) + { + _roomInfo = roomInfo; + _step = new Vector2I(30, 30); + } + + public void Destroy() + { + if (IsDestroyed) + { + return; + } + + IsDestroyed = true; + + _grid.ForEach((x, y, data) => + { + foreach (var spriteData in data) + { + spriteData.Destroy(); + } + data.Clear(); + }); + _grid.Clear(); + QueueFree(); + } + + /// + /// 添加静态精灵 + /// + public void AddFreezeSprite(FreezeSprite freezeSprite) + { + var pos = ToGridPosition(freezeSprite.Position); + var list = _grid.Get(pos); + if (list == null) + { + list = new List(); + _grid.Set(pos, list); + _list.Add(list); + } + list.Add(freezeSprite); + _count++; + + if (list.Count > _stepMaxCount) //检测单个step中残骸是否超出最大数量 + { + var sprite = list[0]; + list.RemoveAt(0); + sprite.Destroy(); + _count--; + } + else if (_count > _maxCount) //检测所有残骸是否超出最大数量 + { + if (_num <= 0 || _list[0].Count == 0) + { + _num = 5; + _list.Sort((l1, l2) => l2.Count - l1.Count); + } + else + { + _num--; + } + + var tempList = _list[0]; + if (tempList.Count > 0) + { + var sprite = tempList[0]; + tempList.RemoveAt(0); + sprite.Destroy(); + _count--; + } + } + } + + /// + /// 移除静态精灵 + /// + public void RemoveFreezeSprite(FreezeSprite freezeSprite) + { + var pos = ToGridPosition(freezeSprite.Position); + var list = _grid.Get(pos); + if (list != null) + { + if (list.Remove(freezeSprite)) + { + _count--; + } + } + } + + public List CollisionCircle(Vector2 position, float radius, bool unfreeze = false) + { + var len = radius * radius; + var result = new List(); + var startPosition = ToGridPosition(new Vector2(position.X - radius, position.Y - radius)); + var endPosition = ToGridPosition(new Vector2(position.X + radius, position.Y + radius)); + for (var x = startPosition.X; x <= endPosition.X; x++) + { + for (var y = startPosition.Y; y <= endPosition.Y; y++) + { + var data = _grid.Get(x, y); + if (data != null) + { + for (var i = 0; i < data.Count; i++) + { + var freezeSprite = data[i]; + if (position.DistanceSquaredTo(freezeSprite.Position) < len) + { + result.Add(freezeSprite); + if (unfreeze) + { + freezeSprite.HandlerUnfreezeSprite(); + data.RemoveAt(i--); + _count--; + } + } + } + } + } + } + + return result; + } + + private Vector2I ToGridPosition(Vector2 position) + { + var x = Mathf.FloorToInt(position.X / _step.X); + var y = Mathf.FloorToInt(position.Y / _step.Y); + return new Vector2I(x * _step.X, y * _step.Y); + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/map/preinstall/RoomPreinstall.cs b/DungeonShooting_Godot/src/framework/map/preinstall/RoomPreinstall.cs index 409eeab..987771d 100644 --- a/DungeonShooting_Godot/src/framework/map/preinstall/RoomPreinstall.cs +++ b/DungeonShooting_Godot/src/framework/map/preinstall/RoomPreinstall.cs @@ -120,7 +120,7 @@ mark.DerivedAttr = new Dictionary(); mark.VerticalSpeed = markInfoItem.VerticalSpeed; mark.Altitude = markInfoItem.Altitude; - mark.ActivityType = (ActivityType)ExcelConfig.ActivityObject_Map[markInfoItem.Id].Type; + mark.ActivityType = (ActivityType)ExcelConfig.ActivityBase_Map[markInfoItem.Id].Type; if (mark.ActivityType == ActivityType.Enemy) //敌人类型 { diff --git a/DungeonShooting_Godot/src/framework/map/room/RoomInfo.cs b/DungeonShooting_Godot/src/framework/map/room/RoomInfo.cs index 93f52da..8883d1d 100644 --- a/DungeonShooting_Godot/src/framework/map/room/RoomInfo.cs +++ b/DungeonShooting_Godot/src/framework/map/room/RoomInfo.cs @@ -76,9 +76,19 @@ public AffiliationArea AffiliationArea; /// + /// 静态渲染精灵根节点, 用于放置sprite + /// + public RoomStaticSprite StaticSprite; + + /// /// 静态精灵绘制画布 /// - public RoomStaticImageCanvas StaticImageCanvas; + public ImageCanvas StaticImageCanvas; + + /// + /// 房间坐标相对于画布坐标偏移量, 单位: 像素 + /// + public Vector2I RoomOffset; /// /// 房间迷雾 @@ -263,6 +273,14 @@ return Size.Y * GameConfig.TileCellSize; } + /// + /// 将世界坐标转为画布下的坐标 + /// + public Vector2 ToImageCanvasPosition(Vector2 pos) + { + return pos - StaticImageCanvas.Position; + } + public void Destroy() { if (IsDestroyed) @@ -296,6 +314,12 @@ { StaticImageCanvas.Destroy(); } + + // + if (StaticSprite != null) + { + StaticSprite.Destroy(); + } //销毁迷雾 if (RoomFogMask != null) diff --git a/DungeonShooting_Godot/src/framework/pool/IPoolItem.cs b/DungeonShooting_Godot/src/framework/pool/IPoolItem.cs new file mode 100644 index 0000000..8ff53da --- /dev/null +++ b/DungeonShooting_Godot/src/framework/pool/IPoolItem.cs @@ -0,0 +1,23 @@ + +/// +/// 可被对象池池回收的实例对象接口 +/// +public interface IPoolItem : IDestroy +{ + /// + /// 是否已经回收 + /// + bool IsRecycled { get; set; } + /// + /// 对象唯一标识,用于在对象池中区分对象类型,可以是资源路径,也可以是配置表id + /// + string Logotype { get; } + /// + /// 当物体被回收时调用,也就是进入对象池 + /// + void OnReclaim(); + /// + /// 离开对象池时调用 + /// + void OnLeavePool(); +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/pool/ObjectPool.cs b/DungeonShooting_Godot/src/framework/pool/ObjectPool.cs new file mode 100644 index 0000000..27f8e4c --- /dev/null +++ b/DungeonShooting_Godot/src/framework/pool/ObjectPool.cs @@ -0,0 +1,71 @@ + +using System.Collections.Generic; + +/// +/// 对象池,用于获取和回收常用对象,避免每次都创建一个新的 +/// +public static class ObjectPool +{ + private static Dictionary> _pool = new Dictionary>(); + + /// + /// 回收一个对象 + /// + public static void Reclaim(IPoolItem poolItem) + { + var logotype = poolItem.Logotype; + if (!_pool.TryGetValue(logotype, out var poolItems)) + { + poolItems = new Stack(); + _pool.Add(logotype, poolItems); + } + + poolItems.Push(poolItem); + poolItem.IsRecycled = true; + poolItem.OnReclaim(); + } + + /// + /// 根据标识从池中取出一个实例,如果没有该标识类型的实例,则返回null + /// + public static IPoolItem GetItem(string logotype) + { + if (_pool.TryGetValue(logotype, out var poolItems)) + { + if (poolItems.Count > 0) + { + var poolItem = poolItems.Pop(); + poolItem.IsRecycled = false; + poolItem.OnLeavePool(); + return poolItem; + } + } + + return null; + } + + /// + /// 根据标识从池中取出一个实例,如果没有该标识类型的实例,则返回null + /// + public static T GetItem(string logotype) where T : IPoolItem + { + return (T)GetItem(logotype); + } + + /// + /// 销毁所有池中的物体 + /// + public static void DisposeAllItem() + { + foreach (var keyValuePair in _pool) + { + var poolItems = keyValuePair.Value; + while (poolItems.Count > 0) + { + var item = poolItems.Pop(); + item.Destroy(); + } + } + _pool.Clear(); + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/framework/ui/UiBase.cs b/DungeonShooting_Godot/src/framework/ui/UiBase.cs index 28ee1fd..17e6d7e 100644 --- a/DungeonShooting_Godot/src/framework/ui/UiBase.cs +++ b/DungeonShooting_Godot/src/framework/ui/UiBase.cs @@ -210,10 +210,7 @@ Process(newDelta); //协程更新 - if (_coroutineList != null) - { - ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, newDelta); - } + ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, newDelta); } /// diff --git a/DungeonShooting_Godot/src/game/AnimatorNames.cs b/DungeonShooting_Godot/src/game/AnimatorNames.cs index 8ba547d..b393c9f 100644 --- a/DungeonShooting_Godot/src/game/AnimatorNames.cs +++ b/DungeonShooting_Godot/src/game/AnimatorNames.cs @@ -60,4 +60,12 @@ /// 显示动画 /// public const string Show = "show"; + /// + /// 播放特效 + /// + public const string Play = "play"; + /// + /// 物体移动 + /// + public const string Move = "move"; } \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/GameApplication.cs b/DungeonShooting_Godot/src/game/GameApplication.cs index 9e4266c..976ffb4 100644 --- a/DungeonShooting_Godot/src/game/GameApplication.cs +++ b/DungeonShooting_Godot/src/game/GameApplication.cs @@ -36,9 +36,14 @@ /// 是否开启调试 /// [ExportGroup("Debug")] - [Export] public bool Debug; + [Export] public bool IsDebug; /// + /// 游戏目标帧率 + /// + public int TargetFps { get; private set; } = 60; + + /// /// 鼠标指针 /// public Cursor Cursor { get; private set; } @@ -84,13 +89,12 @@ public GameApplication() { Instance = this; + TargetFps = (int)DisplayServer.ScreenGetRefreshRate(); //初始化配置表 ExcelConfig.Init(); //初始化房间配置数据 InitRoomConfig(); - //初始化 ActivityObject - ActivityObject.InitActivity(); //初始化武器数据 Weapon.InitWeaponAttribute(); @@ -106,19 +110,19 @@ //随机化种子 //GD.Randomize(); //固定帧率 - Engine.MaxFps = 60; + //Engine.MaxFps = TargetFps; //调试绘制开关 - ActivityObject.IsDebug = Debug; + //IsDebug = true; + ActivityObject.IsDebug = IsDebug; //Engine.TimeScale = 0.2f; - //调整窗口分辨率 OnWindowSizeChanged(); RefreshSubViewportSize(); //窗体大小改变 GetWindow().SizeChanged += OnWindowSizeChanged; - + ImageCanvas.Init(GetTree().CurrentScene); - + //初始化ui UiManager.Init(); //调试Ui @@ -145,10 +149,7 @@ SoundManager.Update(newDelta); //协程更新 - if (_coroutineList != null) - { - ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, newDelta); - } + ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, newDelta); } /// @@ -171,11 +172,15 @@ /// public void DestroyWorld() { + //销毁所有物体 if (World != null) { ClearWorld(); World.QueueFree(); } + + //销毁池中所有物体 + ObjectPool.DisposeAllItem(); World = null; } @@ -296,7 +301,6 @@ //清理世界 private void ClearWorld() { - var childCount = World.NormalLayer.GetChildCount(); for (var i = 0; i < childCount; i++) { diff --git a/DungeonShooting_Godot/src/game/PhysicsLayer.cs b/DungeonShooting_Godot/src/game/PhysicsLayer.cs index a96e34d..f181de2 100644 --- a/DungeonShooting_Godot/src/game/PhysicsLayer.cs +++ b/DungeonShooting_Godot/src/game/PhysicsLayer.cs @@ -36,9 +36,9 @@ ///
public const uint OnHand = 0b1000000; /// - /// 弹壳 + /// 各种碎屑,包括弹壳,敌人死亡碎片,爆炸碎片等 /// - public const uint Shell = 0b10000000; + public const uint Debris = 0b10000000; /// /// 投抛中 /// diff --git a/DungeonShooting_Godot/src/game/activity/bullet/Bullet.cs b/DungeonShooting_Godot/src/game/activity/bullet/Bullet.cs deleted file mode 100644 index 0cf2a33..0000000 --- a/DungeonShooting_Godot/src/game/activity/bullet/Bullet.cs +++ /dev/null @@ -1,181 +0,0 @@ -using System.Collections; -using Godot; - -/// -/// 子弹类 -/// -[Tool] -public partial class Bullet : ActivityObject -{ - /// - /// 碰撞区域 - /// - [Export, ExportFillNode] - public Area2D CollisionArea { get; set; } - - /// - /// 攻击的层级 - /// - public uint AttackLayer - { - get => CollisionArea.CollisionMask; - set => CollisionArea.CollisionMask = value; - } - - /// - /// 发射该子弹的武器 - /// - public Weapon Weapon { get; private set; } - - /// - /// 发射该子弹的角色 - /// - public Role Role { get; private set; } - - /// - /// 最小伤害 - /// - public int MinHarm { get; set; } = 4; - - /// - /// 最大伤害 - /// - public int MaxHarm { get; set; } = 4; - - /// - /// 发射该子弹的角色是否是Ai - /// - public bool TriggerRoleIsAi { get; set; } - - // 最大飞行距离 - private float MaxDistance; - - // 子弹飞行速度 - private float FlySpeed; - - //当前子弹已经飞行的距离 - private float CurrFlyDistance = 0; - - /// - /// 初始化子弹属性 - /// - /// 触发开火的角色 - /// 射出该子弹的武器 - /// 速度 - /// 最大飞行距离 - /// 位置 - /// 角度 - /// 攻击目标层级 - public void Init(bool triggerIsAi, Weapon weapon, float speed, float maxDistance, Vector2 position, float rotation, uint targetLayer) - { - TriggerRoleIsAi = triggerIsAi; - Weapon = weapon; - Role = weapon.Master; - AttackLayer = targetLayer; - CollisionArea.AreaEntered += OnArea2dEntered; - - if (!triggerIsAi) //只有玩家使用该武器才能获得正常速度的子弹 - { - FlySpeed = speed; - } - else - { - FlySpeed = speed * weapon.AiUseAttribute.AiAttackAttr.BulletSpeedScale; - } - MaxDistance = maxDistance; - Position = position; - Rotation = rotation; - ShadowOffset = new Vector2(0, 5); - BasisVelocity = new Vector2(FlySpeed, 0).Rotated(Rotation); - - //如果子弹会对玩家造成伤害, 则显示红色描边 - if (Player.Current.CollisionWithMask(targetLayer)) - { - ShowOutline = true; - OutlineColor = new Color(1, 0, 0); - StartCoroutine(BorderFlashes()); - } - } - - private IEnumerator BorderFlashes() - { - while (true) - { - ShowOutline = !ShowOutline; - yield return new WaitForSeconds(0.12f); - } - } - - /// - /// 播放子弹消失的特效 - /// - public virtual void PlayDisappearEffect() - { - var packedScene = ResourceManager.Load(ResourcePath.prefab_effect_weapon_BulletDisappear_tscn); - var node = packedScene.Instantiate(); - node.GlobalPosition = GlobalPosition; - node.AddToActivityRoot(RoomLayerEnum.YSortLayer); - } - - protected override void PhysicsProcessOver(float delta) - { - //移动 - var lastSlideCollision = GetLastSlideCollision(); - //撞到墙 - if (lastSlideCollision != null) - { - //创建粒子特效 - var packedScene = ResourceManager.Load(ResourcePath.prefab_effect_weapon_BulletSmoke_tscn); - var smoke = packedScene.Instantiate(); - smoke.GlobalPosition = lastSlideCollision.GetPosition(); - smoke.GlobalRotation = lastSlideCollision.GetNormal().Angle(); - smoke.AddToActivityRoot(RoomLayerEnum.YSortLayer); - - Destroy(); - return; - } - //距离太大, 自动销毁 - CurrFlyDistance += FlySpeed * delta; - if (CurrFlyDistance >= MaxDistance) - { - PlayDisappearEffect(); - Destroy(); - } - } - - private void OnArea2dEntered(Area2D other) - { - var role = other.AsActivityObject(); - if (role != null) - { - var packedScene = ResourceManager.Load(ResourcePath.prefab_effect_weapon_BulletDisappear_tscn); - var node = packedScene.Instantiate(); - node.GlobalPosition = GlobalPosition; - node.AddToActivityRoot(RoomLayerEnum.YSortLayer); - - //计算子弹造成的伤害 - var damage = Utils.Random.RandomRangeInt(MinHarm, MaxHarm); - if (Role != null) - { - damage = Role.RoleState.CallCalcDamageEvent(damage); - } - - //击退 - if (role is not Player) //目标不是玩家才会触发击退 - { - var attr = TriggerRoleIsAi ? Weapon.AiUseAttribute : Weapon.PlayerUseAttribute; - var repel = Utils.Random.RandomConfigRange(attr.RepelRnage); - role.MoveController.AddForce(Vector2.FromAngle(BasisVelocity.Angle()) * repel, repel * 2); - } - - //造成伤害 - role.CallDeferred(nameof(Role.Hurt), damage, Rotation); - Destroy(); - } - } - - protected override void OnDestroy() - { - StopAllCoroutine(); - } -} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/bullet/BulletAttribute.cs b/DungeonShooting_Godot/src/game/activity/bullet/BulletAttribute.cs deleted file mode 100644 index aa30af1..0000000 --- a/DungeonShooting_Godot/src/game/activity/bullet/BulletAttribute.cs +++ /dev/null @@ -1,5 +0,0 @@ - -public class BulletAttribute -{ - -} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/bullet/explode/Explode.cs b/DungeonShooting_Godot/src/game/activity/bullet/explode/Explode.cs new file mode 100644 index 0000000..56a6963 --- /dev/null +++ b/DungeonShooting_Godot/src/game/activity/bullet/explode/Explode.cs @@ -0,0 +1,165 @@ + +using Config; +using Godot; + +/// +/// 爆炸 +/// +public partial class Explode : Area2D, IPoolItem +{ + public bool IsRecycled { get; set; } + public string Logotype { get; set; } + + public bool IsDestroyed { get; private set; } + + /// + /// 动画播放器 + /// + public AnimationPlayer AnimationPlayer { get; private set; } + /// + /// 碰撞器 + /// + public CollisionShape2D CollisionShape { get; private set; } + /// + /// 碰撞器形状对象 + /// + public CircleShape2D CircleShape { get; private set; } + + /// + /// 爆炸攻击的层级 + /// + public uint AttackLayer { get; private set; } + + + private bool _init = false; + private float _hitRadius; + private int _minHarm; + private int _maxHarm; + private float _repelledRadius; + private float _maxRepelled; + + public void Destroy() + { + if (IsDestroyed) + { + return; + } + + IsDestroyed = true; + QueueFree(); + } + + /// + /// 初始化爆炸数据 + /// + /// 爆炸所在区域 + /// 攻击的层级 + /// 伤害半径 + /// 最小伤害 + /// 最大伤害 + /// 击退半径 + /// 最大击退速度 + public void Init(AffiliationArea affiliationArea, uint attackLayer, float hitRadius, int minHarm, int maxHarm, float repelledRadius, float maxRepelled) + { + if (!_init) + { + _init = true; + AnimationPlayer = GetNode("AnimationPlayer"); + CollisionShape = GetNode("CollisionShape2D"); + CircleShape = (CircleShape2D)CollisionShape.Shape; + AnimationPlayer.AnimationFinished += OnAnimationFinish; + BodyEntered += OnBodyEntered; + } + + AttackLayer = attackLayer; + _hitRadius = hitRadius; + _minHarm = minHarm; + _maxHarm = maxHarm; + _repelledRadius = repelledRadius; + _maxRepelled = maxRepelled; + CollisionMask = attackLayer | PhysicsLayer.Prop | PhysicsLayer.Debris; + CircleShape.Radius = Mathf.Max(hitRadius, maxRepelled); + + //冲击波 + if (affiliationArea != null) + { + ShockWave(affiliationArea); + } + } + + /// + /// 播放爆炸, triggerRole 为触发该爆炸的角色 + /// + public void RunPlay(Role triggerRole = null) + { + GameCamera.Main.CreateShake(new Vector2(6, 6), 0.7f, true); + AnimationPlayer.Play(AnimatorNames.Play); + //播放爆炸音效 + SoundManager.PlaySoundByConfig("explosion0002", Position, triggerRole); + } + + //爆炸冲击波 + private void ShockWave(AffiliationArea affiliationArea) + { + var position = Position; + var freezeSprites = affiliationArea.RoomInfo.StaticSprite.CollisionCircle(position, _repelledRadius, true); + foreach (var freezeSprite in freezeSprites) + { + var temp = freezeSprite.Position - position; + freezeSprite.ActivityObject.MoveController.AddForce(temp.Normalized() * _maxRepelled * (_repelledRadius - temp.Length()) / _repelledRadius); + } + } + + public void OnReclaim() + { + GetParent().RemoveChild(this); + } + + public void OnLeavePool() + { + + } + + private void OnAnimationFinish(StringName name) + { + if (name == AnimatorNames.Play) + { + ObjectPool.Reclaim(this); + } + } + + private void OnBodyEntered(Node2D node) + { + var o = node.AsActivityObject(); + if (o != null) + { + var temp = o.Position - Position; + var len = temp.Length(); + var angle = temp.Angle(); + + if (len <= _hitRadius) //在伤害半径内 + { + if (o is Role role) //是角色 + { + role.CallDeferred(nameof(role.Hurt), Utils.Random.RandomRangeInt(_minHarm, _maxHarm), angle); + } + else if (o is Bullet bullet) //是子弹 + { + if (bullet is BoomBullet boomBullet) //如果是爆炸子弹, 则直接销毁 + { + boomBullet.PlayBoom(); + } + bullet.Destroy(); + return; + } + } + + if (len <= _repelledRadius) //击退半径内 + { + var repelled = (_repelledRadius - len) / _repelledRadius * _maxRepelled; + //o.MoveController.SetAllVelocity(Vector2.Zero); + o.MoveController.AddForce(Vector2.FromAngle(angle) * repelled); + } + } + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/bullet/laser/Laser.cs b/DungeonShooting_Godot/src/game/activity/bullet/laser/Laser.cs new file mode 100644 index 0000000..fbd2791 --- /dev/null +++ b/DungeonShooting_Godot/src/game/activity/bullet/laser/Laser.cs @@ -0,0 +1,157 @@ +using System.Collections; +using System.Collections.Generic; +using Config; +using Godot; + +/// +/// 激光子弹 +/// +public partial class Laser : Area2D, IBullet +{ + public CollisionShape2D Collision { get; private set; } + public Sprite2D LineSprite { get; private set; } + public RectangleShape2D Shape { get; private set; } + + public uint AttackLayer + { + get => CollisionMask; + set => CollisionMask = value; + } + + public BulletData BulletData { get; private set; } + + public bool IsDestroyed { get; private set; } + + public float Width { get; set; } + + //开启的协程 + private List _coroutineList; + private float _pixelScale; + private float _speed = 2000; + + public override void _Ready() + { + Collision = GetNodeOrNull("CollisionShape2D"); + Collision.Disabled = true; + Shape = Collision.Shape as RectangleShape2D; + LineSprite = GetNodeOrNull("LineSprite"); + _pixelScale = 1f / LineSprite.Texture.GetHeight(); + + AreaEntered += OnArea2dEntered; + } + + public void InitData(BulletData data, uint attackLayer) + { + InitData(data, attackLayer, 5); + } + + public void InitData(BulletData data, uint attackLayer, float width) + { + BulletData = data; + AttackLayer = attackLayer; + + Position = data.Position; + Rotation = data.Rotation; + + //计算射线最大距离, 也就是撞到墙壁的距离 + var targetPosition = data.Position + Vector2.FromAngle(data.Rotation) * data.MaxDistance; + var parameters = PhysicsRayQueryParameters2D.Create(data.Position, targetPosition, PhysicsLayer.Wall); + var result = GetWorld2D().DirectSpaceState.IntersectRay(parameters); + float distance; + if (result != null && result.TryGetValue("position", out var point)) + { + distance = Position.DistanceTo((Vector2)point); + } + else + { + distance = data.MaxDistance; + } + + Collision.SetDeferred(CollisionShape2D.PropertyName.Disabled, false); + Collision.Position = Vector2.Zero; + Shape.Size = Vector2.Zero;; + LineSprite.Scale = new Vector2(0, width * _pixelScale); + + //如果子弹会对玩家造成伤害, 则显示成红色 + if (Player.Current.CollisionWithMask(attackLayer)) + { + LineSprite.Modulate = new Color(2.5f, 0.5f, 0.5f); + } + + //激光飞行时间 + var time = distance / _speed; + + var tween = CreateTween(); + tween.SetParallel(); + tween.TweenProperty(LineSprite, "scale", new Vector2(distance, width * _pixelScale), time); + tween.TweenProperty(Collision, "position", new Vector2(distance * 0.5f, 0), time); + tween.TweenProperty(Shape, "size", new Vector2(distance, width), time); + tween.Chain(); + //持续时间 + // tween.TweenInterval(0.2f); + // tween.Chain(); + tween.TweenCallback(Callable.From(() => + { + Collision.SetDeferred(CollisionShape2D.PropertyName.Disabled, false); + })); + tween.Chain(); + tween.TweenProperty(LineSprite, "scale", new Vector2(distance, 0), 0.3f); + tween.Chain(); + tween.TweenCallback(Callable.From(() => + { + Destroy(); + })); + tween.Play(); + } + + public override void _Process(double delta) + { + ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, (float)delta); + } + + public void Destroy() + { + if (IsDestroyed) + { + return; + } + + QueueFree(); + } + + private void OnArea2dEntered(Area2D other) + { + var role = other.AsActivityObject(); + if (role != null) + { + //计算子弹造成的伤害 + var damage = Utils.Random.RandomRangeInt(BulletData.MinHarm, BulletData.MaxHarm); + if (BulletData.TriggerRole != null) + { + damage = BulletData.TriggerRole.RoleState.CallCalcDamageEvent(damage); + } + //造成伤害 + role.CallDeferred(nameof(Role.Hurt), damage, Rotation); + } + } + + public long StartCoroutine(IEnumerator able) + { + return ProxyCoroutineHandler.ProxyStartCoroutine(ref _coroutineList, able); + } + + public void StopCoroutine(long coroutineId) + { + ProxyCoroutineHandler.ProxyStopCoroutine(ref _coroutineList, coroutineId); + } + + public bool IsCoroutineOver(long coroutineId) + { + return ProxyCoroutineHandler.ProxyIsCoroutineOver(ref _coroutineList, coroutineId); + } + + public void StopAllCoroutine() + { + ProxyCoroutineHandler.ProxyStopAllCoroutine(ref _coroutineList); + } +} diff --git a/DungeonShooting_Godot/src/game/activity/bullet/normal/BoomBullet.cs b/DungeonShooting_Godot/src/game/activity/bullet/normal/BoomBullet.cs new file mode 100644 index 0000000..b997951 --- /dev/null +++ b/DungeonShooting_Godot/src/game/activity/bullet/normal/BoomBullet.cs @@ -0,0 +1,70 @@ + +using Godot; + +/// +/// 爆炸子弹 +/// +[Tool] +public partial class BoomBullet : Bullet +{ + public override void OnLimeOver() + { + PlayBoom(); + Destroy(); + } + + public override void OnMaxDistance() + { + PlayBoom(); + Destroy(); + } + + public override void OnCollisionTarget(ActivityObject o) + { + PlayBoom(); + Destroy(); + } + + public override void OnMoveCollision(KinematicCollision2D lastSlideCollision) + { + CurrentBounce++; + if (CurrentBounce > BulletData.BounceCount) //反弹次数超过限制 + { + PlayBoom(); + } + else + { + //播放撞击音效 + SoundManager.PlaySoundByConfig("collision0001", Position, BulletData.TriggerRole); + } + } + + protected override void OnFallToGround() + { + //播放撞击音效 + SoundManager.PlaySoundByConfig("collision0001", Position, BulletData.TriggerRole); + } + + /// + /// 播放爆炸 + /// + public void PlayBoom() + { + var explode = ObjectManager.GetExplode(ResourcePath.prefab_bullet_explode_Explode0001_tscn); + var pos = Position; + explode.Position = pos; + explode.RotationDegrees = Utils.Random.RandomRangeInt(0, 360); + explode.AddToActivityRootDeferred(RoomLayerEnum.YSortLayer); + explode.Init(BulletData.TriggerRole?.AffiliationArea, AttackLayer, 25, BulletData.MinHarm, BulletData.MaxHarm, 50, 150); + explode.RunPlay(BulletData.TriggerRole); + if (AffiliationArea != null) + { + var texture = ResourceManager.LoadTexture2D(ResourcePath.resource_sprite_effects_explode_Explode_pit0001_png); + var tempPos = AffiliationArea.RoomInfo.ToImageCanvasPosition(pos); + AffiliationArea.RoomInfo.StaticImageCanvas.DrawImageInCanvas( + texture, null, tempPos.X, tempPos.Y, Utils.Random.RandomRangeInt(0, 360), + texture.GetWidth() / 2, texture.GetHeight() / 2, false + ); + } + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/bullet/normal/Bullet.cs b/DungeonShooting_Godot/src/game/activity/bullet/normal/Bullet.cs new file mode 100644 index 0000000..0c24cdc --- /dev/null +++ b/DungeonShooting_Godot/src/game/activity/bullet/normal/Bullet.cs @@ -0,0 +1,209 @@ +using System.Collections; +using Godot; + +/// +/// 子弹类 +/// +[Tool] +public partial class Bullet : ActivityObject, IBullet +{ + /// + /// 碰撞区域 + /// + [Export, ExportFillNode] + public Area2D CollisionArea { get; set; } + + /// + /// 攻击的层级 + /// + public uint AttackLayer + { + get => CollisionArea.CollisionMask; + set => CollisionArea.CollisionMask = value; + } + + public BulletData BulletData { get; private set; } + + /// + /// 当前反弹次数 + /// + public int CurrentBounce { get; protected set; } = 0; + + //当前子弹已经飞行的距离 + private float CurrFlyDistance = 0; + + public override void OnInit() + { + BounceLockRotation = false; + CollisionArea.AreaEntered += OnArea2dEntered; + } + + public virtual void InitData(BulletData data, uint attackLayer) + { + BulletData = data; + AttackLayer = attackLayer; + Rotation = data.Rotation; + + float altitude; + var triggerRole = data.TriggerRole; + if (triggerRole != null) + { + altitude = -triggerRole.MountPoint.Position.Y; + if (triggerRole.AffiliationArea != null) //设置所属区域 + { + triggerRole.AffiliationArea.InsertItem(this); + } + } + else + { + altitude = 8; + } + + Position = data.Position + new Vector2(0, altitude); + Altitude = altitude; + if (data.VerticalSpeed != 0) + { + VerticalSpeed = data.VerticalSpeed; + } + EnableVerticalMotion = data.BulletBase.UseGravity; + + //BasisVelocity = new Vector2(data.FlySpeed, 0).Rotated(Rotation); + MoveController.AddForce(new Vector2(data.FlySpeed, 0).Rotated(Rotation)); + + //如果子弹会对玩家造成伤害, 则显示红色描边 + if (Player.Current.CollisionWithMask(attackLayer)) + { + ShowBorderFlashes(); + } + PutDown(RoomLayerEnum.YSortLayer); + //播放子弹移动动画 + PlaySpriteAnimation(AnimatorNames.Move); + //强制更新下坠逻辑处理 + UpdateFall((float)GetProcessDeltaTime()); + + //过期销毁 + if (data.LifeTime > 0) + { + this.CallDelay(data.LifeTime, OnLimeOver); + } + } + + + public override void OnMoveCollision(KinematicCollision2D collision) + { + CurrentBounce++; + if (CurrentBounce > BulletData.BounceCount) //反弹次数超过限制 + { + //创建粒子特效 + var packedScene = ResourceManager.Load(ResourcePath.prefab_effect_weapon_BulletSmoke_tscn); + var smoke = packedScene.Instantiate(); + var rotated = AnimatedSprite.Position.Rotated(Rotation); + smoke.GlobalPosition = collision.GetPosition() + new Vector2(0, rotated.Y); + smoke.GlobalRotation = collision.GetNormal().Angle(); + smoke.AddToActivityRoot(RoomLayerEnum.YSortLayer); + Destroy(); + } + } + + /// + /// 碰到目标 + /// + public virtual void OnCollisionTarget(ActivityObject o) + { + if (o is Role role) + { + PlayDisappearEffect(); + + //计算子弹造成的伤害 + var damage = Utils.Random.RandomRangeInt(BulletData.MinHarm, BulletData.MaxHarm); + if (BulletData.TriggerRole != null) + { + damage = BulletData.TriggerRole.RoleState.CallCalcDamageEvent(damage); + } + + //击退 + if (role is not Player) //目标不是玩家才会触发击退 + { + var attr = BulletData.Weapon.GetUseAttribute(BulletData.TriggerRole); + var repel = Utils.Random.RandomConfigRange(attr.Bullet.RepelRnage); + if (repel != 0) + { + //role.MoveController.AddForce(Vector2.FromAngle(BasisVelocity.Angle()) * repel); + role.MoveController.AddForce(Vector2.FromAngle(Velocity.Angle()) * repel); + } + } + + //造成伤害 + role.CallDeferred(nameof(Role.Hurt), damage, Rotation); + Destroy(); + } + } + + /// + /// 到达最大运行距离 + /// + public virtual void OnMaxDistance() + { + PlayDisappearEffect(); + Destroy(); + } + + /// + /// 子弹生命周期结束 + /// + public virtual void OnLimeOver() + { + PlayDisappearEffect(); + Destroy(); + } + + /// + /// 显示红色描边 + /// + public void ShowBorderFlashes() + { + ShowOutline = true; + OutlineColor = new Color(1, 0, 0); + StartCoroutine(BorderFlashes()); + } + + private IEnumerator BorderFlashes() + { + while (true) + { + ShowOutline = !ShowOutline; + yield return new WaitForSeconds(0.12f); + } + } + + /// + /// 播放子弹消失的特效 + /// + public virtual void PlayDisappearEffect() + { + var packedScene = ResourceManager.Load(ResourcePath.prefab_effect_weapon_BulletDisappear_tscn); + var node = packedScene.Instantiate(); + node.GlobalPosition = AnimatedSprite.GlobalPosition; + node.AddToActivityRoot(RoomLayerEnum.YSortLayer); + } + + protected override void Process(float delta) + { + //距离太大, 自动销毁 + CurrFlyDistance += BulletData.FlySpeed * delta; + if (CurrFlyDistance >= BulletData.MaxDistance) + { + OnMaxDistance(); + } + } + + private void OnArea2dEntered(Area2D other) + { + if (IsDestroyed) + { + return; + } + var activityObject = other.AsActivityObject(); + OnCollisionTarget(activityObject); + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/bullet/normal/BulletAttribute.cs b/DungeonShooting_Godot/src/game/activity/bullet/normal/BulletAttribute.cs new file mode 100644 index 0000000..aa30af1 --- /dev/null +++ b/DungeonShooting_Godot/src/game/activity/bullet/normal/BulletAttribute.cs @@ -0,0 +1,5 @@ + +public class BulletAttribute +{ + +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/bullet/normal/IBullet.cs b/DungeonShooting_Godot/src/game/activity/bullet/normal/IBullet.cs new file mode 100644 index 0000000..6e74709 --- /dev/null +++ b/DungeonShooting_Godot/src/game/activity/bullet/normal/IBullet.cs @@ -0,0 +1,18 @@ + +using Config; + +public interface IBullet : IDestroy, ICoroutine +{ + /// + /// 攻击的层级 + /// + uint AttackLayer { get; set; } + /// + /// 子弹数据 + /// + BulletData BulletData { get; } + /// + /// 初始化子弹数据 + /// + void InitData(BulletData data, uint attackLayer); +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/prop/active/ActiveProp.cs b/DungeonShooting_Godot/src/game/activity/prop/active/ActiveProp.cs index ac660c5..ea3f772 100644 --- a/DungeonShooting_Godot/src/game/activity/prop/active/ActiveProp.cs +++ b/DungeonShooting_Godot/src/game/activity/prop/active/ActiveProp.cs @@ -131,7 +131,7 @@ { } - protected override void ProcessOver(float delta) + protected override void Process(float delta) { RunUpdate(delta); } diff --git a/DungeonShooting_Godot/src/game/activity/role/Role.cs b/DungeonShooting_Godot/src/game/activity/role/Role.cs index 7269052..f9a1f9f 100644 --- a/DungeonShooting_Godot/src/game/activity/role/Role.cs +++ b/DungeonShooting_Godot/src/game/activity/role/Role.cs @@ -20,7 +20,7 @@ /// /// 默认攻击对象层级 /// - public const uint DefaultAttackLayer = PhysicsLayer.Player | PhysicsLayer.Enemy | PhysicsLayer.Wall | PhysicsLayer.Prop; + public const uint DefaultAttackLayer = PhysicsLayer.Player | PhysicsLayer.Enemy | PhysicsLayer.Wall; /// /// 伤害区域 @@ -439,6 +439,10 @@ protected override void Process(float delta) { + if (IsDie) + { + return; + } if (_rollCoolingTimer > 0) { _rollCoolingTimer -= delta; @@ -562,12 +566,16 @@ } //主动道具调用更新 - var props = (Prop[])ActivePropsPack.ItemSlot.Clone(); - foreach (var prop in props) + var props = ActivePropsPack.ItemSlot; + if (props.Length > 0) { - if (prop != null && !prop.IsDestroyed) + props = (ActiveProp[])props.Clone(); + foreach (var prop in props) { - prop.PackProcess(delta); + if (prop != null && !prop.IsDestroyed) + { + prop.PackProcess(delta); + } } } } @@ -983,7 +991,7 @@ /// 受到伤害, 如果是在碰撞信号处理函数中调用该函数, 请使用 CallDeferred 来延时调用, 否则很有可能导致报错 /// /// 伤害的量 - /// 角度 + /// 伤害角度(弧度制) public virtual void Hurt(int damage, float angle) { //受伤闪烁, 无敌状态 @@ -1166,7 +1174,7 @@ var repel = Utils.Random.RandomConfigRange(attr.MeleeAttackRepelRnage); var position = role.GlobalPosition - MountPoint.GlobalPosition; var v2 = position.Normalized() * repel; - role.MoveController.AddForce(v2, repel * 2); + role.MoveController.AddForce(v2); } role.CallDeferred(nameof(Hurt), damage, (role.GetCenterPosition() - GlobalPosition).Angle()); diff --git a/DungeonShooting_Godot/src/game/activity/role/SubLine.cs b/DungeonShooting_Godot/src/game/activity/role/SubLine.cs index 33bd409..5f9dd84 100644 --- a/DungeonShooting_Godot/src/game/activity/role/SubLine.cs +++ b/DungeonShooting_Godot/src/game/activity/role/SubLine.cs @@ -115,7 +115,7 @@ StopCoroutine(_cid); _cid = 0; } - _range = Utils.GetConfigRangeEnd(weapon.Attribute.BulletDistanceRange); + _range = Utils.GetConfigRangeEnd(weapon.Attribute.Bullet.DistanceRange); _line2D.DefaultColor = _color; } } diff --git a/DungeonShooting_Godot/src/game/activity/role/enemy/Enemy.cs b/DungeonShooting_Godot/src/game/activity/role/enemy/Enemy.cs index 4736952..8de6844 100644 --- a/DungeonShooting_Godot/src/game/activity/role/enemy/Enemy.cs +++ b/DungeonShooting_Godot/src/game/activity/role/enemy/Enemy.cs @@ -74,7 +74,7 @@ IsAi = true; StateController = AddComponent>(); - AttackLayer = PhysicsLayer.Wall | PhysicsLayer.Prop | PhysicsLayer.Player; + AttackLayer = PhysicsLayer.Wall | PhysicsLayer.Player; EnemyLayer = PhysicsLayer.Player; Camp = CampEnum.Camp2; @@ -150,7 +150,10 @@ protected override void Process(float delta) { base.Process(delta); - + if (IsDie) + { + return; + } //目标在视野内的时间 var currState = StateController.CurrState; if (currState == AiStateEnum.AiSurround || currState == AiStateEnum.AiFollowUp) @@ -379,7 +382,7 @@ if (WeaponPack.ActiveItem != null) { var attribute = WeaponPack.ActiveItem.Attribute; - return Mathf.Lerp(Utils.GetConfigRangeStart(attribute.BulletDistanceRange), Utils.GetConfigRangeEnd(attribute.BulletDistanceRange), weight); + return Mathf.Lerp(Utils.GetConfigRangeStart(attribute.Bullet.DistanceRange), Utils.GetConfigRangeEnd(attribute.Bullet.DistanceRange), weight); } return 0; @@ -509,5 +512,4 @@ { _lockTargetTime = time; } - } diff --git a/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiFollowUpState.cs b/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiFollowUpState.cs index 50003ec..02d1de1 100644 --- a/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiFollowUpState.cs +++ b/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiFollowUpState.cs @@ -110,7 +110,7 @@ Master.EnemyAttack(); //距离够近, 可以切换到环绕模式 - if (Master.GlobalPosition.DistanceSquaredTo(playerPos) <= Mathf.Pow(Utils.GetConfigRangeStart(weapon.Attribute.BulletDistanceRange), 2) * 0.7f) + if (Master.GlobalPosition.DistanceSquaredTo(playerPos) <= Mathf.Pow(Utils.GetConfigRangeStart(weapon.Attribute.Bullet.DistanceRange), 2) * 0.7f) { ChangeState(AiStateEnum.AiSurround); } diff --git a/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiSurroundState.cs b/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiSurroundState.cs index 321419f..967cc65 100644 --- a/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiSurroundState.cs +++ b/DungeonShooting_Godot/src/game/activity/role/enemy/state/AiSurroundState.cs @@ -170,7 +170,7 @@ private void RunOver(Vector2 targetPos) { var weapon = Master.WeaponPack.ActiveItem; - var distance = (int)(weapon == null ? 150 : (Utils.GetConfigRangeStart(weapon.Attribute.BulletDistanceRange) * 0.7f)); + var distance = (int)(weapon == null ? 150 : (Utils.GetConfigRangeStart(weapon.Attribute.Bullet.DistanceRange) * 0.7f)); _nextPosition = new Vector2( targetPos.X + Utils.Random.RandomRangeInt(-distance, distance), targetPos.Y + Utils.Random.RandomRangeInt(-distance, distance) diff --git a/DungeonShooting_Godot/src/game/activity/role/player/Player.cs b/DungeonShooting_Godot/src/game/activity/role/player/Player.cs index e067187..f543bf1 100644 --- a/DungeonShooting_Godot/src/game/activity/role/player/Player.cs +++ b/DungeonShooting_Godot/src/game/activity/role/player/Player.cs @@ -1,3 +1,4 @@ +using System; using Godot; @@ -16,11 +17,6 @@ /// 玩家身上的状态机控制器 ///
public StateController StateController { get; private set; } - - /// - /// 是否翻滚中 - /// - public bool IsRolling { get; private set; } /// /// 设置当前操作的玩家对象 @@ -39,7 +35,7 @@ IsAi = false; StateController = AddComponent>(); - AttackLayer = PhysicsLayer.Wall | PhysicsLayer.Prop | PhysicsLayer.Enemy; + AttackLayer = PhysicsLayer.Wall | PhysicsLayer.Enemy; EnemyLayer = EnemyLayer = PhysicsLayer.Enemy; Camp = CampEnum.Camp1; @@ -56,6 +52,11 @@ // CollisionMask = 0; //GameCamera.Main.Zoom = new Vector2(0.2f, 0.2f); //GameCamera.Main.Zoom = new Vector2(0.5f, 0.5f); + // this.CallDelay(0.5f, () => + // { + // var weapon = Create(Ids.Id_weapon0009); + // PickUpWeapon(weapon); + // }); //注册状态机 StateController.Register(new PlayerIdleState()); @@ -69,11 +70,11 @@ protected override void Process(float delta) { + base.Process(delta); if (IsDie) { return; } - base.Process(delta); //脸的朝向 if (LookTarget == null) { @@ -177,22 +178,21 @@ ((Enemy)enemy).Hurt(1000, 0); } } + // //测试用 + // if (InputManager.Roll) //鼠标处触发互动物体 + // { + // var now = DateTime.Now; + // var mousePosition = GetGlobalMousePosition(); + // var freezeSprites = AffiliationArea.RoomInfo.StaticSprite.CollisionCircle(mousePosition, 25, true); + // Debug.Log("检测数量: " + freezeSprites.Count + ", 用时: " + (DateTime.Now - now).TotalMilliseconds); + // foreach (var freezeSprite in freezeSprites) + // { + // var temp = freezeSprite.Position - mousePosition; + // freezeSprite.ActivityObject.MoveController.AddForce(temp.Normalized() * 300 * (25f - temp.Length()) / 25f); + // } + // } } - // protected override void PhysicsProcess(float delta) - // { - // if (IsDie) - // { - // return; - // } - // - // base.PhysicsProcess(delta); - // //处理移动 - // HandleMoveInput(delta); - // //播放动画 - // PlayAnim(); - // } - protected override void OnPickUpWeapon(Weapon weapon) { EventManager.EmitEvent(EventEnum.OnPlayerPickUpWeapon, weapon); @@ -321,9 +321,9 @@ } } - protected override void DebugDraw() - { - base.DebugDraw(); - DrawArc(new Vector2(0, -8), 50, 0, Mathf.Pi * 2f, 20, Colors.Red, 1); - } + // protected override void DebugDraw() + // { + // base.DebugDraw(); + // DrawArc(GetLocalMousePosition(), 25, 0, Mathf.Pi * 2f, 20, Colors.Red, 1); + // } } \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/activity/shell/Shell.cs b/DungeonShooting_Godot/src/game/activity/shell/Shell.cs index 5b58591..379448d 100644 --- a/DungeonShooting_Godot/src/game/activity/shell/Shell.cs +++ b/DungeonShooting_Godot/src/game/activity/shell/Shell.cs @@ -15,12 +15,12 @@ protected override void Process(float delta) { - //落地后将弹壳变为静态贴图 - if (!IsThrowing) + //落地静止后将弹壳变为静态贴图 + if (!IsThrowing && Altitude <= 0 && MoveController.IsMotionless()) { if (AffiliationArea != null) { - BecomesStaticImage(); + Freeze(); } else { diff --git a/DungeonShooting_Godot/src/game/activity/weapon/Weapon.cs b/DungeonShooting_Godot/src/game/activity/weapon/Weapon.cs index 3bead8a..b59ba0e 100644 --- a/DungeonShooting_Godot/src/game/activity/weapon/Weapon.cs +++ b/DungeonShooting_Godot/src/game/activity/weapon/Weapon.cs @@ -11,21 +11,21 @@ /// /// 武器使用的属性数据, 该属性会根据是否是玩家使用武器, 如果是Ai使用武器, 则会返回 AiUseAttribute 的属性对象 /// - public ExcelConfig.Weapon Attribute => _weaponAttribute; + public ExcelConfig.WeaponBase Attribute => _weaponAttribute; /// /// Ai使用该武器的属性 /// - public ExcelConfig.Weapon AiUseAttribute => _aiWeaponAttribute; + public ExcelConfig.WeaponBase AiUseAttribute => _aiWeaponAttribute; /// /// 玩家使用该武器的属性 /// - public ExcelConfig.Weapon PlayerUseAttribute => _playerWeaponAttribute; + public ExcelConfig.WeaponBase PlayerUseAttribute => _playerWeaponAttribute; - private ExcelConfig.Weapon _weaponAttribute; - private ExcelConfig.Weapon _playerWeaponAttribute; - private ExcelConfig.Weapon _aiWeaponAttribute; + private ExcelConfig.WeaponBase _weaponAttribute; + private ExcelConfig.WeaponBase _playerWeaponAttribute; + private ExcelConfig.WeaponBase _aiWeaponAttribute; /// /// 武器攻击的目标阵营 @@ -146,9 +146,9 @@ public bool NoMasterCanTrigger { get; set; } = true; /// - /// 上一次触发改武器开火的角色是否是Ai + /// 上一次触发改武器开火的角色 /// - public bool TriggerRoleIsAi { get; private set; } + public Role TriggerRole { get; private set; } /// /// 上一次触发改武器开火的触发开火攻击的层级, 数据源自于: @@ -232,12 +232,15 @@ //上膛计时器 private float _beLoadedStateTimer = -1; + //换弹投抛弹壳记录 + private bool _reloadShellFlag = false; + // ---------------------------------------------- private uint _tempLayer; private static bool _init = false; - private static Dictionary _weaponAttributeMap = - new Dictionary(); + private static Dictionary _weaponAttributeMap = + new Dictionary(); /// /// 初始化武器属性数据 @@ -250,11 +253,11 @@ } _init = true; - foreach (var weaponAttr in ExcelConfig.Weapon_List) + foreach (var weaponAttr in ExcelConfig.WeaponBase_List) { - if (!string.IsNullOrEmpty(weaponAttr.WeaponId)) + if (weaponAttr.Activity != null) { - if (!_weaponAttributeMap.TryAdd(weaponAttr.WeaponId, weaponAttr)) + if (!_weaponAttributeMap.TryAdd(weaponAttr.Activity.Id, weaponAttr)) { Debug.LogError("发现重复注册的武器属性: " + weaponAttr.Id); } @@ -262,11 +265,18 @@ } } - private static ExcelConfig.Weapon _GetWeaponAttribute(string itemId) + /// + /// 根据 ActivityBase.Id 获取对应武器的属性数据 + /// + public static ExcelConfig.WeaponBase GetWeaponAttribute(string itemId) { + if (itemId == null) + { + return null; + } if (_weaponAttributeMap.TryGetValue(itemId, out var attr)) { - return attr.Clone(); + return attr; } throw new Exception($"武器'{itemId}'没有在 Weapon 表中配置属性数据!"); @@ -274,14 +284,14 @@ public override void OnInit() { - InitWeapon(_GetWeaponAttribute(ItemConfig.Id)); + InitWeapon(GetWeaponAttribute(ItemConfig.Id).Clone()); AnimatedSprite.AnimationFinished += OnAnimationFinished; } /// /// 初始化武器属性 /// - public void InitWeapon(ExcelConfig.Weapon attribute) + public void InitWeapon(ExcelConfig.WeaponBase attribute) { _playerWeaponAttribute = attribute; _weaponAttribute = attribute; @@ -682,7 +692,7 @@ { return Master == null && GetParent() == GameApplication.Instance.World.NormalLayer; } - + /// /// 扳机函数, 调用即视为按下扳机 /// @@ -700,20 +710,20 @@ _triggerRoleFlag = true; if (triggerRole != null) { - TriggerRoleIsAi = triggerRole.IsAi; + TriggerRole = triggerRole; TriggerRoleAttackLayer = triggerRole.AttackLayer; - _weaponAttribute = TriggerRoleIsAi ? _aiWeaponAttribute : _playerWeaponAttribute; + _weaponAttribute = triggerRole.IsAi ? _aiWeaponAttribute : _playerWeaponAttribute; } else if (Master != null) { - TriggerRoleIsAi = Master.IsAi; + TriggerRole = Master; TriggerRoleAttackLayer = Master.AttackLayer; - _weaponAttribute = TriggerRoleIsAi ? _aiWeaponAttribute : _playerWeaponAttribute; + _weaponAttribute = Master.IsAi ? _aiWeaponAttribute : _playerWeaponAttribute; } - + //是否第一帧按下 var justDown = _downTimer == 0; - if (_beLoadedState == 0 || _beLoadedState == -1) //需要执行上膛操作 + if (_beLoadedState == 0 || _beLoadedState == -1) //需要执行上膛操作 { if (justDown && !Reloading && triggerRole != null) { @@ -729,9 +739,9 @@ } } } - else if (_beLoadedState == 1) //上膛中 + else if (_beLoadedState == 1) //上膛中 { - + } else //上膛完成 { @@ -801,6 +811,7 @@ { _delayedTime = Attribute.DelayedTime; } + //扳机按下间隔 _triggerTimer = Attribute.TriggerInterval; //连发数量 @@ -832,6 +843,14 @@ } } } + else //不能开火 + { + if (CurrAmmo <= 0 && justDown && triggerRole != null) //子弹不够 + { + //第一帧按下, 触发换弹 + Reload(); + } + } } } @@ -950,13 +969,16 @@ { _attackFlag = true; _noAttackTime = 0; + _reloadShellFlag = false; //减子弹数量 if (_playerWeaponAttribute != _weaponAttribute) //Ai使用该武器, 有一定概率不消耗弹药 { - if (Utils.Random.RandomRangeFloat(0, 1) < _weaponAttribute.AiAttackAttr.AmmoConsumptionProbability) //触发消耗弹药 + var count = UseAmmoCount(); + CurrAmmo -= count; + if (Utils.Random.RandomRangeFloat(0, 1) >= _weaponAttribute.AiAttackAttr.AmmoConsumptionProbability) //不消耗弹药 { - CurrAmmo -= UseAmmoCount(); + ResidueAmmo += count; } } else @@ -973,7 +995,7 @@ _continuousCount = _continuousCount > 0 ? _continuousCount - 1 : 0; } - //开火间隙 + //开火间隙, 这里的60指的是60秒 _fireInterval = 60 / Attribute.StartFiringSpeed; //攻击冷却 _attackTimer += _fireInterval; @@ -982,13 +1004,14 @@ if (IsAutoPlaySpriteFrames) { PlaySpriteAnimation(AnimatorNames.Fire); + PlayAnimationPlayer(AnimatorNames.Fire); } //播放射击音效 PlayShootSound(); //抛弹 - if ((Attribute.ContinuousShoot || !Attribute.ManualBeLoaded)) + if (!Attribute.ReloadThrowShell && (Attribute.ContinuousShoot || !Attribute.ManualBeLoaded)) { ThrowShellHandler(1f); } @@ -1047,7 +1070,7 @@ else //在地上 { var v = Utils.Random.RandomConfigRange(Attribute.BacklashRange) * 5; - var externalForce = MoveController.AddForce(new Vector2(-v, 0).Rotated(Rotation), v * 2); + var externalForce = MoveController.AddForce(new Vector2(-v, 0).Rotated(Rotation)); externalForce.RotationSpeed = -Mathf.DegToRad(40); externalForce.RotationResistance = Mathf.DegToRad(80); } @@ -1072,6 +1095,19 @@ // { // // } + + /// + /// 根据触扳机的角色对象判断该角色使用的武器数据 + /// + public ExcelConfig.WeaponBase GetUseAttribute(Role triggerRole) + { + if (triggerRole == null || !triggerRole.IsAi) + { + return PlayerUseAttribute; + } + + return AiUseAttribute; + } /// /// 获取武器攻击的目标层级 @@ -1185,7 +1221,8 @@ // Debug.Log("开始换弹."); //抛弹 - if (!Attribute.ContinuousShoot && (_beLoadedState == 0 || _beLoadedState == -1) && Attribute.BeLoadedTime > 0) + if (!Attribute.ReloadThrowShell && !Attribute.ContinuousShoot && + (_beLoadedState == 0 || _beLoadedState == -1) && Attribute.BeLoadedTime > 0) { ThrowShellHandler(0.6f); } @@ -1234,15 +1271,13 @@ { if (Attribute.BeginReloadSound != null) { - var position = GameApplication.Instance.ViewToGlobalPosition(GlobalPosition); - var volume = SoundManager.CalcRoleVolume(Attribute.BeginReloadSound.Volume, Master); if (Attribute.BeginReloadSoundDelayTime <= 0) { - SoundManager.PlaySoundEffectPosition(Attribute.BeginReloadSound.Path, position, volume); + SoundManager.PlaySoundByConfig(Attribute.BeginReloadSound, GlobalPosition, TriggerRole); } else { - SoundManager.PlaySoundEffectPositionDelay(Attribute.BeginReloadSound.Path, position, Attribute.BeginReloadSoundDelayTime, volume); + SoundManager.PlaySoundByConfigDelay(Attribute.BeginReloadSound, GlobalPosition, Attribute.BeginReloadSoundDelayTime, TriggerRole); } } } @@ -1252,15 +1287,13 @@ { if (Attribute.ReloadSound != null) { - var position = GameApplication.Instance.ViewToGlobalPosition(GlobalPosition); - var volume = SoundManager.CalcRoleVolume(Attribute.ReloadSound.Volume, Master); if (Attribute.ReloadSoundDelayTime <= 0) { - SoundManager.PlaySoundEffectPosition(Attribute.ReloadSound.Path, position, volume); + SoundManager.PlaySoundByConfig(Attribute.ReloadSound, GlobalPosition, TriggerRole); } else { - SoundManager.PlaySoundEffectPositionDelay(Attribute.ReloadSound.Path, position, Attribute.ReloadSoundDelayTime, volume); + SoundManager.PlaySoundByConfigDelay(Attribute.ReloadSound, GlobalPosition, Attribute.ReloadSoundDelayTime, TriggerRole); } } } @@ -1270,9 +1303,7 @@ { if (Attribute.ReloadFinishSound != null) { - var volume = SoundManager.CalcRoleVolume(Attribute.ReloadFinishSound.Volume, Master); - var position = GameApplication.Instance.ViewToGlobalPosition(GlobalPosition); - SoundManager.PlaySoundEffectPosition(Attribute.ReloadFinishSound.Path, position, volume); + SoundManager.PlaySoundByConfig(Attribute.ReloadFinishSound, GlobalPosition, TriggerRole); } } @@ -1281,9 +1312,7 @@ { if (Attribute.ShootSound != null) { - var volume = SoundManager.CalcRoleVolume(Attribute.ShootSound.Volume, Master); - var position = GameApplication.Instance.ViewToGlobalPosition(GlobalPosition); - SoundManager.PlaySoundEffectPosition(Attribute.ShootSound.Path, position, volume); + SoundManager.PlaySoundByConfig(Attribute.ShootSound, GlobalPosition, TriggerRole); } } @@ -1292,15 +1321,13 @@ { if (Attribute.BeLoadedSound != null) { - var position = GameApplication.Instance.ViewToGlobalPosition(GlobalPosition); - var volume = SoundManager.CalcRoleVolume(Attribute.BeLoadedSound.Volume, Master); if (Attribute.BeLoadedSoundDelayTime <= 0) { - SoundManager.PlaySoundEffectPosition(Attribute.BeLoadedSound.Path, position, volume); + SoundManager.PlaySoundByConfig(Attribute.BeLoadedSound, GlobalPosition, TriggerRole); } else { - SoundManager.PlaySoundEffectPositionDelay(Attribute.BeLoadedSound.Path, position, Attribute.BeLoadedSoundDelayTime, volume); + SoundManager.PlaySoundByConfigDelay(Attribute.BeLoadedSound, GlobalPosition, Attribute.BeLoadedSoundDelayTime, TriggerRole); } } } @@ -1358,11 +1385,18 @@ if (IsAutoPlaySpriteFrames) { PlaySpriteAnimation(AnimatorNames.Reloading); + PlayAnimationPlayer(AnimatorNames.Reloading); } //播放换弹音效 PlayReloadSound(); - + + //抛出弹壳 + if (Attribute.ReloadThrowShell && !_reloadShellFlag) + { + ThrowShellHandler(0.6f); + } + OnReload(); // Debug.Log("装弹."); } @@ -1385,7 +1419,7 @@ private void BeLoadedHandler() { //上膛抛弹 - if (!Attribute.ContinuousShoot && Attribute.BeLoadedTime > 0) + if (!Attribute.ReloadThrowShell && !Attribute.ContinuousShoot && Attribute.BeLoadedTime > 0) { ThrowShellHandler(0.6f); } @@ -1412,10 +1446,15 @@ if (Attribute.BeLoadedSoundDelayTime <= 0) { PlaySpriteAnimation(AnimatorNames.BeLoaded); + PlayAnimationPlayer(AnimatorNames.BeLoaded); } else { - this.CallDelay(Attribute.BeLoadedSoundDelayTime, PlaySpriteAnimation, AnimatorNames.BeLoaded); + this.CallDelay(Attribute.BeLoadedSoundDelayTime, () => + { + PlaySpriteAnimation(AnimatorNames.BeLoaded); + PlayAnimationPlayer(AnimatorNames.BeLoaded); + }); } } @@ -1426,18 +1465,23 @@ //抛弹逻辑 private void ThrowShellHandler(float speedScale) { - if (string.IsNullOrEmpty(Attribute.ShellId)) + if (Attribute.Shell == null) { return; } //创建一个弹壳 if (Attribute.ThrowShellDelayTime > 0) { - this.CallDelay(Attribute.ThrowShellDelayTime, () => ThrowShell(Attribute.ShellId, speedScale)); + this.CallDelay(Attribute.ThrowShellDelayTime, () => + { + _reloadShellFlag = true; + ThrowShell(Attribute.Shell, speedScale); + }); } else if (Attribute.ThrowShellDelayTime == 0) { - ThrowShell(Attribute.ShellId, speedScale); + _reloadShellFlag = true; + ThrowShell(Attribute.Shell, speedScale); } } @@ -1543,14 +1587,13 @@ ReloadFinishHandler(); } } - + //播放动画 - private void PlaySpriteAnimation(string name) + private void PlayAnimationPlayer(string name) { - var spriteFrames = AnimatedSprite.SpriteFrames; - if (spriteFrames != null && spriteFrames.HasAnimation(name)) + if (AnimationPlayer != null && AnimationPlayer.HasAnimation(name)) { - AnimatedSprite.Play(name); + AnimationPlayer.Play(name); } } @@ -1865,7 +1908,7 @@ /// /// 投抛弹壳的默认实现方式, shellId为弹壳id /// - protected ActivityObject ThrowShell(string shellId, float speedScale = 1) + protected ActivityObject ThrowShell(ExcelConfig.ActivityBase shell, float speedScale = 1) { var startPos = ShellPoint.GlobalPosition; float startHeight; @@ -1884,55 +1927,110 @@ var verticalSpeed = Utils.Random.RandomRangeInt((int)(60 * speedScale), (int)(120 * speedScale)); var velocity = new Vector2(Utils.Random.RandomRangeInt((int)(20 * speedScale), (int)(60 * speedScale)), 0).Rotated(direction * Mathf.Pi / 180); var rotate = Utils.Random.RandomRangeInt((int)(-720 * speedScale), (int)(720 * speedScale)); - var shell = Create(shellId); - shell.Rotation = (Master != null ? Master.MountPoint.RealRotation : Rotation); - shell.Throw(startPos, startHeight, verticalSpeed, velocity, rotate); - shell.InheritVelocity(Master != null ? Master : this); + var shellInstance = Create(shell); + shellInstance.Rotation = (Master != null ? Master.MountPoint.RealRotation : Rotation); + shellInstance.Throw(startPos, startHeight, verticalSpeed, velocity, rotate); + shellInstance.InheritVelocity(Master != null ? Master : this); if (Master == null) { - AffiliationArea.InsertItem(shell); + AffiliationArea.InsertItem(shellInstance); } else { - Master.AffiliationArea.InsertItem(shell); + Master.AffiliationArea.InsertItem(shellInstance); } - return shell; + return shellInstance; } /// - /// 发射子弹的默认实现方式, bulletId为子弹id + /// 发射子弹 /// - protected Bullet ShootBullet(float fireRotation, string bulletId) + protected IBullet ShootBullet(float fireRotation, ExcelConfig.BulletBase bullet) { - var speed = Utils.Random.RandomConfigRange(Attribute.BulletSpeedRange); - var distance = Utils.Random.RandomConfigRange(Attribute.BulletDistanceRange); - var deviationAngle = Utils.Random.RandomConfigRange(Attribute.BulletDeviationAngleRange); - if (Master != null) + if (bullet.Type == 1) //实体子弹 { - speed = Master.RoleState.CallCalcBulletSpeedEvent(this, speed); - distance = Master.RoleState.CallCalcBulletDistanceEvent(this, distance); - deviationAngle = Master.RoleState.CallCalcBulletDeviationAngleEvent(this, deviationAngle); + return ShootSolidBullet(fireRotation, bullet); + } + else if (bullet.Type == 2) //激光子弹 + { + return ShootLaser(fireRotation, bullet); } - var attackLayer = GetAttackLayer(); - //创建子弹 - var bullet = Create(bulletId); - bullet.Init( - TriggerRoleIsAi, - this, - speed, - distance, - FirePoint.GlobalPosition, - fireRotation + Mathf.DegToRad(deviationAngle), - attackLayer - ); - bullet.MinHarm = Utils.GetConfigRangeStart(Attribute.HarmRange); - bullet.MaxHarm = Utils.GetConfigRangeEnd(Attribute.HarmRange); - bullet.PutDown(RoomLayerEnum.YSortLayer); - return bullet; + return null; } - + + /// + /// 发射子弹的默认实现方式 + /// + private Bullet ShootSolidBullet(float fireRotation, ExcelConfig.BulletBase bullet) + { + var data = new BulletData() + { + Weapon = this, + BulletBase = bullet, + TriggerRole = TriggerRole, + MinHarm = Utils.GetConfigRangeStart(bullet.HarmRange), + MaxHarm = Utils.GetConfigRangeEnd(bullet.HarmRange), + MaxDistance = Utils.Random.RandomConfigRange(bullet.DistanceRange), + FlySpeed = Utils.Random.RandomConfigRange(bullet.SpeedRange), + VerticalSpeed = Utils.Random.RandomConfigRange(bullet.VerticalSpeed), + BounceCount = Utils.Random.RandomConfigRange(bullet.BounceCount), + Position = FirePoint.GlobalPosition, + }; + + var deviationAngle = Utils.Random.RandomConfigRange(bullet.DeviationAngleRange); + if (TriggerRole != null) + { + data.FlySpeed = TriggerRole.RoleState.CallCalcBulletSpeedEvent(this, data.FlySpeed); + data.MaxDistance = TriggerRole.RoleState.CallCalcBulletDistanceEvent(this, data.MaxDistance); + deviationAngle = TriggerRole.RoleState.CallCalcBulletDeviationAngleEvent(this, deviationAngle); + } + + if (TriggerRole != null && TriggerRole.IsAi) //只有玩家使用该武器才能获得正常速度的子弹 + { + data.FlySpeed *= AiUseAttribute.AiAttackAttr.BulletSpeedScale; + } + + data.Rotation = fireRotation + Mathf.DegToRad(deviationAngle); + //创建子弹 + var bulletInstance = Create(bullet.Prefab); + bulletInstance.InitData(data, GetAttackLayer()); + return bulletInstance; + } + + /// + /// 发射射线的默认实现方式 + /// + private Laser ShootLaser(float fireRotation, ExcelConfig.BulletBase bullet) + { + var data = new BulletData() + { + Weapon = this, + BulletBase = bullet, + TriggerRole = TriggerRole, + MinHarm = Utils.GetConfigRangeStart(bullet.HarmRange), + MaxHarm = Utils.GetConfigRangeEnd(bullet.HarmRange), + MaxDistance = Utils.Random.RandomConfigRange(bullet.DistanceRange), + BounceCount = Utils.Random.RandomConfigRange(bullet.BounceCount), + LifeTime = Utils.Random.RandomConfigRange(bullet.LifeTimeRange), + Position = FirePoint.GlobalPosition, + }; + + var deviationAngle = Utils.Random.RandomConfigRange(bullet.DeviationAngleRange); + if (TriggerRole != null) + { + deviationAngle = TriggerRole.RoleState.CallCalcBulletDeviationAngleEvent(this, deviationAngle); + } + + data.Rotation = fireRotation + Mathf.DegToRad(deviationAngle); + //创建激光 + var laser = ResourceManager.LoadAndInstantiate(bullet.Prefab); + laser.AddToActivityRoot(RoomLayerEnum.YSortLayer); + laser.InitData(data, GetAttackLayer(), 3); + return laser; + } + //-------------------------------- Ai相关 ----------------------------- /// diff --git a/DungeonShooting_Godot/src/game/activity/weapon/gun/Gun.cs b/DungeonShooting_Godot/src/game/activity/weapon/gun/Gun.cs index f74575e..92a4cfe 100644 --- a/DungeonShooting_Godot/src/game/activity/weapon/gun/Gun.cs +++ b/DungeonShooting_Godot/src/game/activity/weapon/gun/Gun.cs @@ -15,18 +15,21 @@ } //创建开火特效 - var packedScene = ResourceManager.Load(ResourcePath.prefab_effect_weapon_ShotFire_tscn); - var sprite = packedScene.Instantiate(); - // sprite.GlobalPosition = FirePoint.GlobalPosition; - // sprite.GlobalRotation = FirePoint.GlobalRotation; - // sprite.AddToActivityRoot(RoomLayerEnum.YSortLayer); - sprite.Position = GetLocalFirePosition(); - AddChild(sprite); + if (!string.IsNullOrEmpty(Attribute.FireEffect)) + { + var packedScene = ResourceManager.Load(Attribute.FireEffect); + var sprite = packedScene.Instantiate(); + // sprite.GlobalPosition = FirePoint.GlobalPosition; + // sprite.GlobalRotation = FirePoint.GlobalRotation; + // sprite.AddToActivityRoot(RoomLayerEnum.YSortLayer); + sprite.Position = GetLocalFirePosition(); + AddChild(sprite); + } } protected override void OnShoot(float fireRotation) { - ShootBullet(fireRotation, Attribute.BulletId); + ShootBullet(fireRotation, Attribute.Bullet); } // //测试用, 敌人被消灭时触发手上武器开火 diff --git a/DungeonShooting_Godot/src/game/activity/weapon/knife/Knife.cs b/DungeonShooting_Godot/src/game/activity/weapon/knife/Knife.cs index 462ebed..a8c3dff 100644 --- a/DungeonShooting_Godot/src/game/activity/weapon/knife/Knife.cs +++ b/DungeonShooting_Godot/src/game/activity/weapon/knife/Knife.cs @@ -129,16 +129,19 @@ { if (activityObject is Role role) //碰到角色 { - var damage = Utils.Random.RandomConfigRange(Attribute.HarmRange); + var damage = Utils.Random.RandomConfigRange(Attribute.Bullet.HarmRange); damage = Master.RoleState.CallCalcDamageEvent(damage); //击退 if (role is not Player) //目标不是玩家才会触发击退 { var attr = Master.IsAi ? AiUseAttribute : PlayerUseAttribute; - var repel = Utils.Random.RandomConfigRange(attr.RepelRnage); - var position = role.GlobalPosition - Master.MountPoint.GlobalPosition; - var v2 = position.Normalized() * repel; - role.MoveController.AddForce(v2, repel * 2); + var repel = Utils.Random.RandomConfigRange(attr.Bullet.RepelRnage); + if (repel != 0) + { + var position = role.GlobalPosition - Master.MountPoint.GlobalPosition; + var v2 = position.Normalized() * repel; + role.MoveController.AddForce(v2); + } } //造成伤害 diff --git a/DungeonShooting_Godot/src/game/camera/GameCamera.cs b/DungeonShooting_Godot/src/game/camera/GameCamera.cs index 4d7918d..27827a8 100644 --- a/DungeonShooting_Godot/src/game/camera/GameCamera.cs +++ b/DungeonShooting_Godot/src/game/camera/GameCamera.cs @@ -7,6 +7,20 @@ /// public partial class GameCamera : Camera2D { + private class ShakeData + { + public Vector2 Value; + public bool Decline; + public float DataDelta; + + public ShakeData(Vector2 value, bool decline, float dataDelta) + { + Value = value; + Decline = decline; + DataDelta = dataDelta; + } + } + /// /// 当前场景的相机对象 /// @@ -46,7 +60,7 @@ private Vector2 _processDistanceSquared = Vector2.Zero; private Vector2 _processDirection = Vector2.Zero; //抖动数据 - private readonly Dictionary _shakeMap = new Dictionary(); + private readonly Dictionary _shakeMap = new Dictionary(); private Vector2 _camPos; private Vector2 _shakeOffset = Vector2.Zero; @@ -60,8 +74,9 @@ { _camPos = GlobalPosition; } - - public override void _Process(double delta) + + //_PhysicsProcess + public override void _PhysicsProcess(double delta) { var newDelta = (float)delta; _Shake(newDelta); @@ -81,23 +96,20 @@ { var mousePosition = InputManager.CursorPosition; var targetPosition = _followTarget.GlobalPosition; - Vector2 targetPos; //if (targetPosition.DistanceSquaredTo(mousePosition) >= 39999.992F) // >= (60 / 0.3f) * (60 / 0.3f) if (targetPosition.DistanceSquaredTo(mousePosition) >= (60 / FollowsMouseAmount) * (60 / FollowsMouseAmount)) { - targetPos = targetPosition.MoveToward(mousePosition, 60); + _camPos = targetPosition.MoveToward(mousePosition, 60); } else { //targetPos = targetPosition.Lerp(mousePosition, 0.3f); //这里的0.3就是上面的 (60 / 0.3f) * (60 / 0.3f) 中的 0.3 - targetPos = targetPosition.Lerp(mousePosition, FollowsMouseAmount); + _camPos = targetPosition.Lerp(mousePosition, FollowsMouseAmount); } - _camPos = _camPos.Lerp(targetPos, 20 * newDelta); + //_camPos = _camPos.Lerp(targetPos, 20 * newDelta); GlobalPosition = _camPos.Round(); Offset = _shakeOffset.Round(); - - //_temp = _camPos - targetPosition; //调用相机更新事件 if (OnPositionUpdateEvent != null) @@ -151,7 +163,7 @@ /// /// 创建一个抖动, 并设置抖动时间 /// - public async void CreateShake(Vector2 value, float time) + public async void CreateShake(Vector2 value, float time, bool decline = false) { if (time > 0) { @@ -159,7 +171,15 @@ value.Y = Mathf.Abs(value.Y); var tempIndex = _index++; var sceneTreeTimer = GetTree().CreateTimer(time); - _shakeMap[tempIndex] = value; + if (decline) + { + _shakeMap[tempIndex] = new ShakeData(value, true, value.Length() / time); + } + else + { + _shakeMap[tempIndex] = new ShakeData(value, false, 0); + } + await ToSignal(sceneTreeTimer, Timer.SignalName.Timeout); _shakeMap.Remove(tempIndex); } @@ -178,7 +198,7 @@ { if (EnableShake) { - var distance = _CalculateDistanceSquared(); + var distance = _CalculateDistanceSquared(delta); distance = new Vector2(Mathf.Sqrt(distance.X), Mathf.Sqrt(distance.Y)); _shakeOffset += _processDirection + new Vector2( (float)GD.RandRange(-distance.X, distance.X) - Offset.X, @@ -194,21 +214,28 @@ } //计算相机需要抖动的值 - private Vector2 _CalculateDistanceSquared() + private Vector2 _CalculateDistanceSquared(float delta) { var temp = Vector2.Zero; float length = 0; - + foreach (var keyValuePair in _shakeMap) { - var tempLenght = keyValuePair.Value.LengthSquared(); + var shakeData = keyValuePair.Value; + var tempLenght = shakeData.Value.LengthSquared(); if (tempLenght > length) { length = tempLenght; - temp = keyValuePair.Value; + temp = shakeData.Value; + if (shakeData.Decline) + { + shakeData.Value = shakeData.Value.MoveToward(Vector2.Zero, shakeData.DataDelta * delta); + //Debug.Log("shakeData.Value: " + shakeData.Value + ", _processDistanceSquared: " + _processDistanceSquared); + } } } - + + //return temp; return _processDistanceSquared.LengthSquared() > length ? _processDistanceSquared : temp; } } diff --git a/DungeonShooting_Godot/src/game/data/BulletData.cs b/DungeonShooting_Godot/src/game/data/BulletData.cs new file mode 100644 index 0000000..e15913f --- /dev/null +++ b/DungeonShooting_Godot/src/game/data/BulletData.cs @@ -0,0 +1,69 @@ + +using Config; +using Godot; + +/// +/// 子弹数据 +/// +public class BulletData +{ + /// + /// 发射该子弹的武器 + /// + public Weapon Weapon; + + /// + /// 使用的配置数据 + /// + public ExcelConfig.BulletBase BulletBase; + + /// + /// 发射该子弹的角色 + /// + public Role TriggerRole; + + /// + /// 最小伤害 + /// + public int MinHarm; + + /// + /// 最大伤害 + /// + public int MaxHarm; + + /// + /// 最大飞行距离 + /// + public float MaxDistance; + + /// + /// 子弹飞行速度 + /// + public float FlySpeed; + + /// + /// 纵轴速度 + /// + public float VerticalSpeed; + + /// + /// 反弹次数 + /// + public int BounceCount; + + /// + /// 子弹最大存在时间 + /// + public float LifeTime; + + /// + /// 坐标 + /// + public Vector2 Position; + + /// + /// 旋转角度 + /// + public float Rotation; +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/effects/EnemyDebris.cs b/DungeonShooting_Godot/src/game/effects/EnemyDebris.cs index 4e975ee..d96d1c2 100644 --- a/DungeonShooting_Godot/src/game/effects/EnemyDebris.cs +++ b/DungeonShooting_Godot/src/game/effects/EnemyDebris.cs @@ -2,11 +2,15 @@ using System.Collections; using Godot; +/// +/// 敌人死亡碎片 +/// [Tool] public partial class EnemyDebris : ActivityObject { private GpuParticles2D _gpuParticles2D; + private bool _playOver = false; public override void OnInit() { @@ -23,6 +27,15 @@ StartCoroutine(EmitParticles()); } + protected override void Process(float delta) + { + if (_playOver && !IsThrowing && Altitude <= 0 && MoveController.IsMotionless()) + { + MoveController.SetAllVelocity(Vector2.Zero); + Freeze(); + } + } + public IEnumerator EmitParticles() { var gpuParticles2D = GetNode("GPUParticles2D"); @@ -30,6 +43,6 @@ yield return new WaitForSeconds(Utils.Random.RandomRangeFloat(1f, 2.5f)); gpuParticles2D.Emitting = false; yield return new WaitForSeconds(1); - BecomesStaticImage(); + _playOver = true; } } \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/manager/EditorWindowManager.cs b/DungeonShooting_Godot/src/game/manager/EditorWindowManager.cs index 878db9c..35f7451 100644 --- a/DungeonShooting_Godot/src/game/manager/EditorWindowManager.cs +++ b/DungeonShooting_Godot/src/game/manager/EditorWindowManager.cs @@ -332,7 +332,7 @@ /// 查找的类型, 如果为 none, 则查找所有类型数据 /// 选中物体时回调 /// 所属父级Ui - public static void ShowSelectObject(ActivityType findType, Action onSelectObject, UiBase parentUi = null) + public static void ShowSelectObject(ActivityType findType, Action onSelectObject, UiBase parentUi = null) { var window = CreateWindowInstance(parentUi); window.S_Window.Instance.Size = new Vector2I(1000, 700); diff --git a/DungeonShooting_Godot/src/game/manager/ObjectManager.cs b/DungeonShooting_Godot/src/game/manager/ObjectManager.cs new file mode 100644 index 0000000..5338453 --- /dev/null +++ b/DungeonShooting_Godot/src/game/manager/ObjectManager.cs @@ -0,0 +1,15 @@ + +public static class ObjectManager +{ + public static Explode GetExplode(string resPath) + { + var explode = ObjectPool.GetItem(resPath); + if (explode == null) + { + explode = ResourceManager.LoadAndInstantiate(resPath); + explode.Logotype = resPath; + } + + return explode; + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/manager/ResourceManager.cs b/DungeonShooting_Godot/src/game/manager/ResourceManager.cs index 008031b..6119cda 100644 --- a/DungeonShooting_Godot/src/game/manager/ResourceManager.cs +++ b/DungeonShooting_Godot/src/game/manager/ResourceManager.cs @@ -29,6 +29,8 @@ } private static ShaderMaterial _shadowMaterial; + + public static ShaderMaterial NewBlendMaterial => Load(ResourcePath.resource_material_Blend_tres, false); /// /// 颜色混合Shader diff --git a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs index 40f2ec7..03b63e2 100644 --- a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs +++ b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs @@ -9,9 +9,12 @@ public const string excel_DungeonShooting_ExcelTool_deps_json = "res://excel/DungeonShooting_ExcelTool.deps.json"; public const string excel_DungeonShooting_ExcelTool_runtimeconfig_json = "res://excel/DungeonShooting_ExcelTool.runtimeconfig.json"; public const string prefab_Cursor_tscn = "res://prefab/Cursor.tscn"; - public const string prefab_bullet_Bullet0001_tscn = "res://prefab/bullet/Bullet0001.tscn"; - public const string prefab_bullet_Bullet0002_tscn = "res://prefab/bullet/Bullet0002.tscn"; - public const string prefab_bullet_Bullet0003_tscn = "res://prefab/bullet/Bullet0003.tscn"; + public const string prefab_bullet_explode_Explode0001_tscn = "res://prefab/bullet/explode/Explode0001.tscn"; + public const string prefab_bullet_laser_Laser0001_tscn = "res://prefab/bullet/laser/Laser0001.tscn"; + public const string prefab_bullet_normal_Bullet0001_tscn = "res://prefab/bullet/normal/Bullet0001.tscn"; + public const string prefab_bullet_normal_Bullet0002_tscn = "res://prefab/bullet/normal/Bullet0002.tscn"; + public const string prefab_bullet_normal_Bullet0003_tscn = "res://prefab/bullet/normal/Bullet0003.tscn"; + public const string prefab_bullet_normal_Bullet0004_tscn = "res://prefab/bullet/normal/Bullet0004.tscn"; public const string prefab_effect_Blood_tscn = "res://prefab/effect/Blood.tscn"; public const string prefab_effect_common_Effect1_tscn = "res://prefab/effect/common/Effect1.tscn"; public const string prefab_effect_enemy_Effect0001_tscn = "res://prefab/effect/enemy/Effect0001.tscn"; @@ -22,6 +25,7 @@ public const string prefab_effect_weapon_MeleeAttack1_tscn = "res://prefab/effect/weapon/MeleeAttack1.tscn"; public const string prefab_effect_weapon_MeleeAttack2_tscn = "res://prefab/effect/weapon/MeleeAttack2.tscn"; public const string prefab_effect_weapon_ShotFire_tscn = "res://prefab/effect/weapon/ShotFire.tscn"; + public const string prefab_effect_weapon_ShotFire2_tscn = "res://prefab/effect/weapon/ShotFire2.tscn"; public const string prefab_map_RoomDoor_E_tscn = "res://prefab/map/RoomDoor_E.tscn"; public const string prefab_map_RoomDoor_N_tscn = "res://prefab/map/RoomDoor_N.tscn"; public const string prefab_map_RoomDoor_S_tscn = "res://prefab/map/RoomDoor_S.tscn"; @@ -75,10 +79,15 @@ public const string prefab_weapon_Weapon0005_tscn = "res://prefab/weapon/Weapon0005.tscn"; public const string prefab_weapon_Weapon0006_tscn = "res://prefab/weapon/Weapon0006.tscn"; public const string prefab_weapon_Weapon0007_tscn = "res://prefab/weapon/Weapon0007.tscn"; + public const string prefab_weapon_Weapon0008_tscn = "res://prefab/weapon/Weapon0008.tscn"; + public const string prefab_weapon_Weapon0009_tscn = "res://prefab/weapon/Weapon0009.tscn"; public const string prefab_weapon_WeaponTemplate_tscn = "res://prefab/weapon/WeaponTemplate.tscn"; - public const string resource_config_ActivityObject_json = "res://resource/config/ActivityObject.json"; + public const string resource_config_ActivityBase_json = "res://resource/config/ActivityBase.json"; + public const string resource_config_ActivityMaterial_json = "res://resource/config/ActivityMaterial.json"; + public const string resource_config_AiAttackAttr_json = "res://resource/config/AiAttackAttr.json"; + public const string resource_config_BulletBase_json = "res://resource/config/BulletBase.json"; public const string resource_config_Sound_json = "res://resource/config/Sound.json"; - public const string resource_config_Weapon_json = "res://resource/config/Weapon.json"; + public const string resource_config_WeaponBase_json = "res://resource/config/WeaponBase.json"; public const string resource_curve_Curve1_tres = "res://resource/curve/Curve1.tres"; public const string resource_font_DinkieBitmap7pxDemo_ttf = "res://resource/font/DinkieBitmap-7pxDemo.ttf"; public const string resource_font_DinkieBitmap9pxDemo_ttf = "res://resource/font/DinkieBitmap-9pxDemo.ttf"; @@ -125,8 +134,10 @@ public const string resource_sound_sfx_reloading_Reloading_begin0008_ogg = "res://resource/sound/sfx/reloading/Reloading_begin0008.ogg"; public const string resource_sound_sfx_reloading_Reloading_begin0009_ogg = "res://resource/sound/sfx/reloading/Reloading_begin0009.ogg"; public const string resource_sound_sfx_reloading_Reloading_begin0010_ogg = "res://resource/sound/sfx/reloading/Reloading_begin0010.ogg"; + public const string resource_sound_sfx_reloading_Reloading_begin0011_ogg = "res://resource/sound/sfx/reloading/Reloading_begin0011.ogg"; public const string resource_sound_sfx_reloading_Reloading_finish0001_ogg = "res://resource/sound/sfx/reloading/Reloading_finish0001.ogg"; public const string resource_sound_sfx_reloading_Reloading_finish0002_ogg = "res://resource/sound/sfx/reloading/Reloading_finish0002.ogg"; + public const string resource_sound_sfx_reloading_Reloading_finish0003_ogg = "res://resource/sound/sfx/reloading/Reloading_finish0003.ogg"; public const string resource_sound_sfx_shooting_Shooting0001_ogg = "res://resource/sound/sfx/shooting/Shooting0001.ogg"; public const string resource_sound_sfx_shooting_Shooting0002_ogg = "res://resource/sound/sfx/shooting/Shooting0002.ogg"; public const string resource_sound_sfx_shooting_Shooting0003_ogg = "res://resource/sound/sfx/shooting/Shooting0003.ogg"; @@ -135,20 +146,30 @@ public const string resource_sound_sfx_shooting_Shooting0006_ogg = "res://resource/sound/sfx/shooting/Shooting0006.ogg"; public const string resource_sound_sfx_shooting_Shooting0007_ogg = "res://resource/sound/sfx/shooting/Shooting0007.ogg"; public const string resource_sound_sfx_shooting_Shooting0008_ogg = "res://resource/sound/sfx/shooting/Shooting0008.ogg"; - public const string resource_sprite_bullet_arrow_png = "res://resource/sprite/bullet/arrow.png"; - public const string resource_sprite_bullet_bullet0001_png = "res://resource/sprite/bullet/bullet0001.png"; - public const string resource_sprite_bullet_bullet0002_png = "res://resource/sprite/bullet/bullet0002.png"; - public const string resource_sprite_bullet_bullet0003_png = "res://resource/sprite/bullet/bullet0003.png"; - public const string resource_sprite_bullet_bullet2_png = "res://resource/sprite/bullet/bullet2.png"; + public const string resource_sound_sfx_shooting_Shooting0009_ogg = "res://resource/sound/sfx/shooting/Shooting0009.ogg"; + public const string resource_sound_sfx_shooting_Shooting0010_ogg = "res://resource/sound/sfx/shooting/Shooting0010.ogg"; + public const string resource_sprite_bullet_laser_Laser0001_png = "res://resource/sprite/bullet/laser/Laser0001.png"; + public const string resource_sprite_bullet_normal_arrow_png = "res://resource/sprite/bullet/normal/arrow.png"; + public const string resource_sprite_bullet_normal_bullet0001_png = "res://resource/sprite/bullet/normal/bullet0001.png"; + public const string resource_sprite_bullet_normal_bullet0002_png = "res://resource/sprite/bullet/normal/bullet0002.png"; + public const string resource_sprite_bullet_normal_bullet0003_png = "res://resource/sprite/bullet/normal/bullet0003.png"; + public const string resource_sprite_bullet_normal_bullet0004_png = "res://resource/sprite/bullet/normal/bullet0004.png"; + public const string resource_sprite_bullet_normal_bullet2_png = "res://resource/sprite/bullet/normal/bullet2.png"; public const string resource_sprite_effects_Circle_png = "res://resource/sprite/effects/Circle.png"; + public const string resource_sprite_effects_Circle2_png = "res://resource/sprite/effects/Circle2.png"; public const string resource_sprite_effects_debug_arrows_png = "res://resource/sprite/effects/debug_arrows.png"; public const string resource_sprite_effects_Explosion_png = "res://resource/sprite/effects/Explosion.png"; public const string resource_sprite_effects_common_Effect1_png = "res://resource/sprite/effects/common/Effect1.png"; public const string resource_sprite_effects_common_Smoke_png = "res://resource/sprite/effects/common/Smoke.png"; + public const string resource_sprite_effects_common_Smoke2_png = "res://resource/sprite/effects/common/Smoke2.png"; + public const string resource_sprite_effects_explode_Explode_circle0001_png = "res://resource/sprite/effects/explode/Explode_circle0001.png"; + public const string resource_sprite_effects_explode_Explode_line0001_png = "res://resource/sprite/effects/explode/Explode_line0001.png"; + public const string resource_sprite_effects_explode_Explode_pit0001_png = "res://resource/sprite/effects/explode/Explode_pit0001.png"; public const string resource_sprite_effects_weapon_Collision1_png = "res://resource/sprite/effects/weapon/Collision1.png"; public const string resource_sprite_effects_weapon_KnifeHit1_png = "res://resource/sprite/effects/weapon/KnifeHit1.png"; public const string resource_sprite_effects_weapon_MeleeAttack1_png = "res://resource/sprite/effects/weapon/MeleeAttack1.png"; public const string resource_sprite_effects_weapon_ShotFire_png = "res://resource/sprite/effects/weapon/ShotFire.png"; + public const string resource_sprite_effects_weapon_ShotFire2_png = "res://resource/sprite/effects/weapon/ShotFire2.png"; public const string resource_sprite_map_door_png = "res://resource/sprite/map/door.png"; public const string resource_sprite_map_door1_down_png = "res://resource/sprite/map/door1_down.png"; public const string resource_sprite_map_PreviewTransition_png = "res://resource/sprite/map/PreviewTransition.png"; @@ -276,9 +297,13 @@ public const string resource_sprite_weapon_weapon0005_Weapon0005_png = "res://resource/sprite/weapon/weapon0005/Weapon0005.png"; public const string resource_sprite_weapon_weapon0006_Weapon0006_png = "res://resource/sprite/weapon/weapon0006/Weapon0006.png"; public const string resource_sprite_weapon_weapon0007_Weapon0007_png = "res://resource/sprite/weapon/weapon0007/Weapon0007.png"; + public const string resource_sprite_weapon_weapon0008_Weapon0008_png = "res://resource/sprite/weapon/weapon0008/Weapon0008.png"; + public const string resource_sprite_weapon_weapon0008_Weapon0008_reloading_png = "res://resource/sprite/weapon/weapon0008/Weapon0008_reloading.png"; + public const string resource_sprite_weapon_weapon0009_weapon0009_png = "res://resource/sprite/weapon/weapon0009/weapon0009.png"; public const string resource_spriteFrames_bullet_Bullet0001_tres = "res://resource/spriteFrames/bullet/Bullet0001.tres"; public const string resource_spriteFrames_bullet_Bullet0002_tres = "res://resource/spriteFrames/bullet/Bullet0002.tres"; public const string resource_spriteFrames_bullet_Bullet0003_tres = "res://resource/spriteFrames/bullet/Bullet0003.tres"; + public const string resource_spriteFrames_bullet_Bullet0004_tres = "res://resource/spriteFrames/bullet/Bullet0004.tres"; public const string resource_spriteFrames_effect_KnifeHit1_tres = "res://resource/spriteFrames/effect/KnifeHit1.tres"; public const string resource_spriteFrames_other_RoomDoor_E_Down_tres = "res://resource/spriteFrames/other/RoomDoor_E_Down.tres"; public const string resource_spriteFrames_other_RoomDoor_E_Up_tres = "res://resource/spriteFrames/other/RoomDoor_E_Up.tres"; @@ -310,20 +335,20 @@ public const string resource_spriteFrames_weapon_Weapon0005_tres = "res://resource/spriteFrames/weapon/Weapon0005.tres"; public const string resource_spriteFrames_weapon_Weapon0006_tres = "res://resource/spriteFrames/weapon/Weapon0006.tres"; public const string resource_spriteFrames_weapon_Weapon0007_tres = "res://resource/spriteFrames/weapon/Weapon0007.tres"; + public const string resource_spriteFrames_weapon_Weapon0008_tres = "res://resource/spriteFrames/weapon/Weapon0008.tres"; + public const string resource_spriteFrames_weapon_Weapon0009_tres = "res://resource/spriteFrames/weapon/Weapon0009.tres"; public const string resource_theme_mainTheme_tres = "res://resource/theme/mainTheme.tres"; public const string resource_theme_theme1_tres = "res://resource/theme/theme1.tres"; public const string scene_Main_tscn = "res://scene/Main.tscn"; public const string scene_World_tscn = "res://scene/World.tscn"; - public const string scene_test_TestCommpont_tscn = "res://scene/test/TestCommpont.tscn"; public const string scene_test_TestCreateSector_tscn = "res://scene/test/TestCreateSector.tscn"; - public const string scene_test_TestExpression_tscn = "res://scene/test/TestExpression.tscn"; - public const string scene_test_TestGenerateDungeon_tscn = "res://scene/test/TestGenerateDungeon.tscn"; + public const string scene_test_TestDrawSprite_tscn = "res://scene/test/TestDrawSprite.tscn"; + public const string scene_test_TestGridData_tscn = "res://scene/test/TestGridData.tscn"; public const string scene_test_TestNavigation2_tscn = "res://scene/test/TestNavigation2.tscn"; public const string scene_test_TestNavigationPolygon_tscn = "res://scene/test/TestNavigationPolygon.tscn"; public const string scene_test_TestNewTileMap_tscn = "res://scene/test/TestNewTileMap.tscn"; public const string scene_test_TestOptimizeSprite_tscn = "res://scene/test/TestOptimizeSprite.tscn"; public const string scene_test_TestOutline_tscn = "res://scene/test/TestOutline.tscn"; - public const string scene_test_TestReadExcel_tscn = "res://scene/test/TestReadExcel.tscn"; public const string scene_test_TestRoomFog_tscn = "res://scene/test/TestRoomFog.tscn"; public const string scene_test_TestTileLayer_tscn = "res://scene/test/TestTileLayer.tscn"; } \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/manager/SoundManager.cs b/DungeonShooting_Godot/src/game/manager/SoundManager.cs index 679cb32..2195543 100644 --- a/DungeonShooting_Godot/src/game/manager/SoundManager.cs +++ b/DungeonShooting_Godot/src/game/manager/SoundManager.cs @@ -1,6 +1,7 @@ using System; using System.Collections; using System.Collections.Generic; +using Config; using Godot; /// @@ -190,6 +191,63 @@ soundNode.PlaySoundByResource(soundName, delayTime); return soundNode; } + + /// + /// 根据音效配置表Id播放音效 + /// + /// 音效Id + /// 播放音效的位置, 该位置为 SubViewport 下的坐标, 也就是 使用的坐标 + /// 触发播放音效的角色, 因为 Npc 产生的音效声音更小, 可以传 null + public static GameAudioPlayer2D PlaySoundByConfig(string id, Vector2 viewPosition, Role triggerRole = null) + { + var sound = ExcelConfig.Sound_Map[id]; + return PlaySoundByConfig(sound, viewPosition, triggerRole); + } + + /// + /// 根据音效配置播放音效 + /// + /// 音效数据 + /// 播放音效的位置, 该位置为 SubViewport 下的坐标, 也就是 使用的坐标 + /// 触发播放音效的角色, 因为 Npc 产生的音效声音更小, 可以传 null + public static GameAudioPlayer2D PlaySoundByConfig(ExcelConfig.Sound sound, Vector2 viewPosition, Role triggerRole = null) + { + return PlaySoundEffectPosition( + sound.Path, + GameApplication.Instance.ViewToGlobalPosition(viewPosition), + CalcRoleVolume(sound.Volume, triggerRole) + ); + } + + /// + /// 根据音效配置表Id延时播放音效 + /// + /// 音效Id + /// 播放音效的位置, 该位置为 SubViewport 下的坐标, 也就是 使用的坐标 + /// 延时时间 + /// 触发播放音效的角色, 因为 Npc 产生的音效声音更小, 可以传 null + public static GameAudioPlayer2D PlaySoundByConfigDelay(string id, Vector2 viewPosition, float delayTime, Role triggerRole = null) + { + var sound = ExcelConfig.Sound_Map[id]; + return PlaySoundByConfigDelay(sound, viewPosition, delayTime, triggerRole); + } + + /// + /// 根据音效配置延时播放音效 + /// + /// 音效数据 + /// 播放音效的位置, 该位置为 SubViewport 下的坐标, 也就是 使用的坐标 + /// 延时时间 + /// 触发播放音效的角色, 因为 Npc 产生的音效声音更小, 可以传 null + public static GameAudioPlayer2D PlaySoundByConfigDelay(ExcelConfig.Sound sound, Vector2 viewPosition, float delayTime, Role triggerRole = null) + { + return PlaySoundEffectPositionDelay( + sound.Path, + GameApplication.Instance.ViewToGlobalPosition(viewPosition), + delayTime, + CalcRoleVolume(sound.Volume, triggerRole) + ); + } /// /// 获取2D音频播放节点 diff --git a/DungeonShooting_Godot/src/game/room/DungeonManager.cs b/DungeonShooting_Godot/src/game/room/DungeonManager.cs index 822e63e..c83bbf3 100644 --- a/DungeonShooting_Godot/src/game/room/DungeonManager.cs +++ b/DungeonShooting_Godot/src/game/room/DungeonManager.cs @@ -185,7 +185,7 @@ //更新敌人视野 UpdateEnemiesView(); - if (GameApplication.Instance.Debug) + if (GameApplication.Instance.IsDebug) { QueueRedraw(); } @@ -325,6 +325,8 @@ CreateDoor(roomInfo); //创建房间归属区域 CreateRoomAffiliation(roomInfo); + //创建 RoomStaticSprite + CreateRoomStaticSprite(roomInfo); //创建静态精灵画布 CreateRoomStaticSpriteCanvas(roomInfo); //创建迷雾遮罩 @@ -411,24 +413,31 @@ World.AffiliationAreaRoot.AddChild(affiliation); } + //创建 RoomStaticSprite + private void CreateRoomStaticSprite(RoomInfo roomInfo) + { + var spriteRoot = new RoomStaticSprite(roomInfo); + spriteRoot.Name = "SpriteRoot"; + World.Current.StaticSpriteRoot.AddChild(spriteRoot); + roomInfo.StaticSprite = spriteRoot; + } + //创建静态精灵画布 private void CreateRoomStaticSpriteCanvas(RoomInfo roomInfo) { var worldPos = roomInfo.GetWorldPosition(); var rect = roomInfo.OuterRange; - int minX = rect.Position.X - GameConfig.TileCellSize; - int minY = rect.Position.Y - GameConfig.TileCellSize; - int maxX = rect.End.X + GameConfig.TileCellSize; - int maxY = rect.End.Y + GameConfig.TileCellSize; + var minX = rect.Position.X - GameConfig.TileCellSize; + var minY = rect.Position.Y - GameConfig.TileCellSize; + var maxX = rect.End.X + GameConfig.TileCellSize; + var maxY = rect.End.Y + GameConfig.TileCellSize; - var staticSpriteCanvas = new RoomStaticImageCanvas( - World.StaticSpriteRoot, - new Vector2I(minX, minY), - maxX - minX, maxY - minY - ); - staticSpriteCanvas.RoomOffset = new Vector2I(worldPos.X - minX, worldPos.Y - minY); - roomInfo.StaticImageCanvas = staticSpriteCanvas; + var canvasSprite = new ImageCanvas(maxX - minX, maxY - minY); + canvasSprite.Position = new Vector2I(minX, minY); + roomInfo.RoomOffset = new Vector2I(worldPos.X - minX, worldPos.Y - minY); + roomInfo.StaticImageCanvas = canvasSprite; + roomInfo.StaticSprite.AddChild(canvasSprite); } //创建迷雾遮罩 @@ -642,9 +651,9 @@ public override void _Draw() { - if (GameApplication.Instance.Debug) + if (GameApplication.Instance.IsDebug) { - if (_dungeonTileMap != null) + if (_dungeonTileMap != null && _roomStaticNavigationList != null) { //绘制ai寻路区域 Utils.DrawNavigationPolygon(this, _roomStaticNavigationList.ToArray()); diff --git a/DungeonShooting_Godot/src/game/room/World.cs b/DungeonShooting_Godot/src/game/room/World.cs index 00ca2eb..35af42b 100644 --- a/DungeonShooting_Godot/src/game/room/World.cs +++ b/DungeonShooting_Godot/src/game/room/World.cs @@ -84,6 +84,8 @@ public override void _Ready() { + Color = Colors.Black; + //临时处理, 加载TileSet var tileSet = ResourceManager.Load(ResourcePath.resource_map_tileSet_map1_TileSet1_tres); var tileSetAtlasSource = (TileSetAtlasSource)tileSet.GetSource(0); @@ -95,10 +97,7 @@ public override void _Process(double delta) { //协程更新 - if (_coroutineList != null) - { - ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, (float)delta); - } + ProxyCoroutineHandler.ProxyUpdateCoroutine(ref _coroutineList, (float)delta); } /// diff --git a/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTipsPanel.cs b/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTipsPanel.cs index ff23c3e..a7bba64 100644 --- a/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTipsPanel.cs +++ b/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTipsPanel.cs @@ -69,7 +69,7 @@ yield return 0; //向上移动 - var frame = 60 * _animationTime; + var frame = GameApplication.Instance.TargetFps * _animationTime; var stepPixel = _movePixel / frame; for (var i = 0; i < frame; i++) { diff --git a/DungeonShooting_Godot/src/game/ui/debugger/Debugger.cs b/DungeonShooting_Godot/src/game/ui/debugger/Debugger.cs index e63e0d4..f663a64 100644 --- a/DungeonShooting_Godot/src/game/ui/debugger/Debugger.cs +++ b/DungeonShooting_Godot/src/game/ui/debugger/Debugger.cs @@ -31,6 +31,19 @@ } private HoverButton _L_HoverButton; + /// + /// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: Debugger.Fps + /// + public Fps L_Fps + { + get + { + if (_L_Fps == null) _L_Fps = new Fps((DebuggerPanel)this, GetNode("Fps")); + return _L_Fps; + } + } + private Fps _L_Fps; + public Debugger() : base(nameof(Debugger)) { @@ -147,6 +160,15 @@ public override HoverButton Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate()); } + /// + /// 类型: , 路径: Debugger.Fps + /// + public class Fps : UiNode + { + public Fps(DebuggerPanel uiPanel, Godot.Label node) : base(uiPanel, node) { } + public override Fps Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate()); + } + /// /// 场景中唯一名称的节点, 节点类型: , 节点路径: Debugger.Bg.Clear @@ -178,4 +200,9 @@ /// public HoverButton S_HoverButton => L_HoverButton; + /// + /// 场景中唯一名称的节点, 节点类型: , 节点路径: Debugger.Fps + /// + public Fps S_Fps => L_Fps; + } diff --git a/DungeonShooting_Godot/src/game/ui/debugger/DebuggerPanel.cs b/DungeonShooting_Godot/src/game/ui/debugger/DebuggerPanel.cs index 68d13f4..62c13bb 100644 --- a/DungeonShooting_Godot/src/game/ui/debugger/DebuggerPanel.cs +++ b/DungeonShooting_Godot/src/game/ui/debugger/DebuggerPanel.cs @@ -51,6 +51,8 @@ } } } + + S_Fps.Instance.Text = "FPS:" + Engine.GetFramesPerSecond(); } private void OnMouseDown() diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MapEditorCreateMarkPanel.cs b/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MapEditorCreateMarkPanel.cs index ca97690..0dce3e9 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MapEditorCreateMarkPanel.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MapEditorCreateMarkPanel.cs @@ -201,7 +201,7 @@ } //选中物体回调, 创建标记数据 - private void OnSelectObject(ExcelConfig.ActivityObject activityObject) + private void OnSelectObject(ExcelConfig.ActivityBase activityObject) { _grid.Add(new MarkInfoItem() { diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MarkObjectCell.cs b/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MarkObjectCell.cs index aefa59c..b42ac54 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MarkObjectCell.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/MarkObjectCell.cs @@ -11,7 +11,7 @@ private MapEditorCreateMark.ExpandPanel _expandPanel; //自定义额外属性 private List _attributeBases; - private ExcelConfig.ActivityObject _activityObject; + private ExcelConfig.ActivityBase _activityObject; private MapEditorCreateMark.NumberBar _altitude; private MapEditorCreateMark.NumberBar _vSpeed; @@ -25,7 +25,7 @@ public override void OnSetData(MarkInfoItem data) { //记得判断随机对象, 后面再做 - _activityObject = ExcelConfig.ActivityObject_Map[data.Id]; + _activityObject = ExcelConfig.ActivityBase_Map[data.Id]; //图标 if (string.IsNullOrEmpty(_activityObject.Icon)) { @@ -161,7 +161,7 @@ } } - private void CreateExpandPanel(ExcelConfig.ActivityObject activityObject, MarkInfoItem markInfoItem) + private void CreateExpandPanel(ExcelConfig.ActivityBase activityObject, MarkInfoItem markInfoItem) { if (_expandPanel != null) { @@ -218,7 +218,7 @@ numberBar.L_NumInput.Instance.MinValue = 0; numberBar2.L_NumInput.Instance.MinValue = 0; //武器配置数据 - var weapon = ExcelConfig.Weapon_List.Find(weapon => weapon.WeaponId == activityObject.Id); + var weapon = Weapon.GetWeaponAttribute(activityObject.Id); if (weapon != null) { numberBar.L_NumInput.Instance.MaxValue = weapon.AmmoCapacity; //弹夹上限 @@ -276,7 +276,7 @@ } if (markInfoItem.Attr.TryGetValue("Weapon", out var weaponId)) //武器 { - weaponBar.Instance.SelectWeapon(ExcelConfig.Weapon_List.Find(w => w.WeaponId == weaponId)); + weaponBar.Instance.SelectWeapon(Weapon.GetWeaponAttribute(weaponId)); } if (markInfoItem.Attr.TryGetValue("CurrAmmon", out var currAmmon)) //弹夹弹药量 { diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/attribute/ObjectAttribute.cs b/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/attribute/ObjectAttribute.cs index 0761a9a..b3d23ae 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/attribute/ObjectAttribute.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorCreateMark/attribute/ObjectAttribute.cs @@ -10,7 +10,7 @@ public ActivityType ActivityType { get; set; } private MapEditorCreateMark.ObjectBar _objectBar; //选择的武器数据 - private ExcelConfig.Weapon _selectWeapon; + private ExcelConfig.WeaponBase _selectWeapon; //关联属性 private MapEditorCreateMark.NumberBar _currAmmonAttr; private MapEditorCreateMark.NumberBar _residueAmmoAttr; @@ -33,7 +33,7 @@ { return null; } - return _selectWeapon.WeaponId; + return _selectWeapon.Activity.Id; } //点击编辑按钮 @@ -48,9 +48,9 @@ SelectWeapon(null); } - private void OnSelectObject(ExcelConfig.ActivityObject activityObject) + private void OnSelectObject(ExcelConfig.ActivityBase activityObject) { - var weapon = ExcelConfig.Weapon_List.Find(weapon => weapon.WeaponId == activityObject.Id); + var weapon = Weapon.GetWeaponAttribute(activityObject.Id); if (weapon != null) { SelectWeapon(weapon); @@ -60,7 +60,7 @@ /// /// 设置选择的武器物体 /// - public void SelectWeapon(ExcelConfig.Weapon weapon) + public void SelectWeapon(ExcelConfig.WeaponBase weapon) { if (weapon == null) { @@ -76,7 +76,7 @@ { _objectBar.L_HBoxContainer.L_DeleteButton.Instance.Visible = true; _selectWeapon = weapon; - var o = ExcelConfig.ActivityObject_Map[weapon.WeaponId]; + var o = weapon.Activity; //显示关联属性 _currAmmonAttr.Instance.Visible = true; _residueAmmoAttr.Instance.Visible = true; diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorMarkCell.cs b/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorMarkCell.cs index c36e547..8f96ec5 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorMarkCell.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorMarkCell.cs @@ -30,7 +30,7 @@ str += ","; } - str += ExcelConfig.ActivityObject_Map[markInfoItem.Id].Name; + str += ExcelConfig.ActivityBase_Map[markInfoItem.Id].Name; } text += str; } diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/MapEditorSelectObjectPanel.cs b/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/MapEditorSelectObjectPanel.cs index c06f20b..5776073 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/MapEditorSelectObjectPanel.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/MapEditorSelectObjectPanel.cs @@ -10,7 +10,7 @@ /// /// 双击选中物体事件 /// - public event Action SelectObjectEvent; + public event Action SelectObjectEvent; public class TypeButtonData { @@ -32,7 +32,7 @@ //类型网格组件 private UiGrid _typeGrid; //物体网格组件 - private UiGrid _objectGrid; + private UiGrid _objectGrid; //允许出现在该面板中的物体类型 private int[] _typeArray = new[] { 4, 5, 9 }; @@ -45,7 +45,7 @@ _typeGrid.SetHorizontalExpand(true); _typeGrid.SetCellOffset(new Vector2I(0, 5)); - _objectGrid = new UiGrid(S_ObjectButton, typeof(ObjectButtonCell)); + _objectGrid = new UiGrid(S_ObjectButton, typeof(ObjectButtonCell)); _objectGrid.SetAutoColumns(true); _objectGrid.SetHorizontalExpand(true); _objectGrid.SetCellOffset(new Vector2I(10, 10)); @@ -97,7 +97,7 @@ } //搜索结果 - var arr = ExcelConfig.ActivityObject_List.Where( + var arr = ExcelConfig.ActivityBase_List.Where( o => { return o.ShowInMapEditor && @@ -111,7 +111,7 @@ /// /// 选中对象 /// - public void SelectCell(ExcelConfig.ActivityObject activityObject) + public void SelectCell(ExcelConfig.ActivityBase activityObject) { if (SelectObjectEvent != null) { @@ -122,7 +122,7 @@ /// /// 获取选中的数据 /// - public ExcelConfig.ActivityObject GetSelectData() + public ExcelConfig.ActivityBase GetSelectData() { return _objectGrid.SelectData; } diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/ObjectButtonCell.cs b/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/ObjectButtonCell.cs index 9c4e03f..3b325c5 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/ObjectButtonCell.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorSelectObject/ObjectButtonCell.cs @@ -3,14 +3,14 @@ namespace UI.MapEditorSelectObject; -public class ObjectButtonCell : UiCell +public class ObjectButtonCell : UiCell { public override void OnInit() { CellNode.L_Select.Instance.Visible = false; } - public override void OnSetData(ExcelConfig.ActivityObject data) + public override void OnSetData(ExcelConfig.ActivityBase data) { CellNode.L_ObjectName.Instance.Text = data.Name; if (!string.IsNullOrEmpty(data.Icon)) diff --git a/DungeonShooting_Godot/src/game/ui/roomUI/InteractiveTipBar.cs b/DungeonShooting_Godot/src/game/ui/roomUI/InteractiveTipBar.cs index 85eb7da..3203984 100644 --- a/DungeonShooting_Godot/src/game/ui/roomUI/InteractiveTipBar.cs +++ b/DungeonShooting_Godot/src/game/ui/roomUI/InteractiveTipBar.cs @@ -46,7 +46,7 @@ /// 显示图标 public void ShowBar(ActivityObject target, string showText, Texture2D icon) { - _interactiveTipBar.Instance.GlobalPosition = target.GlobalPosition; + _interactiveTipBar.Instance.GlobalPosition = GameApplication.Instance.ViewToGlobalPosition(_interactiveTarget.GlobalPosition); _interactiveTipBar.L_Icon.Instance.Texture = icon; _interactiveTipBar.Instance.Visible = true; _interactiveTipBar.L_NameLabel.Instance.Text = showText; diff --git a/DungeonShooting_Godot/src/test/TestDrawSprite.cs b/DungeonShooting_Godot/src/test/TestDrawSprite.cs new file mode 100644 index 0000000..c7a0729 --- /dev/null +++ b/DungeonShooting_Godot/src/test/TestDrawSprite.cs @@ -0,0 +1,99 @@ +using Godot; +using System; +using System.Collections.Generic; + +public partial class TestDrawSprite : Node2D +{ + [Export] + public Label FpsLabel; + + [Export] + public PathFollow2D PathFollow2D; + + public override void _Ready() + { + // for (var i = 0; i < 10000; i++) + // { + // var image = Image.Create(50, 50, false, Image.Format.Rgba8); + // image.Fill(new Color(Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1), + // Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1))); + // var imageTexture = ImageTexture.CreateFromImage(image); + // var proxySprite = new ProxySprite(); + // proxySprite.SetTexture( + // this, + // imageTexture, + // new Vector2(Utils.Random.RandomRangeInt(0, 1600), Utils.Random.RandomRangeInt(0, 900)), + // Utils.Random.RandomRangeFloat(0, Mathf.Pi), + // new Vector2(Utils.Random.RandomRangeFloat(0.2f, 2f), Utils.Random.RandomRangeFloat(0.2f, 2f)), + // new Vector2(0, 5) + // ); + // } + } + + public override void _Process(double delta) + { + FpsLabel.Text = "FPS: " + 1 / delta; + PathFollow2D.Progress += 200 * (float)delta; + } + + //------------------------------------------------------------------------------------------------------------------------------- + + //使用sprite2d绘制精灵 + // public override void _Ready() + // { + // for (int i = 0; i < 20000; i++) + // { + // var image = Image.Create(50, 50, false, Image.Format.Rgba8); + // image.Fill(new Color(Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1))); + // var imageTexture = ImageTexture.CreateFromImage(image); + // var sprite2D = new Sprite2D(); + // sprite2D.Texture = imageTexture; + // sprite2D.Centered = false; + // sprite2D.Scale = new Vector2(Utils.Random.RandomRangeFloat(0.2f, 2f), Utils.Random.RandomRangeFloat(0.2f, 2f)); + // sprite2D.Rotation = Utils.Random.RandomRangeFloat(0, Mathf.Pi); + // sprite2D.Position = new Vector2(Utils.Random.RandomRangeInt(0, 1600), Utils.Random.RandomRangeInt(0, 900)); + // AddChild(sprite2D); + // } + // } + + //尝试使用DrawTexture绘制texture,结果发现性比sprite2d还差 + // private class DrawTextureData + // { + // public Texture2D Texture2D; + // public Vector2 Position; + // public float Rotation; + // public Vector2 Scale; + // } + // private List _texture2Ds = new List(); + + // public override void _Ready() + // { + // for (int i = 0; i < 10000; i++) + // { + // var image = Image.Create(100, 100, false, Image.Format.Rgba8); + // image.Fill(new Color(Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1), Utils.Random.RandomRangeFloat(0, 1))); + // var imageTexture = ImageTexture.CreateFromImage(image); + // _texture2Ds.Add(new DrawTextureData() + // { + // Texture2D = imageTexture, + // Position = new Vector2(Utils.Random.RandomRangeInt(0, 1600), Utils.Random.RandomRangeInt(0, 900)), + // Rotation = Utils.Random.RandomRangeFloat(0, Mathf.Pi), + // Scale = new Vector2(Utils.Random.RandomRangeFloat(0.2f, 2f), Utils.Random.RandomRangeFloat(0.2f, 2f)) + // }); + // } + // } + // + // public override void _Process(double delta) + // { + // QueueRedraw(); + // } + // + // public override void _Draw() + // { + // foreach (var texture2D in _texture2Ds) + // { + // DrawSetTransform(texture2D.Position, texture2D.Rotation, texture2D.Scale); + // DrawTexture(texture2D.Texture2D, Vector2.Zero); + // } + // } +} diff --git a/DungeonShooting_Godot/src/test/TestGridData.cs b/DungeonShooting_Godot/src/test/TestGridData.cs new file mode 100644 index 0000000..b7db7cb --- /dev/null +++ b/DungeonShooting_Godot/src/test/TestGridData.cs @@ -0,0 +1,104 @@ +using Godot; +using System; +using System.Collections.Generic; + +public partial class TestGridData : Node2D +{ + + public class TestGrid + { + public TestGrid(int width) + { + Width = width; + } + + public int Width { get; } + private Dictionary _dictionary = new Dictionary(); + + public void Set(int x, int y, T data) + { + if (x <= Width) + { + _dictionary[y * Width + x] = data; + } + } + + public T Get(int x, int y) + { + if (x <= Width && _dictionary.TryGetValue(y * Width + x, out var value)) + { + return value; + } + + return default; + } + + public void ForEach(Action callback) + { + foreach (var keyValuePair in _dictionary) + { + var index = keyValuePair.Key; + callback(index % Width, index / Width, keyValuePair.Value); + } + } + } + + public override void _Ready() + { + var time = DateTime.Now; + var testGrid = new TestGrid(100000); + for (int i = 0; i < 1000; i++) + { + for (int j = 0; j < 1000; j++) + { + testGrid.Set(i, j, i + j); + } + } + Debug.Log("TestGrid设置值用时: " + (DateTime.Now - time).Milliseconds); + + time = DateTime.Now; + var testGrid2 = new Grid(); + for (int i = 0; i < 1000; i++) + { + for (int j = 0; j < 1000; j++) + { + testGrid2.Set(i, j, i + j); + } + } + Debug.Log("Grid设置值用时: " + (DateTime.Now - time).Milliseconds); + + time = DateTime.Now; + for (int i = 0; i < 1000; i++) + { + for (int j = 0; j < 1000; j++) + { + testGrid.Get(i, j); + } + } + Debug.Log("TestGrid取值用时: " + (DateTime.Now - time).Milliseconds); + + time = DateTime.Now; + for (int i = 0; i < 1000; i++) + { + for (int j = 0; j < 1000; j++) + { + testGrid2.Get(i, j); + } + } + Debug.Log("Grid取值用时: " + (DateTime.Now - time).Milliseconds); + + time = DateTime.Now; + testGrid.ForEach((i, i1, arg3) => + { + + }); + Debug.Log("TestGrid遍历用时: " + (DateTime.Now - time).Milliseconds); + + time = DateTime.Now; + testGrid2.ForEach((i, i1, arg3) => + { + + }); + Debug.Log("Grid遍历用时: " + (DateTime.Now - time).Milliseconds); + } +} diff --git a/README.md b/README.md index 8949983..0acf3f2 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,6 @@ --- ### 其他 -**开发日志:** [开发日志.md](DungeonShooting_Document/开发日志.md) -**项目看板:** https://trello.com/b/a8UGxnTl/dungeonshooting +**开发日志:** [开发日志.md](DungeonShooting_Document/开发日志.md) **哔哩哔哩:** https://space.bilibili.com/259437820 **项目Ui插件:** https://github.com/xlljc/Ds_Ui \ No newline at end of file diff --git "a/\351\241\271\347\233\256\347\234\213\346\235\277.html" "b/\351\241\271\347\233\256\347\234\213\346\235\277.html" deleted file mode 100644 index bb1170f..0000000 --- "a/\351\241\271\347\233\256\347\234\213\346\235\277.html" +++ /dev/null @@ -1,3 +0,0 @@ - \ No newline at end of file