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

feat(战斗系统): 添加攻击速度属性支持

在Weapon.gd中根据实体攻击速度调整冷却时间
在CooldownTimer.gd中新增speedScale属性和centralTime方法
This commit is contained in:
2025-10-01 08:22:37 +08:00
parent 813ecfcf69
commit 76e87ac90e
2 changed files with 5 additions and 1 deletions
+1
View File
@@ -171,6 +171,7 @@ func playSound(sound: String):
await cloned.finished
cloned.queue_free()
func tryAttack(entity: EntityBase):
cooldownTimer.speedScale = entity.fields.get(FieldStore.Entity.ATTACK_SPEED)
if cooldownTimer.start():
if entity.useEnergy(needEnergy):
return await attack(entity)