mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-28 23:11:54 +08:00
78734700d5
修改多个武器和召唤物的属性值,包括生命值、伤害计算和能量消耗 调整初始波次从0改为9,优化游戏初始难度 更新武器卡片的UI显示和描述文本
28 lines
660 B
GDScript
28 lines
660 B
GDScript
extends SummonBase
|
|
|
|
var attackTime: float = 0
|
|
var tracer: EntityBase = null
|
|
|
|
func register():
|
|
fields[FieldStore.Entity.MAX_HEALTH] = 150
|
|
fields[FieldStore.Entity.MOVEMENT_SPEED] = 1.5
|
|
await TickTool.frame()
|
|
attackCooldownMap[0] = attackTime
|
|
func spawn():
|
|
texture.play("walk")
|
|
func ai():
|
|
tryAttack(0)
|
|
if is_instance_valid(tracer):
|
|
PresetEntityAI.follow(self, tracer, 80)
|
|
else:
|
|
tracer = EntityTool.findClosetEntity(position, get_tree(), !isPlayer(), isPlayer())
|
|
func attack(type):
|
|
if type == 0:
|
|
for bullet in BulletBase.generate(
|
|
ComponentManager.getBullet("HJMAttack"),
|
|
self,
|
|
findWeaponAnchor("normal"),
|
|
0
|
|
):
|
|
bullet.damage = atk
|