1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-28 06:51:54 +08:00

fix(武器): 调整武器参数和修复弹反逻辑

- 修改Tree武器的攻击速率从0.25提升到1.0
- 移除Tree和PurpleCrystal的debugRebuild标志
- 修正Parrier弹反时的冲量计算公式
- 更新弹反子弹的目标定位为追踪锚点
- 完善PurpleCrystal场景结构和属性配置
This commit is contained in:
2026-04-29 22:09:59 +08:00
parent e2da3ec86e
commit 33192fbf8d
3 changed files with 16 additions and 12 deletions
+13 -8
View File
@@ -1,31 +1,36 @@
[gd_scene load_steps=5 format=3 uid="uid://c0n3igy4hucrg"]
[gd_scene format=3 uid="uid://c0n3igy4hucrg"]
[ext_resource type="PackedScene" uid="uid://ckq2cq6m23hq3" path="res://components/Abstracts/WeaponCardBase.tscn" id="1_hyubh"]
[ext_resource type="Script" uid="uid://cfgdvytfnwe8l" path="res://scripts/Contents/Weapons/PurpleCrystal.gd" id="2_0xgcv"]
[ext_resource type="Texture2D" uid="uid://16yhngg3jpun" path="res://resources/weapons/purple-crystal.svg" id="2_wgtcw"]
[ext_resource type="AudioStream" uid="uid://dclinyhu256xi" path="res://resources/sounds/effect/Low Whoosh.mp3" id="4_16daa"]
[node name="PurpleCrystal" instance=ExtResource("1_hyubh")]
[node name="PurpleCrystal" unique_id=1991730660 instance=ExtResource("1_hyubh")]
offset_bottom = 302.0
script = ExtResource("2_0xgcv")
avatarTexture = ExtResource("2_wgtcw")
displayName = "紫水晶簇"
costBeachball = 200
store = {
"atk": 0
}
descriptionTemplate = "发射[b]紫水晶[/b],撞击时造成$atk点伤害。"
cooldown = 200.0
debugRebuild = true
[node name="attack" parent="sounds" index="0"]
[node name="attack" parent="sounds" parent_id_path=PackedInt32Array(1775425991) index="0" unique_id=853583292]
stream = ExtResource("4_16daa")
[node name="avatar" parent="container/info" index="0"]
[node name="avatar" parent="container/info" parent_id_path=PackedInt32Array(1625294072) index="0" unique_id=1021985889]
texture = ExtResource("2_wgtcw")
[node name="beachball" parent="container/info/infos" index="1"]
[node name="beachball" parent="container/info/infos" parent_id_path=PackedInt32Array(492799150) index="1" unique_id=653442983]
count = 200
[node name="name" parent="container/info/displays" index="0"]
[node name="name" parent="container/info/displays" parent_id_path=PackedInt32Array(784441328) index="0" unique_id=1576068972]
displayName = "紫水晶簇"
[node name="description" parent="container" index="2"]
[node name="description" parent="container" parent_id_path=PackedInt32Array(575698869) index="2" unique_id=566230682]
text = "[center]发射[b]紫水晶[/b],撞击时造成[color=cyan]10[/color]点伤害。[/center]"
[node name="tease" parent="container" parent_id_path=PackedInt32Array(575698869) index="3" unique_id=689277044]
visible = false
+1 -2
View File
@@ -16,7 +16,7 @@ store = {
"atk": 10,
"count": 1.0,
"max": 3.0,
"rate": 0.25
"rate": 1.0
}
storeType = {
"atk": 1,
@@ -44,7 +44,6 @@ descriptionTemplate = "进行[b]格挡[/b],化解飞来的子弹。
sources = Array[String](["Nine Sols", "Terraria"])
tease = "卸劲反伤"
cooldown = 250.0
debugRebuild = true
[node name="avatar" parent="container/info" parent_id_path=PackedInt32Array(1625294072) index="0" unique_id=1021985889]
texture = ExtResource("3_nwamk")
+2 -2
View File
@@ -38,11 +38,11 @@ func hitBullet(bullet: BulletBase): # 当前子弹与其他子弹相撞
eff.modulate = bullet.modulate.blend(bullet.texture.modulate)
eff.rotation = position.angle_to_point(bullet.position)
eff.shot()
launcher.impluse((position - bullet.position).normalized() * (bullet.speed * bullet.getDamage()) ** (1.0 / 3) * 250)
launcher.impluse((position - bullet.position).normalized() * bullet.speed ** (1.0 / 2) * 250)
var targetBaseDamage = bullet.baseDamage
# 弹反 还是 格挡?
if MathTool.rate(reflectRate):
bullet.look_at(bullet.launcher.position)
bullet.look_at(bullet.launcher.getTrackingAnchor())
bullet.launcher = launcher
bullet.baseDamage *= atk
bullet.baseDamage *= reflectRate