mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-30 07:51:54 +08:00
feat(武器): 调整HJM武器的属性和召唤逻辑
修改HJM武器的攻击计算方式,从乘法改为加法 优化召唤物的移动速度和追踪距离 调整武器的基础属性和UI显示 增加子弹生成逻辑和伤害设置 更新武器配置和描述文本
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user