diff --git a/DungeonShooting_Godot/prefab/effect/Effect1.tscn b/DungeonShooting_Godot/prefab/effect/Effect1.tscn index df39e78..17115a1 100644 --- a/DungeonShooting_Godot/prefab/effect/Effect1.tscn +++ b/DungeonShooting_Godot/prefab/effect/Effect1.tscn @@ -1,5 +1,6 @@ [gd_scene load_steps=8 format=3 uid="uid://crx1kqqrymmdb"] +[ext_resource type="Material" uid="uid://c1chld6lkpgji" path="res://resource/material/SmokeParticleMaterial.tres" id="1_dxavj"] [ext_resource type="Texture2D" uid="uid://bs1lan5uwxyfg" path="res://resource/curve/Curve1.tres" id="1_s60r7"] [ext_resource type="Texture2D" uid="uid://h7hkgbwj1li" path="res://resource/effects/Smoke.png" id="2_3kyig"] [ext_resource type="Texture2D" uid="uid://csud4e6kc3iku" path="res://resource/effects/Effect1.png" id="3_1mceu"] @@ -11,20 +12,6 @@ particles_anim_v_frames = 1 particles_anim_loop = false -[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_wsy4a"] -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 -scale_min = 0.8 -scale_max = 0.8 -scale_curve = ExtResource("1_s60r7") -color = Color(0.760784, 0.760784, 0.760784, 0.533333) -anim_offset_max = 1.0 - [sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_pgx85"] particle_flag_align_y = true particle_flag_disable_z = true @@ -39,11 +26,12 @@ scale_curve = ExtResource("1_s60r7") [node name="Effect1" type="GPUParticles2D"] +modulate = Color(0.760784, 0.760784, 0.760784, 0.533333) z_index = 5 material = SubResource("CanvasItemMaterial_ipadv") emitting = false amount = 10 -process_material = SubResource("ParticleProcessMaterial_wsy4a") +process_material = ExtResource("1_dxavj") texture = ExtResource("2_3kyig") lifetime = 0.7 one_shot = true diff --git a/DungeonShooting_Godot/prefab/effect/activityObject/EnemyBloodEffect.tscn b/DungeonShooting_Godot/prefab/effect/activityObject/EnemyBloodEffect.tscn new file mode 100644 index 0000000..a96a14e --- /dev/null +++ b/DungeonShooting_Godot/prefab/effect/activityObject/EnemyBloodEffect.tscn @@ -0,0 +1,25 @@ +[gd_scene load_steps=5 format=3 uid="uid://dv3pstsr56ux7"] + +[ext_resource type="Material" uid="uid://c1chld6lkpgji" path="res://resource/material/SmokeParticleMaterial.tres" id="1_wwb7t"] +[ext_resource type="Texture2D" uid="uid://h7hkgbwj1li" path="res://resource/effects/Smoke.png" id="2_5rrhq"] +[ext_resource type="Script" path="res://src/game/effects/AutoDestroyEffect.cs" id="3_cvfk3"] + +[sub_resource type="CanvasItemMaterial" id="CanvasItemMaterial_emuda"] +particles_animation = true +particles_anim_h_frames = 3 +particles_anim_v_frames = 1 +particles_anim_loop = false + +[node name="EnemyBloodEffect" type="GPUParticles2D"] +modulate = Color(0.811765, 0.0980392, 0.0980392, 0.627451) +material = SubResource("CanvasItemMaterial_emuda") +emitting = false +amount = 10 +process_material = ExtResource("1_wwb7t") +texture = ExtResource("2_5rrhq") +lifetime = 1.2 +one_shot = true +explosiveness = 1.0 +fixed_fps = 20 +script = ExtResource("3_cvfk3") +DelayTime = 1.5 diff --git a/DungeonShooting_Godot/prefab/effect/activityObject/EnemyDebris.tscn b/DungeonShooting_Godot/prefab/effect/activityObject/EnemyDebris.tscn new file mode 100644 index 0000000..58a339d --- /dev/null +++ b/DungeonShooting_Godot/prefab/effect/activityObject/EnemyDebris.tscn @@ -0,0 +1,191 @@ +[gd_scene load_steps=30 format=3 uid="uid://cj47w003yql4x"] + +[ext_resource type="Script" path="res://src/framework/activity/ActivityObjectTemplate.cs" id="1_h7exw"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_vlp01"] +[ext_resource type="Texture2D" uid="uid://d2f55lu60x64i" path="res://resource/effects/activityObject/Enemy0001_Debris.png" id="3_ohnrx"] +[ext_resource type="Texture2D" uid="uid://h7hkgbwj1li" path="res://resource/effects/Smoke.png" id="4_e30nm"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_s1mj2"] +resource_local_to_scene = true +shader = ExtResource("2_vlp01") +shader_parameter/blend = Color(0, 0, 0, 0.470588) +shader_parameter/schedule = 1 + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_08fn3"] +resource_local_to_scene = true +shader = ExtResource("2_vlp01") +shader_parameter/blend = Color(1, 1, 1, 1) +shader_parameter/schedule = 0 + +[sub_resource type="AtlasTexture" id="AtlasTexture_hqaf2"] +atlas = ExtResource("3_ohnrx") +region = Rect2(0, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_b55yq"] +atlas = ExtResource("3_ohnrx") +region = Rect2(8, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_6ouxh"] +atlas = ExtResource("3_ohnrx") +region = Rect2(16, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_sfr41"] +atlas = ExtResource("3_ohnrx") +region = Rect2(24, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_j5qpi"] +atlas = ExtResource("3_ohnrx") +region = Rect2(32, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ltfhd"] +atlas = ExtResource("3_ohnrx") +region = Rect2(40, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_oh4q1"] +atlas = ExtResource("3_ohnrx") +region = Rect2(48, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ebvnk"] +atlas = ExtResource("3_ohnrx") +region = Rect2(56, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_lboyj"] +atlas = ExtResource("3_ohnrx") +region = Rect2(64, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_6qefr"] +atlas = ExtResource("3_ohnrx") +region = Rect2(72, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_aya5f"] +atlas = ExtResource("3_ohnrx") +region = Rect2(80, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_el804"] +atlas = ExtResource("3_ohnrx") +region = Rect2(88, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_pha71"] +atlas = ExtResource("3_ohnrx") +region = Rect2(96, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_ps4oc"] +atlas = ExtResource("3_ohnrx") +region = Rect2(104, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_l8my6"] +atlas = ExtResource("3_ohnrx") +region = Rect2(112, 0, 8, 8) + +[sub_resource type="AtlasTexture" id="AtlasTexture_4jpot"] +atlas = ExtResource("3_ohnrx") +region = Rect2(120, 0, 8, 8) + +[sub_resource type="SpriteFrames" id="SpriteFrames_15g84"] +animations = [{ +"frames": [{ +"duration": 1.0, +"texture": SubResource("AtlasTexture_hqaf2") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_b55yq") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_6ouxh") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_sfr41") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_j5qpi") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ltfhd") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_oh4q1") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ebvnk") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_lboyj") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_6qefr") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_aya5f") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_el804") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_pha71") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_ps4oc") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_l8my6") +}, { +"duration": 1.0, +"texture": SubResource("AtlasTexture_4jpot") +}], +"loop": true, +"name": &"default", +"speed": 5.0 +}] + +[sub_resource type="CanvasItemMaterial" id="CanvasItemMaterial_p3lv8"] +particles_animation = true +particles_anim_h_frames = 3 +particles_anim_v_frames = 1 +particles_anim_loop = false + +[sub_resource type="Gradient" id="Gradient_ryemi"] +colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 0.537255) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_orgu0"] +gradient = SubResource("Gradient_ryemi") + +[sub_resource type="Curve" id="Curve_21dxk"] +_data = [Vector2(0, 0), 0.0, 0.0, 0, 0, Vector2(0.177419, 1), 0.0, 0.0, 0, 0, Vector2(1, 0.0272727), 0.0, 0.0, 0, 0] +point_count = 3 + +[sub_resource type="CurveTexture" id="CurveTexture_rutlp"] +curve = SubResource("Curve_21dxk") + +[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 +scale_min = 0.4 +scale_max = 1.5 +scale_curve = SubResource("CurveTexture_rutlp") +color = Color(0.811765, 0.0980392, 0.0980392, 0.627451) +color_ramp = SubResource("GradientTexture1D_orgu0") +anim_offset_max = 1.0 + +[node name="EnemyDebris" type="Node"] +script = ExtResource("1_h7exw") +collision_mask = 1 + +[node name="ShadowSprite" type="Sprite2D" parent="."] +z_index = -1 +material = SubResource("ShaderMaterial_s1mj2") + +[node name="AnimatedSprite" type="AnimatedSprite2D" parent="."] +material = SubResource("ShaderMaterial_08fn3") +sprite_frames = SubResource("SpriteFrames_15g84") + +[node name="Collision" type="CollisionShape2D" parent="."] + +[node name="GPUParticles2D" type="GPUParticles2D" parent="."] +material = SubResource("CanvasItemMaterial_p3lv8") +emitting = false +process_material = SubResource("ParticleProcessMaterial_ku1mm") +texture = ExtResource("4_e30nm") +fixed_fps = 20 diff --git a/DungeonShooting_Godot/prefab/map/RoomDoor.tscn b/DungeonShooting_Godot/prefab/map/RoomDoor.tscn index 55266c6..ce49453 100644 --- a/DungeonShooting_Godot/prefab/map/RoomDoor.tscn +++ b/DungeonShooting_Godot/prefab/map/RoomDoor.tscn @@ -1,7 +1,7 @@ -[gd_scene load_steps=10 format=3 uid="uid://dl62yuh5q656a"] +[gd_scene load_steps=10 format=3] [ext_resource type="Script" path="res://src/framework/activity/ActivityObjectTemplate.cs" id="1_8es7a"] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="2_d8jnk"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_d8jnk"] [ext_resource type="Texture2D" uid="uid://dviv44fhwvkb1" path="res://resource/sprite/map/door1_down.png" id="3_knmoy"] [sub_resource type="ShaderMaterial" id="ShaderMaterial_x5aop"] diff --git a/DungeonShooting_Godot/prefab/role/Enemy.tscn b/DungeonShooting_Godot/prefab/role/Enemy.tscn index 7c54d07..04a1f50 100644 --- a/DungeonShooting_Godot/prefab/role/Enemy.tscn +++ b/DungeonShooting_Godot/prefab/role/Enemy.tscn @@ -1,78 +1,78 @@ [gd_scene load_steps=20 format=3 uid="uid://dbrig6dq441wo"] [ext_resource type="PackedScene" uid="uid://b515ti0qinck8" path="res://prefab/role/Role.tscn" id="1_qkqsa"] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="2_in1s7"] -[ext_resource type="Texture2D" uid="uid://un6gylhe011n" path="res://resource/sprite/role/role8.png" id="3_tk1tp"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_1ah5y"] +[ext_resource type="Texture2D" uid="uid://chd2vtesap5cf" path="res://resource/sprite/role/role1.png" id="3_tqhbo"] [sub_resource type="ShaderMaterial" id="ShaderMaterial_8vxx6"] resource_local_to_scene = true -shader = ExtResource("2_in1s7") +shader = ExtResource("2_1ah5y") shader_parameter/blend = Color(0, 0, 0, 0.470588) shader_parameter/schedule = 1 [sub_resource type="ShaderMaterial" id="ShaderMaterial_k8mt5"] resource_local_to_scene = true -shader = ExtResource("2_in1s7") +shader = ExtResource("2_1ah5y") shader_parameter/blend = Color(1, 1, 1, 1) shader_parameter/schedule = 0 -[sub_resource type="AtlasTexture" id="AtlasTexture_b4gmf"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_gx4d0"] +atlas = ExtResource("3_tqhbo") region = Rect2(0, 0, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_ps4o2"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_da1qy"] +atlas = ExtResource("3_tqhbo") region = Rect2(0, 24, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_00s75"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_qr6u5"] +atlas = ExtResource("3_tqhbo") region = Rect2(16, 24, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_ov7r3"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_yxi4p"] +atlas = ExtResource("3_tqhbo") region = Rect2(32, 24, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_7o5sg"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_1g0j1"] +atlas = ExtResource("3_tqhbo") region = Rect2(48, 24, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_3cf41"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_mqoog"] +atlas = ExtResource("3_tqhbo") region = Rect2(48, 48, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_ore1n"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_6n45h"] +atlas = ExtResource("3_tqhbo") region = Rect2(32, 48, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_0yx8e"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_7bfvr"] +atlas = ExtResource("3_tqhbo") region = Rect2(16, 48, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_v2had"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_jep37"] +atlas = ExtResource("3_tqhbo") region = Rect2(0, 48, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_myxvk"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_n0mff"] +atlas = ExtResource("3_tqhbo") region = Rect2(0, 48, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_t5tkd"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_snkia"] +atlas = ExtResource("3_tqhbo") region = Rect2(16, 48, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_ia68q"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_l4qvj"] +atlas = ExtResource("3_tqhbo") region = Rect2(32, 48, 16, 24) -[sub_resource type="AtlasTexture" id="AtlasTexture_ueb6d"] -atlas = ExtResource("3_tk1tp") +[sub_resource type="AtlasTexture" id="AtlasTexture_yxje3"] +atlas = ExtResource("3_tqhbo") region = Rect2(48, 48, 16, 24) [sub_resource type="SpriteFrames" id="SpriteFrames_m7t3e"] animations = [{ "frames": [{ "duration": 1.0, -"texture": SubResource("AtlasTexture_b4gmf") +"texture": SubResource("AtlasTexture_gx4d0") }], "loop": true, "name": &"default", @@ -80,16 +80,16 @@ }, { "frames": [{ "duration": 1.0, -"texture": SubResource("AtlasTexture_ps4o2") +"texture": SubResource("AtlasTexture_da1qy") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_00s75") +"texture": SubResource("AtlasTexture_qr6u5") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_ov7r3") +"texture": SubResource("AtlasTexture_yxi4p") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_7o5sg") +"texture": SubResource("AtlasTexture_1g0j1") }], "loop": true, "name": &"idle", @@ -97,16 +97,16 @@ }, { "frames": [{ "duration": 1.0, -"texture": SubResource("AtlasTexture_3cf41") +"texture": SubResource("AtlasTexture_mqoog") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_ore1n") +"texture": SubResource("AtlasTexture_6n45h") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_0yx8e") +"texture": SubResource("AtlasTexture_7bfvr") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_v2had") +"texture": SubResource("AtlasTexture_jep37") }], "loop": true, "name": &"reverseRun", @@ -114,16 +114,16 @@ }, { "frames": [{ "duration": 1.0, -"texture": SubResource("AtlasTexture_myxvk") +"texture": SubResource("AtlasTexture_n0mff") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_t5tkd") +"texture": SubResource("AtlasTexture_snkia") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_ia68q") +"texture": SubResource("AtlasTexture_l4qvj") }, { "duration": 1.0, -"texture": SubResource("AtlasTexture_ueb6d") +"texture": SubResource("AtlasTexture_yxje3") }], "loop": true, "name": &"run", @@ -140,6 +140,7 @@ [node name="AnimatedSprite" parent="." index="2"] material = SubResource("ShaderMaterial_k8mt5") sprite_frames = SubResource("SpriteFrames_m7t3e") +frame_progress = 0.877597 [node name="HurtArea" parent="." index="4"] visible = false diff --git a/DungeonShooting_Godot/prefab/role/Player.tscn b/DungeonShooting_Godot/prefab/role/Player.tscn index 994067e..016c4b5 100644 --- a/DungeonShooting_Godot/prefab/role/Player.tscn +++ b/DungeonShooting_Godot/prefab/role/Player.tscn @@ -1,7 +1,7 @@ -[gd_scene load_steps=20 format=3 uid="uid://cdohv4xeirtuc"] +[gd_scene load_steps=20 format=3] [ext_resource type="PackedScene" uid="uid://b515ti0qinck8" path="res://prefab/role/Role.tscn" id="1"] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="2_nvo1u"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_nvo1u"] [ext_resource type="Texture2D" uid="uid://bhwhhg2dfsr26" path="res://resource/sprite/role/role2.png" id="3_55mk2"] [sub_resource type="ShaderMaterial" id="ShaderMaterial_vejn8"] diff --git a/DungeonShooting_Godot/prefab/role/Role.tscn b/DungeonShooting_Godot/prefab/role/Role.tscn index 4882f43..0b11811 100644 --- a/DungeonShooting_Godot/prefab/role/Role.tscn +++ b/DungeonShooting_Godot/prefab/role/Role.tscn @@ -1,7 +1,7 @@ -[gd_scene load_steps=9 format=3 uid="uid://b515ti0qinck8"] +[gd_scene load_steps=9 format=3] [ext_resource type="Script" path="res://src/framework/activity/ActivityObjectTemplate.cs" id="1_hm41b"] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="2_q6jwp"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_q6jwp"] [ext_resource type="Script" path="res://src/game/role/MountRotation.cs" id="4"] [sub_resource type="ShaderMaterial" id="ShaderMaterial_v2kfw"] diff --git a/DungeonShooting_Godot/prefab/test/TestActivity.tscn b/DungeonShooting_Godot/prefab/test/TestActivity.tscn index 4f7ee6c..203f1e7 100644 --- a/DungeonShooting_Godot/prefab/test/TestActivity.tscn +++ b/DungeonShooting_Godot/prefab/test/TestActivity.tscn @@ -1,9 +1,10 @@ -[gd_scene load_steps=7 format=3 uid="uid://bjf0e6nehg51j"] +[gd_scene load_steps=7 format=3] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="1"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="1"] [ext_resource type="Script" path="res://src/framework/activity/ActivityObjectTemplate.cs" id="2"] [ext_resource type="Texture2D" uid="uid://uhhfgdhpk7i4" path="res://icon.png" id="3"] + [sub_resource type="ShaderMaterial" id="ShaderMaterial_rxkv3"] resource_local_to_scene = true shader = ExtResource("1") diff --git a/DungeonShooting_Godot/prefab/weapon/Knife.tscn b/DungeonShooting_Godot/prefab/weapon/Knife.tscn index 471711e..c1b92fa 100644 --- a/DungeonShooting_Godot/prefab/weapon/Knife.tscn +++ b/DungeonShooting_Godot/prefab/weapon/Knife.tscn @@ -1,10 +1,11 @@ -[gd_scene load_steps=8 format=3 uid="uid://cji4nrwabt4ky"] +[gd_scene load_steps=8 format=3] [ext_resource type="PackedScene" uid="uid://bcosbsgt7a7o3" path="res://prefab/weapon/Weapon.tscn" id="1_xk7sg"] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="2_vwwhv"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2_vwwhv"] [ext_resource type="Texture2D" uid="uid://bxhbsq0wb2yo1" path="res://resource/sprite/gun/knife1.png" id="3_s52oh"] [ext_resource type="PackedScene" path="res://prefab/FanCollisionShape.tscn" id="3_wdje6"] + [sub_resource type="ShaderMaterial" id="ShaderMaterial_o5ytq"] resource_local_to_scene = true shader = ExtResource("2_vwwhv") diff --git a/DungeonShooting_Godot/prefab/weapon/Weapon.tscn b/DungeonShooting_Godot/prefab/weapon/Weapon.tscn index 7ad9039..139fef6 100644 --- a/DungeonShooting_Godot/prefab/weapon/Weapon.tscn +++ b/DungeonShooting_Godot/prefab/weapon/Weapon.tscn @@ -1,8 +1,9 @@ -[gd_scene load_steps=9 format=3 uid="uid://bcosbsgt7a7o3"] +[gd_scene load_steps=9 format=3] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="1"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="1"] [ext_resource type="Script" path="res://src/framework/activity/ActivityObjectTemplate.cs" id="1_dtam7"] + [sub_resource type="ShaderMaterial" id="ShaderMaterial_cbiyh"] resource_local_to_scene = true shader = ExtResource("1") diff --git a/DungeonShooting_Godot/prefab/weapon/bullet/Bullet.tscn b/DungeonShooting_Godot/prefab/weapon/bullet/Bullet.tscn index 7f1d347..e0b78f3 100644 --- a/DungeonShooting_Godot/prefab/weapon/bullet/Bullet.tscn +++ b/DungeonShooting_Godot/prefab/weapon/bullet/Bullet.tscn @@ -1,9 +1,10 @@ -[gd_scene load_steps=9 format=3 uid="uid://gaa31i7420h"] +[gd_scene load_steps=9 format=3] [ext_resource type="Script" path="res://src/framework/activity/ActivityObjectTemplate.cs" id="1_nwypj"] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="2"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2"] [ext_resource type="Texture2D" uid="uid://bu0b11hiuecxy" path="res://resource/sprite/bullet/bullet.png" id="3"] + [sub_resource type="ShaderMaterial" id="ShaderMaterial_5a4f2"] resource_local_to_scene = true shader = ExtResource("2") diff --git a/DungeonShooting_Godot/prefab/weapon/shell/ShellCase.tscn b/DungeonShooting_Godot/prefab/weapon/shell/ShellCase.tscn index 0fda121..48d475e 100644 --- a/DungeonShooting_Godot/prefab/weapon/shell/ShellCase.tscn +++ b/DungeonShooting_Godot/prefab/weapon/shell/ShellCase.tscn @@ -1,8 +1,8 @@ -[gd_scene load_steps=10 format=3 uid="uid://bj4yr6ru8nhwr"] +[gd_scene load_steps=7 format=3 uid="uid://bj4yr6ru8nhwr"] [ext_resource type="Texture2D" uid="uid://dto03bc2qbhnj" path="res://resource/sprite/shell/shellCase.png" id="1"] [ext_resource type="Script" path="res://src/framework/activity/ActivityObjectTemplate.cs" id="1_nmhqm"] -[ext_resource type="Shader" path="res://resource/materlal/Blend.gdshader" id="2"] +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="2"] [sub_resource type="ShaderMaterial" id="ShaderMaterial_px12l"] resource_local_to_scene = true @@ -27,56 +27,6 @@ "speed": 5.0 }] -[sub_resource type="Animation" id="Animation_pfprw"] -length = 0.001 -tracks/0/type = "value" -tracks/0/imported = false -tracks/0/enabled = true -tracks/0/path = NodePath(".:visible") -tracks/0/interp = 1 -tracks/0/loop_wrap = true -tracks/0/keys = { -"times": PackedFloat32Array(0), -"transitions": PackedFloat32Array(1), -"update": 1, -"values": [true] -} - -[sub_resource type="Animation" id="Animation_kjsto"] -resource_name = "flicker" -tracks/0/type = "value" -tracks/0/imported = false -tracks/0/enabled = true -tracks/0/path = NodePath(".:visible") -tracks/0/interp = 1 -tracks/0/loop_wrap = true -tracks/0/keys = { -"times": PackedFloat32Array(0, 0.5, 0.6, 0.7, 0.8, 0.9, 1), -"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1), -"update": 1, -"values": [true, true, false, true, false, true, false] -} -tracks/1/type = "method" -tracks/1/imported = false -tracks/1/enabled = true -tracks/1/path = NodePath(".") -tracks/1/interp = 1 -tracks/1/loop_wrap = true -tracks/1/keys = { -"times": PackedFloat32Array(1), -"transitions": PackedFloat32Array(1), -"values": [{ -"args": [], -"method": &"queue_free" -}] -} - -[sub_resource type="AnimationLibrary" id="AnimationLibrary_cpq4j"] -_data = { -"RESET": SubResource("Animation_pfprw"), -"flicker": SubResource("Animation_kjsto") -} - [node name="ShellCase" type="Node"] script = ExtResource("1_nmhqm") @@ -89,8 +39,3 @@ sprite_frames = SubResource("SpriteFrames_4huvy") [node name="Collision" type="CollisionShape2D" parent="."] - -[node name="AnimationPlayer" type="AnimationPlayer" parent="."] -libraries = { -"": SubResource("AnimationLibrary_cpq4j") -} diff --git a/DungeonShooting_Godot/resource/effects/activityObject/Enemy0001_Debris.png b/DungeonShooting_Godot/resource/effects/activityObject/Enemy0001_Debris.png new file mode 100644 index 0000000..1c4d212 --- /dev/null +++ b/DungeonShooting_Godot/resource/effects/activityObject/Enemy0001_Debris.png Binary files differ diff --git a/DungeonShooting_Godot/resource/effects/activityObject/Enemy0001_Debris.png.import b/DungeonShooting_Godot/resource/effects/activityObject/Enemy0001_Debris.png.import new file mode 100644 index 0000000..a522847 --- /dev/null +++ b/DungeonShooting_Godot/resource/effects/activityObject/Enemy0001_Debris.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://d2f55lu60x64i" +path="res://.godot/imported/Enemy0001_Debris.png-acec55b336255e10e72d7cc4a1ba1163.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/effects/activityObject/Enemy0001_Debris.png" +dest_files=["res://.godot/imported/Enemy0001_Debris.png-acec55b336255e10e72d7cc4a1ba1163.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/material/Blend.gdshader b/DungeonShooting_Godot/resource/material/Blend.gdshader new file mode 100644 index 0000000..68a6001 --- /dev/null +++ b/DungeonShooting_Godot/resource/material/Blend.gdshader @@ -0,0 +1,10 @@ +shader_type canvas_item; + +uniform vec4 blend : source_color = vec4(1.0, 1.0, 1.0, 1.0); +uniform float schedule = 1.0; + +void fragment() { + vec4 textureColor = texture(TEXTURE, UV); + vec4 col = mix(textureColor, blend, schedule); + COLOR = mix(vec4(0.0, 0.0, 0.0, 0.0), col, textureColor.a); +} diff --git a/DungeonShooting_Godot/resource/material/Blend.tres b/DungeonShooting_Godot/resource/material/Blend.tres new file mode 100644 index 0000000..02c6b22 --- /dev/null +++ b/DungeonShooting_Godot/resource/material/Blend.tres @@ -0,0 +1,11 @@ +[gd_resource type="ShaderMaterial" load_steps=2 format=3] + +[ext_resource type="Shader" path="res://resource/material/Blend.gdshader" id="1"] + + +[resource] +resource_local_to_scene = true +render_priority = 4 +shader = ExtResource( 1 ) +shader_param/blend = Color( 0, 0, 0, 0.470588 ) +shader_param/schedule = 1 diff --git a/DungeonShooting_Godot/resource/material/SmokeParticleMaterial.tres b/DungeonShooting_Godot/resource/material/SmokeParticleMaterial.tres new file mode 100644 index 0000000..1bbb83e --- /dev/null +++ b/DungeonShooting_Godot/resource/material/SmokeParticleMaterial.tres @@ -0,0 +1,17 @@ +[gd_resource type="ParticleProcessMaterial" load_steps=2 format=3 uid="uid://c1chld6lkpgji"] + +[ext_resource type="Texture2D" uid="uid://bs1lan5uwxyfg" path="res://resource/curve/Curve1.tres" id="1_yr5l8"] + +[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 +scale_min = 0.8 +scale_max = 0.8 +scale_curve = ExtResource("1_yr5l8") +color = Color(1, 1, 1, 0.533333) +anim_offset_max = 1.0 diff --git a/DungeonShooting_Godot/resource/materlal/Blend.gdshader b/DungeonShooting_Godot/resource/materlal/Blend.gdshader deleted file mode 100644 index 68a6001..0000000 --- a/DungeonShooting_Godot/resource/materlal/Blend.gdshader +++ /dev/null @@ -1,10 +0,0 @@ -shader_type canvas_item; - -uniform vec4 blend : source_color = vec4(1.0, 1.0, 1.0, 1.0); -uniform float schedule = 1.0; - -void fragment() { - vec4 textureColor = texture(TEXTURE, UV); - vec4 col = mix(textureColor, blend, schedule); - COLOR = mix(vec4(0.0, 0.0, 0.0, 0.0), col, textureColor.a); -} diff --git a/DungeonShooting_Godot/resource/materlal/Blend.tres b/DungeonShooting_Godot/resource/materlal/Blend.tres deleted file mode 100644 index 1bfd155..0000000 --- a/DungeonShooting_Godot/resource/materlal/Blend.tres +++ /dev/null @@ -1,10 +0,0 @@ -[gd_resource type="ShaderMaterial" load_steps=2 format=2] - -[ext_resource path="res://resource/materlal/Blend.gdshader" type="Shader" id=1] - -[resource] -resource_local_to_scene = true -render_priority = 4 -shader = ExtResource( 1 ) -shader_param/blend = Color( 0, 0, 0, 0.470588 ) -shader_param/schedule = 1 diff --git a/DungeonShooting_Godot/resource/theme/mainTheme.tres b/DungeonShooting_Godot/resource/theme/mainTheme.tres index e43f73e..f0db64e 100644 --- a/DungeonShooting_Godot/resource/theme/mainTheme.tres +++ b/DungeonShooting_Godot/resource/theme/mainTheme.tres @@ -352,7 +352,7 @@ [sub_resource type="ImageTexture" id="58"] -[sub_resource type="Image" id="Image_g0d4n"] +[sub_resource type="Image" id="Image_151oh"] data = { "data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 1, 255, 255, 255, 39, 255, 255, 255, 67, 255, 255, 255, 67, 255, 255, 255, 39, 255, 255, 255, 1, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 39, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 39, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 66, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 66, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 66, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 66, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 39, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 39, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 1, 255, 255, 255, 39, 255, 255, 255, 67, 255, 255, 255, 67, 255, 255, 255, 39, 255, 255, 255, 1, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), "format": "RGBA8", @@ -362,7 +362,7 @@ } [sub_resource type="ImageTexture" id="60"] -image = SubResource("Image_g0d4n") +image = SubResource("Image_151oh") [sub_resource type="StyleBoxTexture" id="61"] content_margin_left = 2.0 @@ -372,7 +372,7 @@ texture = SubResource("60") region_rect = Rect2(0, 0, 12, 12) -[sub_resource type="Image" id="Image_b8fbs"] +[sub_resource type="Image" id="Image_ev2o0"] data = { "data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 247, 247, 247, 0, 248, 248, 248, 0, 248, 248, 248, 0, 247, 247, 247, 0, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 191, 191, 191, 4, 247, 247, 247, 98, 248, 248, 248, 167, 248, 248, 248, 167, 247, 247, 247, 98, 191, 191, 191, 4, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 247, 247, 247, 0, 247, 247, 247, 97, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 247, 247, 247, 97, 247, 247, 247, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 248, 248, 248, 0, 248, 248, 248, 164, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 164, 248, 248, 248, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 248, 248, 248, 0, 248, 248, 248, 164, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 164, 248, 248, 248, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 247, 247, 247, 0, 247, 247, 247, 97, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 247, 247, 247, 97, 247, 247, 247, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 191, 191, 191, 4, 247, 247, 247, 98, 248, 248, 248, 167, 248, 248, 248, 167, 247, 247, 247, 98, 191, 191, 191, 4, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 247, 247, 247, 0, 248, 248, 248, 0, 248, 248, 248, 0, 247, 247, 247, 0, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), "format": "RGBA8", @@ -382,7 +382,7 @@ } [sub_resource type="ImageTexture" id="63"] -image = SubResource("Image_b8fbs") +image = SubResource("Image_ev2o0") [sub_resource type="StyleBoxTexture" id="64"] content_margin_left = 2.0 @@ -392,7 +392,7 @@ texture = SubResource("63") region_rect = Rect2(0, 0, 12, 12) -[sub_resource type="Image" id="Image_cjqw6"] +[sub_resource type="Image" id="Image_22as7"] data = { "data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 127, 127, 127, 4, 173, 173, 173, 97, 173, 173, 173, 166, 173, 173, 173, 166, 173, 173, 173, 97, 127, 127, 127, 4, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 172, 172, 172, 0, 172, 172, 172, 96, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 172, 172, 172, 96, 172, 172, 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 173, 173, 173, 0, 173, 173, 173, 163, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 163, 173, 173, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 173, 173, 173, 0, 173, 173, 173, 163, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 163, 173, 173, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 172, 172, 172, 0, 172, 172, 172, 96, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 172, 172, 172, 96, 172, 172, 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 127, 127, 127, 4, 173, 173, 173, 97, 173, 173, 173, 166, 173, 173, 173, 166, 173, 173, 173, 97, 127, 127, 127, 4, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), "format": "RGBA8", @@ -402,7 +402,7 @@ } [sub_resource type="ImageTexture" id="66"] -image = SubResource("Image_cjqw6") +image = SubResource("Image_22as7") [sub_resource type="StyleBoxTexture" id="67"] content_margin_left = 2.0 @@ -412,7 +412,7 @@ texture = SubResource("66") region_rect = Rect2(0, 0, 12, 12) -[sub_resource type="Image" id="Image_nu7wl"] +[sub_resource type="Image" id="Image_xsoii"] data = { "data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 4, 255, 255, 255, 16, 255, 255, 255, 16, 255, 255, 255, 4, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 16, 255, 255, 255, 21, 255, 255, 255, 21, 255, 255, 255, 16, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 16, 255, 255, 255, 21, 255, 255, 255, 21, 255, 255, 255, 16, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 4, 255, 255, 255, 16, 255, 255, 255, 16, 255, 255, 255, 4, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), "format": "RGBA8", @@ -422,7 +422,7 @@ } [sub_resource type="ImageTexture" id="69"] -image = SubResource("Image_nu7wl") +image = SubResource("Image_xsoii") [sub_resource type="StyleBoxTexture" id="70"] content_margin_left = 0.0 @@ -446,7 +446,7 @@ content_margin_right = 4.0 content_margin_bottom = 4.0 -[sub_resource type="Image" id="Image_bhkb5"] +[sub_resource type="Image" id="Image_g5uvy"] data = { "data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 76, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 76, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 76, 255, 255, 255, 228, 255, 255, 255, 188, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 188, 255, 255, 255, 228, 255, 255, 255, 76, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 18, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 187, 255, 255, 255, 17, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 187, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 18, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 185, 255, 255, 255, 17, 255, 255, 255, 17, 255, 255, 255, 186, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 190, 255, 255, 255, 229, 255, 255, 255, 185, 255, 255, 255, 185, 255, 255, 255, 229, 255, 255, 255, 189, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 191, 255, 255, 255, 229, 255, 255, 255, 229, 255, 255, 255, 190, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 187, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 187, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 18, 255, 255, 255, 19, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 186, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 185, 255, 255, 255, 229, 255, 255, 255, 189, 255, 255, 255, 19, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 189, 255, 255, 255, 229, 255, 255, 255, 185, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 76, 255, 255, 255, 229, 255, 255, 255, 190, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 190, 255, 255, 255, 229, 255, 255, 255, 76, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 77, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 77, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), "format": "RGBA8", @@ -456,7 +456,7 @@ } [sub_resource type="ImageTexture" id="56"] -image = SubResource("Image_bhkb5") +image = SubResource("Image_g5uvy") [sub_resource type="StyleBoxFlat" id="57"] content_margin_left = 6.0 diff --git a/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs b/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs index 8d295c0..629c16b 100644 --- a/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs +++ b/DungeonShooting_Godot/src/framework/activity/ActivityObject.cs @@ -556,9 +556,9 @@ /// 将该节点投抛出去 /// /// 初始高度 - /// 旋转速度 - /// 移动速率 /// 纵轴速度 + /// 移动速率 + /// 旋转速度 public void Throw(float altitude, float verticalSpeed, Vector2 velocity, float rotate) { var parent = GetParent(); @@ -590,9 +590,9 @@ /// /// 初始位置 /// 初始高度 - /// 旋转速度 - /// 移动速率 /// 纵轴速度 + /// 移动速率 + /// 旋转速度 public void Throw(Vector2 position, float altitude, float verticalSpeed, Vector2 velocity, float rotate) { GlobalPosition = position; diff --git a/DungeonShooting_Godot/src/framework/activity/ActivityObjectTemplate.cs b/DungeonShooting_Godot/src/framework/activity/ActivityObjectTemplate.cs index 201d18d..30a1ce2 100644 --- a/DungeonShooting_Godot/src/framework/activity/ActivityObjectTemplate.cs +++ b/DungeonShooting_Godot/src/framework/activity/ActivityObjectTemplate.cs @@ -68,7 +68,7 @@ sprite.Name = "ShadowSprite"; sprite.ZIndex = -1; var material = - ResourceManager.Load(ResourcePath.resource_materlal_Blend_tres, false); + ResourceManager.Load(ResourcePath.resource_material_Blend_tres, false); material.SetShaderParameter("blend", new Color(0, 0, 0, 0.47058824F)); material.SetShaderParameter("schedule", 1); sprite.Material = material; @@ -78,7 +78,7 @@ else if (sprite.Material == null) { var material = - ResourceManager.Load(ResourcePath.resource_materlal_Blend_tres, false); + ResourceManager.Load(ResourcePath.resource_material_Blend_tres, false); material.SetShaderParameter("blend", new Color(0, 0, 0, 0.47058824F)); material.SetShaderParameter("schedule", 1); sprite.Material = material; @@ -91,7 +91,7 @@ animatedSprite = new AnimatedSprite2D(); animatedSprite.Name = "AnimatedSprite"; var material = - ResourceManager.Load(ResourcePath.resource_materlal_Blend_tres, false); + ResourceManager.Load(ResourcePath.resource_material_Blend_tres, false); material.SetShaderParameter("blend", new Color(1, 1, 1, 1)); material.SetShaderParameter("schedule", 0); animatedSprite.Material = material; @@ -101,7 +101,7 @@ else if (animatedSprite.Material == null) { var material = - ResourceManager.Load(ResourcePath.resource_materlal_Blend_tres, false); + ResourceManager.Load(ResourcePath.resource_material_Blend_tres, false); material.SetShaderParameter("blend", new Color(1, 1, 1, 1)); material.SetShaderParameter("schedule", 0); animatedSprite.Material = material; diff --git a/DungeonShooting_Godot/src/game/effects/AutoDestroyEffect.cs b/DungeonShooting_Godot/src/game/effects/AutoDestroyEffect.cs new file mode 100644 index 0000000..c8e2b97 --- /dev/null +++ b/DungeonShooting_Godot/src/game/effects/AutoDestroyEffect.cs @@ -0,0 +1,19 @@ + +using Godot; + +public partial class AutoDestroyEffect : GpuParticles2D +{ + /// + /// 延时销毁时间 + /// + [Export] + public float DelayTime = 1f; + + public override async void _Ready() + { + Emitting = true; + var sceneTreeTimer = GetTree().CreateTimer(DelayTime); + await ToSignal(sceneTreeTimer, Timer.SignalName.Timeout); + QueueFree(); + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/effects/Effect1.cs b/DungeonShooting_Godot/src/game/effects/Effect1.cs index 2bf5ca0..5f43297 100644 --- a/DungeonShooting_Godot/src/game/effects/Effect1.cs +++ b/DungeonShooting_Godot/src/game/effects/Effect1.cs @@ -1,17 +1,14 @@ using Godot; -public partial class Effect1 : GpuParticles2D +public partial class Effect1 : AutoDestroyEffect { - public override async void _Ready() + public override void _Ready() { var c = GetNode("GPUParticles2D"); c.Amount = Utils.RandomRangeInt(2, 6); c.Emitting = true; - Emitting = true; - var sceneTreeTimer = GetTree().CreateTimer(1f); - await ToSignal(sceneTreeTimer, Timer.SignalName.Timeout); - QueueFree(); + base._Ready(); } } diff --git a/DungeonShooting_Godot/src/game/effects/EnemyDebris.cs b/DungeonShooting_Godot/src/game/effects/EnemyDebris.cs new file mode 100644 index 0000000..0017f0f --- /dev/null +++ b/DungeonShooting_Godot/src/game/effects/EnemyDebris.cs @@ -0,0 +1,37 @@ + +using System.Collections; +using Godot; + +[RegisterActivity(ActivityIdPrefix.Effect + "0001", ResourcePath.prefab_effect_activityObject_EnemyDebris_tscn)] +public partial class EnemyDebris : ActivityObject +{ + + private GpuParticles2D _gpuParticles2D; + + public override void OnInit() + { + var frameCount = AnimatedSprite.SpriteFrames.GetFrameCount(AnimatorNames.Default); + AnimatedSprite.Frame = Utils.RandomRangeInt(0, frameCount - 1); + + Throw( + Utils.RandomRangeInt(0, 16), + Utils.RandomRangeInt(10, 60), + new Vector2(Utils.RandomRangeInt(-25, 25), Utils.RandomRangeInt(-25, 25)), + Utils.RandomRangeInt(-360, 360) + ); + + StartCoroutine(EmitParticles()); + } + + public IEnumerator EmitParticles() + { + var gpuParticles2D = GetNode("GPUParticles2D"); + gpuParticles2D.Emitting = true; + yield return new WaitForSeconds(Utils.RandomRangeFloat(1f, 2.5f)); + gpuParticles2D.Emitting = false; + yield return new WaitForSeconds(1); + gpuParticles2D.QueueFree(); + EnableBehavior = false; + Collision.QueueFree(); + } +} \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/item/weapon/shell/ShellCase.cs b/DungeonShooting_Godot/src/game/item/weapon/shell/ShellCase.cs index 24c56b8..1966222 100644 --- a/DungeonShooting_Godot/src/game/item/weapon/shell/ShellCase.cs +++ b/DungeonShooting_Godot/src/game/item/weapon/shell/ShellCase.cs @@ -7,30 +7,16 @@ [RegisterActivity(ActivityIdPrefix.Shell + "0001", ResourcePath.prefab_weapon_shell_ShellCase_tscn)] public partial class ShellCase : ActivityObject { - /// - /// 动画播放器 - /// - public AnimationPlayer AnimationPlayer { get; private set; } - public override void OnInit() { base.OnInit(); - AnimationPlayer = GetNode("AnimationPlayer"); ShadowOffset = new Vector2(0, 1); ThrowCollisionSize = new Vector2(5, 5); } protected override void OnThrowOver() { - //AwaitDestroy(); - MoveController.SetAllForce(Vector2.Zero); - AnimationPlayer.Play("flicker"); - } - - private async void AwaitDestroy() - { - //2秒后销毁 - await ToSignal(GetTree().CreateTimer(2), "timeout"); - Destroy(); + EnableBehavior = false; + Collision.QueueFree(); } } \ No newline at end of file diff --git a/DungeonShooting_Godot/src/game/manager/ActivityIdPrefix.cs b/DungeonShooting_Godot/src/game/manager/ActivityIdPrefix.cs index 677fd4c..c2edfc4 100644 --- a/DungeonShooting_Godot/src/game/manager/ActivityIdPrefix.cs +++ b/DungeonShooting_Godot/src/game/manager/ActivityIdPrefix.cs @@ -37,6 +37,10 @@ /// Shell, /// + /// 特效 + /// + Effect, + /// /// 其它类型 /// Other, @@ -66,7 +70,10 @@ /// 弹壳 /// public const string Shell = "shell"; - + /// + /// 特效 + /// + public const string Effect = "effect"; /// /// 其他类型 /// @@ -94,6 +101,8 @@ return Bullet; case ActivityPrefixType.Shell: return Shell; + case ActivityPrefixType.Effect: + return Effect; case ActivityPrefixType.Other: return Other; } diff --git a/DungeonShooting_Godot/src/game/manager/ResourceManager.cs b/DungeonShooting_Godot/src/game/manager/ResourceManager.cs index e5798a8..41dfc21 100644 --- a/DungeonShooting_Godot/src/game/manager/ResourceManager.cs +++ b/DungeonShooting_Godot/src/game/manager/ResourceManager.cs @@ -15,7 +15,7 @@ { if (_shadowMaterial == null) { - _shadowMaterial = ResourceLoader.Load(ResourcePath.resource_materlal_Blend_tres); + _shadowMaterial = ResourceLoader.Load(ResourcePath.resource_material_Blend_tres); } return _shadowMaterial; @@ -33,7 +33,7 @@ { if (_shadowShader == null) { - _shadowShader = ResourceLoader.Load(ResourcePath.resource_materlal_Blend_gdshader); + _shadowShader = ResourceLoader.Load(ResourcePath.resource_material_Blend_tres); } return _shadowShader; diff --git a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs index aa05b8b..299b36b 100644 --- a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs +++ b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs @@ -11,6 +11,8 @@ public const string prefab_effect_Effect1_tscn = "res://prefab/effect/Effect1.tscn"; public const string prefab_effect_FirePart_tscn = "res://prefab/effect/FirePart.tscn"; public const string prefab_effect_ShotFire_tscn = "res://prefab/effect/ShotFire.tscn"; + public const string prefab_effect_activityObject_EnemyBloodEffect_tscn = "res://prefab/effect/activityObject/EnemyBloodEffect.tscn"; + public const string prefab_effect_activityObject_EnemyDebris_tscn = "res://prefab/effect/activityObject/EnemyDebris.tscn"; public const string prefab_map_RoomDoor_tscn = "res://prefab/map/RoomDoor.tscn"; public const string prefab_role_Enemy_tscn = "res://prefab/role/Enemy.tscn"; public const string prefab_role_Player_tscn = "res://prefab/role/Player.tscn"; @@ -33,31 +35,22 @@ public const string resource_effects_KnifeHit1_tres = "res://resource/effects/KnifeHit1.tres"; public const string resource_effects_ShotFire_png = "res://resource/effects/ShotFire.png"; public const string resource_effects_Smoke_png = "res://resource/effects/Smoke.png"; + public const string resource_effects_activityObject_Enemy0001_Debris_png = "res://resource/effects/activityObject/Enemy0001_Debris.png"; public const string resource_font_cn_font_12_tres = "res://resource/font/cn_font_12.tres"; public const string resource_font_cn_font_18_tres = "res://resource/font/cn_font_18.tres"; public const string resource_font_cn_font_36_tres = "res://resource/font/cn_font_36.tres"; public const string resource_map_RoomConfig_json = "res://resource/map/RoomConfig.json"; - public const string resource_map_tiledata_testGroup_battle_Room1_json = "res://resource/map/tiledata/testGroup/battle/Room1.json"; - public const string resource_map_tiledata_testGroup_battle_Room2_json = "res://resource/map/tiledata/testGroup/battle/Room2.json"; - public const string resource_map_tiledata_testGroup_battle_Room3_json = "res://resource/map/tiledata/testGroup/battle/Room3.json"; - public const string resource_map_tiledata_testGroup_battle_Room4_json = "res://resource/map/tiledata/testGroup/battle/Room4.json"; - public const string resource_map_tiledata_testGroup_battle_Room5_json = "res://resource/map/tiledata/testGroup/battle/Room5.json"; - public const string resource_map_tiledata_testGroup_battle_Room6_json = "res://resource/map/tiledata/testGroup/battle/Room6.json"; - public const string resource_map_tiledata_testGroup_battle_Room7_json = "res://resource/map/tiledata/testGroup/battle/Room7.json"; + public const string resource_map_tiledata_testGroup_battle_Room8_json = "res://resource/map/tiledata/testGroup/battle/Room8.json"; public const string resource_map_tiledata_testGroup_inlet_Room1_json = "res://resource/map/tiledata/testGroup/inlet/Room1.json"; public const string resource_map_tiledata_testGroup_outlet_Room1_json = "res://resource/map/tiledata/testGroup/outlet/Room1.json"; - public const string resource_map_tileMaps_testGroup_battle_Room1_tscn = "res://resource/map/tileMaps/testGroup/battle/Room1.tscn"; - public const string resource_map_tileMaps_testGroup_battle_Room2_tscn = "res://resource/map/tileMaps/testGroup/battle/Room2.tscn"; - public const string resource_map_tileMaps_testGroup_battle_Room3_tscn = "res://resource/map/tileMaps/testGroup/battle/Room3.tscn"; - public const string resource_map_tileMaps_testGroup_battle_Room4_tscn = "res://resource/map/tileMaps/testGroup/battle/Room4.tscn"; - public const string resource_map_tileMaps_testGroup_battle_Room5_tscn = "res://resource/map/tileMaps/testGroup/battle/Room5.tscn"; - public const string resource_map_tileMaps_testGroup_battle_Room6_tscn = "res://resource/map/tileMaps/testGroup/battle/Room6.tscn"; - public const string resource_map_tileMaps_testGroup_battle_Room7_tscn = "res://resource/map/tileMaps/testGroup/battle/Room7.tscn"; + public const string resource_map_tileMaps_testGroup_battle_Room8_tscn = "res://resource/map/tileMaps/testGroup/battle/Room8.tscn"; public const string resource_map_tileMaps_testGroup_inlet_Room1_tscn = "res://resource/map/tileMaps/testGroup/inlet/Room1.tscn"; public const string resource_map_tileMaps_testGroup_outlet_Room1_tscn = "res://resource/map/tileMaps/testGroup/outlet/Room1.tscn"; public const string resource_map_tileset_TileSet1_tres = "res://resource/map/tileset/TileSet1.tres"; - public const string resource_materlal_Blend_gdshader = "res://resource/materlal/Blend.gdshader"; - public const string resource_materlal_Blend_tres = "res://resource/materlal/Blend.tres"; + public const string resource_map_tileset_TileSet_old_tres = "res://resource/map/tileset/TileSet_old.tres"; + public const string resource_material_Blend_gdshader = "res://resource/material/Blend.gdshader"; + public const string resource_material_Blend_tres = "res://resource/material/Blend.tres"; + public const string resource_material_SmokeParticleMaterial_tres = "res://resource/material/SmokeParticleMaterial.tres"; public const string resource_sound_bgm_Intro_ogg = "res://resource/sound/bgm/Intro.ogg"; public const string resource_sound_sfx_ordinaryBullet_ogg = "res://resource/sound/sfx/ordinaryBullet.ogg"; public const string resource_sound_sfx_ordinaryBullet2_mp3 = "res://resource/sound/sfx/ordinaryBullet2.mp3"; @@ -277,6 +270,7 @@ public const string scene_Main_tscn = "res://scene/Main.tscn"; public const string scene_Room_tscn = "res://scene/Room.tscn"; public const string scene_test_TestCommpont_tscn = "res://scene/test/TestCommpont.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_TestNavigation_tscn = "res://scene/test/TestNavigation.tscn"; public const string scene_test_TestNavigation2_tscn = "res://scene/test/TestNavigation2.tscn"; diff --git a/DungeonShooting_Godot/src/game/role/AnimatorNames.cs b/DungeonShooting_Godot/src/game/role/AnimatorNames.cs index 2084a1f..29e59cb 100644 --- a/DungeonShooting_Godot/src/game/role/AnimatorNames.cs +++ b/DungeonShooting_Godot/src/game/role/AnimatorNames.cs @@ -5,6 +5,10 @@ public static class AnimatorNames { /// + /// 默认动画 + /// + public const string Default = "default"; + /// /// 静止不动 /// public const string Idle = "idle"; diff --git a/DungeonShooting_Godot/src/game/role/Role.cs b/DungeonShooting_Godot/src/game/role/Role.cs index 1d4ba68..d6ab0a4 100644 --- a/DungeonShooting_Godot/src/game/role/Role.cs +++ b/DungeonShooting_Godot/src/game/role/Role.cs @@ -301,13 +301,13 @@ { if (index % 2 == 0) { - weapon.Position = new Vector2(-4, 5); + weapon.Position = new Vector2(-4, 3); weapon.RotationDegrees = 90 - (index / 2f) * 20; weapon.Scale = new Vector2(-1, 1); } else { - weapon.Position = new Vector2(4, 5); + weapon.Position = new Vector2(4, 3); weapon.RotationDegrees = 270 + (index - 1) / 2f * 20; weapon.Scale = new Vector2(1, 1); } diff --git a/DungeonShooting_Godot/src/game/role/enemy/Enemy.cs b/DungeonShooting_Godot/src/game/role/enemy/Enemy.cs index 92edf4e..57e8bd8 100644 --- a/DungeonShooting_Godot/src/game/role/enemy/Enemy.cs +++ b/DungeonShooting_Godot/src/game/role/enemy/Enemy.cs @@ -136,6 +136,22 @@ { weapons[i].ThrowWeapon(this); } + + var effPos = Position + new Vector2(0, -Altitude); + //血液特效 + var blood = ResourceManager.LoadAndInstantiate(ResourcePath.prefab_effect_activityObject_EnemyBloodEffect_tscn); + blood.Position = effPos - new Vector2(0, 12); + blood.AddToActivityRoot(RoomLayerEnum.NormalLayer); + + //创建敌人碎片 + var count = Utils.RandomRangeInt(3, 6); + for (var i = 0; i < count; i++) + { + var debris = Create(ActivityIdPrefix.Effect + "0001"); + debris.PutDown(effPos, RoomLayerEnum.NormalLayer); + debris.InheritVelocity(this); + } + //派发敌人死亡信号 EventManager.EmitEvent(EventEnum.OnEnemyDie, this); Destroy();