1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-27 22:41:56 +08:00

feat(武器/特效): 新增扶桑元神武器及爆炸特效

添加扶桑元神武器相关资源及功能实现,包括:
- 新增武器图标、描述和属性配置
- 实现格挡子弹并生成乾坤剑的逻辑
- 添加符咒爆炸特效及相关动画资源
- 调整乾坤剑伤害值和生成位置
- 优化武器特效控制器支持纹理动画
This commit is contained in:
2026-03-21 13:51:17 +08:00
parent 97ac580347
commit 0395019d5f
36 changed files with 712 additions and 12 deletions
+15 -1
View File
@@ -1,9 +1,17 @@
[gd_scene load_steps=3 format=3 uid="uid://bcvuuy2m0pke0"]
[gd_scene load_steps=4 format=3 uid="uid://bcvuuy2m0pke0"]
[ext_resource type="Script" uid="uid://0iwnvhdh645p" path="res://scripts/Statemachine/EffectController.gd" id="1_pt2rk"]
[sub_resource type="ShaderMaterial" id="ShaderMaterial_7cv4k"]
[sub_resource type="SpriteFrames" id="SpriteFrames_44wuf"]
animations = [{
"frames": [],
"loop": true,
"name": &"spawn",
"speed": 5.0
}]
[node name="EffectBase" type="Node2D"]
z_index = 1
script = ExtResource("1_pt2rk")
@@ -29,3 +37,9 @@ color = Color(1, 1, 1, 0)
[node name="animator" type="AnimationPlayer" parent="stage"]
unique_name_in_owner = true
[node name="texture" type="AnimatedSprite2D" parent="stage"]
unique_name_in_owner = true
position = Vector2(50, 50)
sprite_frames = SubResource("SpriteFrames_44wuf")
animation = &"spawn"
+1 -1
View File
@@ -122,7 +122,7 @@ size = Vector2(146, 26)
[node name="QKSword" instance=ExtResource("1_1ke2b")]
script = ExtResource("2_x26jp")
speed = 20.0
baseDamage = 20.0
baseDamage = 25.0
penerate = 1.0
penerateDamageReduction = 0.2
lifeTime = 3000.0
+87
View File
@@ -0,0 +1,87 @@
[gd_scene load_steps=18 format=3 uid="uid://cgdnkey2fhla4"]
[ext_resource type="PackedScene" uid="uid://bcvuuy2m0pke0" path="res://components/Abstracts/EffectBase.tscn" id="1_vi6cv"]
[ext_resource type="Texture2D" uid="uid://cq80y83edetx3" path="res://resources/effects/fooExplosion/Lv1_FooExplosion00.png" id="2_1ukt2"]
[ext_resource type="AudioStream" uid="uid://dkm4rld5hsevd" path="res://resources/sounds/effect/baozha.mp3" id="2_8b1u1"]
[ext_resource type="Texture2D" uid="uid://cehkdqa85b0ad" path="res://resources/effects/fooExplosion/Lv1_FooExplosion01.png" id="3_8b1u1"]
[ext_resource type="Texture2D" uid="uid://d2pg5hqpe2cp2" path="res://resources/effects/fooExplosion/Lv1_FooExplosion02.png" id="4_5pi6y"]
[ext_resource type="Texture2D" uid="uid://bykjgvhsf2dsu" path="res://resources/effects/fooExplosion/Lv1_FooExplosion03.png" id="5_k87jx"]
[ext_resource type="Texture2D" uid="uid://d0uq64amohrs7" path="res://resources/effects/fooExplosion/Lv1_FooExplosion04.png" id="6_arn3m"]
[ext_resource type="Texture2D" uid="uid://b2ywi78d7lg21" path="res://resources/effects/fooExplosion/Lv1_FooExplosion05.png" id="7_7ocvl"]
[ext_resource type="Texture2D" uid="uid://bihj346dfshj3" path="res://resources/effects/fooExplosion/Lv1_FooExplosion06.png" id="8_qdlyj"]
[ext_resource type="Texture2D" uid="uid://c1b3gnamtn2rn" path="res://resources/effects/fooExplosion/Lv1_FooExplosion07.png" id="9_bcn35"]
[ext_resource type="Texture2D" uid="uid://bo7cih0s2hx3g" path="res://resources/effects/fooExplosion/Lv1_FooExplosion08.png" id="10_4wpfv"]
[ext_resource type="Texture2D" uid="uid://cgisg4urhvrah" path="res://resources/effects/fooExplosion/Lv1_FooExplosion09.png" id="11_pg82r"]
[ext_resource type="Texture2D" uid="uid://dm4ih65h45qi8" path="res://resources/effects/fooExplosion/Lv1_FooExplosion10.png" id="12_dhm5g"]
[ext_resource type="Texture2D" uid="uid://bpr2j2jed4yxm" path="res://resources/effects/fooExplosion/Lv1_FooExplosion11.png" id="13_41cg7"]
[sub_resource type="Animation" id="Animation_1ukt2"]
resource_name = "spawn"
length = 0.4
[sub_resource type="AnimationLibrary" id="AnimationLibrary_8b1u1"]
_data = {
&"spawn": SubResource("Animation_1ukt2")
}
[sub_resource type="SpriteFrames" id="SpriteFrames_kn8g0"]
animations = [{
"frames": [{
"duration": 1.0,
"texture": ExtResource("2_1ukt2")
}, {
"duration": 1.0,
"texture": ExtResource("3_8b1u1")
}, {
"duration": 1.0,
"texture": ExtResource("4_5pi6y")
}, {
"duration": 1.0,
"texture": ExtResource("5_k87jx")
}, {
"duration": 1.0,
"texture": ExtResource("6_arn3m")
}, {
"duration": 1.0,
"texture": ExtResource("7_7ocvl")
}, {
"duration": 1.0,
"texture": ExtResource("8_qdlyj")
}, {
"duration": 1.0,
"texture": ExtResource("9_bcn35")
}, {
"duration": 1.0,
"texture": ExtResource("10_4wpfv")
}, {
"duration": 1.0,
"texture": ExtResource("11_pg82r")
}, {
"duration": 1.0,
"texture": ExtResource("12_dhm5g")
}, {
"duration": 1.0,
"texture": ExtResource("13_41cg7")
}],
"loop": false,
"name": &"spawn",
"speed": 30.0
}]
[node name="Foo" instance=ExtResource("1_vi6cv")]
spawnSound = "spawn"
spawnTexture = "spawn"
[node name="spawn" parent="sounds" index="0"]
stream = ExtResource("2_8b1u1")
[node name="animator" parent="stage" index="0"]
libraries = {
&"": SubResource("AnimationLibrary_8b1u1")
}
[node name="texture" parent="stage" index="1"]
scale = Vector2(0.4, 0.4)
sprite_frames = SubResource("SpriteFrames_kn8g0")
frame = 11
frame_progress = 1.0
+43 -1
View File
@@ -1,9 +1,51 @@
[gd_scene load_steps=3 format=3 uid="uid://cx7nogfnv7s8t"]
[gd_scene load_steps=4 format=3 uid="uid://cx7nogfnv7s8t"]
[ext_resource type="PackedScene" uid="uid://ckq2cq6m23hq3" path="res://components/Abstracts/WeaponCardBase.tscn" id="1_0lbwr"]
[ext_resource type="Script" uid="uid://bqdyhwcd4jwmj" path="res://scripts/Contents/Weapons/Tree.gd" id="2_jsuc8"]
[ext_resource type="Texture2D" uid="uid://74n7umby4d4w" path="res://resources/weapons/ParryCounter.png" id="3_nwamk"]
[node name="Tree" instance=ExtResource("1_0lbwr")]
script = ExtResource("2_jsuc8")
avatarTexture = ExtResource("3_nwamk")
displayName = "扶桑元神"
quality = 4
costBeachball = 900
oneShoot = true
store = {
"atk": 10,
"count": 1.0,
"foo": 1.0
}
storeType = {
"atk": 1,
"count": 1,
"foo": 1
}
descriptionTemplate = "进行[b]格挡[/b],化解飞来的子弹。
每成功格挡一次,获得一点[b]气力[/b]。
每拥有一点气力,闪避穿过敌人时对其贴上$foo层[b]符咒[/b],一段时间后符咒自动引爆,
召唤[b]乾坤剑[/b]穿透敌人。
乾坤剑造成$atk点伤害,
每次格挡最多化解$count个子弹。"
cooldown = 0.0
debugRebuild = true
[node name="avatar" parent="container/info" index="0"]
texture = ExtResource("3_nwamk")
[node name="beachball" parent="container/info/infos" index="1"]
count = 900
[node name="name" parent="container/info" index="2"]
displayName = "扶桑元神"
quality = 4
[node name="description" parent="container" index="2"]
text = "[center]进行[b]格挡[/b],化解飞来的子弹。
每成功格挡一次,获得一点[b]气力[/b]。
每拥有一点气力,闪避穿过敌人时对其贴上[color=cyan]1[/color]层[b]符咒[/b],一段时间后符咒自动引爆,
召唤[b]乾坤剑[/b]穿透敌人。
乾坤剑造成[color=cyan]10[/color]点伤害,
每次格挡最多化解[color=cyan]1[/color]个子弹。[/center]"
Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://cq80y83edetx3"
path="res://.godot/imported/Lv1_FooExplosion00.png-0df356b41f41f6092a9bb1652b63c922.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion00.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion00.png-0df356b41f41f6092a9bb1652b63c922.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://cehkdqa85b0ad"
path="res://.godot/imported/Lv1_FooExplosion01.png-68bf3113277947648d8279d0bfdb097d.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion01.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion01.png-68bf3113277947648d8279d0bfdb097d.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://d2pg5hqpe2cp2"
path="res://.godot/imported/Lv1_FooExplosion02.png-aae254d5afcc3300fd26352bf0755644.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion02.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion02.png-aae254d5afcc3300fd26352bf0755644.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 107 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bykjgvhsf2dsu"
path="res://.godot/imported/Lv1_FooExplosion03.png-0e10aa6579aec41c19e6203d0f058645.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion03.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion03.png-0e10aa6579aec41c19e6203d0f058645.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 137 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://d0uq64amohrs7"
path="res://.godot/imported/Lv1_FooExplosion04.png-47f8417164422428df5573e03db52542.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion04.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion04.png-47f8417164422428df5573e03db52542.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://b2ywi78d7lg21"
path="res://.godot/imported/Lv1_FooExplosion05.png-e7053aa245973761ac554d6fd5e77058.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion05.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion05.png-e7053aa245973761ac554d6fd5e77058.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 99 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bihj346dfshj3"
path="res://.godot/imported/Lv1_FooExplosion06.png-554f03b8591fe4c6bb586c25c92dd99d.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion06.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion06.png-554f03b8591fe4c6bb586c25c92dd99d.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://c1b3gnamtn2rn"
path="res://.godot/imported/Lv1_FooExplosion07.png-6fa6f8e96ab1f80771386b46f8864404.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion07.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion07.png-6fa6f8e96ab1f80771386b46f8864404.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bo7cih0s2hx3g"
path="res://.godot/imported/Lv1_FooExplosion08.png-d7231d7b4edbdab9a16d8cad0a51476c.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion08.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion08.png-d7231d7b4edbdab9a16d8cad0a51476c.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://cgisg4urhvrah"
path="res://.godot/imported/Lv1_FooExplosion09.png-147b5348099f6b500e932b6503afafcf.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion09.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion09.png-147b5348099f6b500e932b6503afafcf.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://dm4ih65h45qi8"
path="res://.godot/imported/Lv1_FooExplosion10.png-0dd1b5feaa95ffcae5a37a258a7b3ee8.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion10.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion10.png-0dd1b5feaa95ffcae5a37a258a7b3ee8.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bpr2j2jed4yxm"
path="res://.godot/imported/Lv1_FooExplosion11.png-44353bf2f6dfa8ab9c991a076e881591.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/effects/fooExplosion/Lv1_FooExplosion11.png"
dest_files=["res://.godot/imported/Lv1_FooExplosion11.png-44353bf2f6dfa8ab9c991a076e881591.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
Binary file not shown.
+19
View File
@@ -0,0 +1,19 @@
[remap]
importer="mp3"
type="AudioStreamMP3"
uid="uid://dkm4rld5hsevd"
path="res://.godot/imported/baozha.mp3-eb2f30dce98ee91c482d7e0c754d12a4.mp3str"
[deps]
source_file="res://resources/sounds/effect/baozha.mp3"
dest_files=["res://.godot/imported/baozha.mp3-eb2f30dce98ee91c482d7e0c754d12a4.mp3str"]
[params]
loop=false
loop_offset=0
bpm=0
beat_count=0
bar_beats=4
Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

+40
View File
@@ -0,0 +1,40 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://74n7umby4d4w"
path="res://.godot/imported/ParryCounter.png-05b65344ef1eb04d0ffd824fc52e8ec1.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://resources/weapons/ParryCounter.png"
dest_files=["res://.godot/imported/ParryCounter.png-05b65344ef1eb04d0ffd824fc52e8ec1.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
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/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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
+5 -1
View File
@@ -3,9 +3,13 @@ class_name ParrierBullet
@export var parryRate: float = 1
var parryiedTimes: int = 0
var maxParryTimes: int = 1
func hitBullet(bullet: BulletBase): # 当前子弹与其他子弹相撞
if BulletTool.canDamage(bullet, launcher): # 其他子弹可以使当前子弹的发射者受伤吗?
if MathTool.rate(parryRate):
if parryiedTimes < maxParryTimes && MathTool.rate(parryRate): # 一个刀光最多格挡多少个敌方子弹?
parryiedTimes += 1
# 生成格挡特效
var eff = EffectController.create(ComponentManager.getEffect("Parry"), position + (bullet.position - position).normalized() * 150) # 从子弹位置,面向其他子弹的方向前进150
eff.modulate = bullet.modulate.blend(bullet.texture.modulate)
+1 -1
View File
@@ -20,6 +20,6 @@ func succeedToHit(_dmg: float, entity: EntityBase): # 当撞到敌人时
0
):
if bullet is QKSwordBullet:
bullet.position = entity.texture.global_position + MathTool.sampleInRing(50, 200)
bullet.position = entity.texture.global_position + MathTool.sampleInRing(200, 500)
bullet.tracer = entity
bullet.look_at(entity.getTrackingAnchor()) # 生成的乾坤剑面向敌人
+6 -2
View File
@@ -3,11 +3,15 @@ class_name QKSwordBullet
var tracer: EntityBase
var attackedTracer: bool = false
var spawnSpeed: float = 1
func register():
spawnSpeed = randf_range(0.25, 1.75)
animator.speed_scale = spawnSpeed
func ai():
if is_instance_valid(tracer) && !attackedTracer:
look_at(tracer.getTrackingAnchor())
if timeLived() > 1000:
if timeLived() > 1000 / spawnSpeed:
PresetBulletAI.forward(self , rotation) # 前进
hitbox.disabled = false
else:
@@ -16,6 +20,6 @@ func succeedToHit(_dmg: float, entity: EntityBase):
if entity == tracer:
attackedTracer = true # 只需要命中一次目标就不需要继续前进了
EffectController.create(
ComponentManager.getEffect("CatBoom"),
ComponentManager.getEffect("FooExplosion"),
entity.texture.global_position
).shot()
+15 -5
View File
@@ -4,10 +4,12 @@ class_name EffectController
@export var oneShot: bool = true
@export var spawnSound: String = ""
@export var spawnAnimation: String = ""
@export var spawnTexture: String = ""
@onready var particles: GPUParticles2D = $"%particles"
@onready var sounds: Node2D = $"%sounds"
@onready var animator: AnimationPlayer = $"%animator"
@onready var texture: AnimatedSprite2D = $"%texture"
func _ready():
register()
@@ -18,17 +20,25 @@ func _ready():
sound.play()
if spawnAnimation:
animator.play(spawnAnimation)
if spawnTexture:
texture.play(spawnTexture)
func shot():
var cloned = particles.duplicate() as GPUParticles2D
cloned.emitting = true
add_child(cloned)
var childParticle = particles.duplicate() as GPUParticles2D
childParticle.emitting = true
add_child(childParticle)
if oneShot:
await cloned.finished
cloned.queue_free()
await childParticle.finished
childParticle.queue_free()
if spawnSound:
var sound: AudioStreamPlayer2D = sounds.get_node(spawnSound)
if sound.playing:
await sound.finished
if spawnAnimation:
if animator.is_playing():
await animator.animation_finished
if spawnTexture:
if texture.is_playing():
await texture.animation_finished
queue_free()
func register():