From baa4f2d7259d08cfcb936fe6b5aa28a7be3673af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=A8=E8=90=BD=E5=9F=BA=E5=9B=B4=E8=99=BE?= <3161880837@qq.com> Date: Sat, 8 Nov 2025 20:28:12 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E6=AD=A6=E5=99=A8):=20=E8=B0=83=E6=95=B4H?= =?UTF-8?q?JM=E6=AD=A6=E5=99=A8=E7=9A=84=E5=B1=9E=E6=80=A7=E5=92=8C?= =?UTF-8?q?=E5=8F=AC=E5=94=A4=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修改HJM武器的攻击计算方式,从乘法改为加法 优化召唤物的移动速度和追踪距离 调整武器的基础属性和UI显示 增加子弹生成逻辑和伤害设置 更新武器配置和描述文本 --- components/Weapons/HJM.tscn | 8 +++++--- scripts/Contents/Summons/HJM.gd | 9 +++++---- scripts/Contents/Weapons/HJM.gd | 4 ++-- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/components/Weapons/HJM.tscn b/components/Weapons/HJM.tscn index 97aadfb..129a289 100644 --- a/components/Weapons/HJM.tscn +++ b/components/Weapons/HJM.tscn @@ -9,9 +9,10 @@ script = ExtResource("2_2in6n") avatarTexture = ExtResource("2_74sfb") displayName = "耄耋" typeTopic = 2 +costBeachball = 600 store = { "atk": 10, -"time": 0.1 +"time": 0.2 } storeType = { "atk": 1, @@ -19,12 +20,13 @@ storeType = { } descriptionTemplate = "召唤[b]抓狂的哈基米[/b],跟踪敌人,每$time秒造成$atk点伤害。" cooldown = 1000.0 +debugRebuild = true [node name="avatar" parent="container/info" index="0"] texture = ExtResource("2_74sfb") [node name="beachball" parent="container/info/infos" index="1"] -count = 500 +count = 600 [node name="soul" parent="container/info/infos" index="2"] count = 1 @@ -34,4 +36,4 @@ displayName = "耄耋" typeTopic = 2 [node name="description" parent="container" index="2"] -text = "[center]召唤[b]抓狂的哈基米[/b],跟踪敌人,每[color=cyan]0.10[/color]秒造成[color=cyan]10[/color]点伤害。[/center]" +text = "[center]召唤[b]抓狂的哈基米[/b],跟踪敌人,每[color=cyan]0.20[/color]秒造成[color=cyan]10[/color]点伤害。[/center]" diff --git a/scripts/Contents/Summons/HJM.gd b/scripts/Contents/Summons/HJM.gd index a59214c..adcc2c5 100644 --- a/scripts/Contents/Summons/HJM.gd +++ b/scripts/Contents/Summons/HJM.gd @@ -5,7 +5,7 @@ var tracer: EntityBase = null func register(): fields[FieldStore.Entity.MAX_HEALTH] = 75 - fields[FieldStore.Entity.MOVEMENT_SPEED] = 2 + fields[FieldStore.Entity.MOVEMENT_SPEED] = 1.5 await TickTool.frame() attackCooldownMap[0] = attackTime func spawn(): @@ -13,14 +13,15 @@ func spawn(): func ai(): tryAttack(0) if is_instance_valid(tracer): - PresetEntityAI.follow(self, tracer, 50) + PresetEntityAI.follow(self, tracer, 80) else: tracer = EntityTool.findClosetEntity(position, get_tree(), !isPlayer(), isPlayer()) func attack(type): if type == 0: - BulletBase.generate( + for bullet in BulletBase.generate( ComponentManager.getBullet("HJMAttack"), self, findWeaponAnchor("normal"), 0 - ) + ): + bullet.damage = atk diff --git a/scripts/Contents/Weapons/HJM.gd b/scripts/Contents/Weapons/HJM.gd index 093ed4f..2df2b7e 100644 --- a/scripts/Contents/Weapons/HJM.gd +++ b/scripts/Contents/Weapons/HJM.gd @@ -3,10 +3,10 @@ extends Weapon func update(to: int, origin: Dictionary, _entity: EntityBase): origin["time"] /= 1 + 0.05 * to * soulLevel - origin["atk"] *= 2 * to * soulLevel + origin["atk"] += 2 * to * soulLevel return origin func attack(entity: EntityBase): - var summon = entity.summon(ComponentManager.getSummon("HJM"), true, false) + var summon = entity.summon(ComponentManager.getSummon("HJM")) summon.atk = readStore("atk") summon.attackTime = readStore("time") * 1000 return true