mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-28 23:11:54 +08:00
f2094a538d
将初始波数从10改为1以降低游戏初始难度 减少猫角色的攻击冷却时间范围从3500-8000到2500-6000 添加背景图片资源文件
19 lines
583 B
GDScript
19 lines
583 B
GDScript
extends EntityBase
|
|
class_name Maodie
|
|
|
|
func register():
|
|
fields[FieldStore.Entity.MAX_HEALTH] = 75
|
|
fields[FieldStore.Entity.MOVEMENT_SPEED] = randf_range(0.5, 0.8)
|
|
attackCooldownMap[0] = randi_range(2500, 6000)
|
|
sprintMultiplier = randf_range(10, 35)
|
|
func ai():
|
|
PresetEntityAI.follow(self, currentFocusedBoss)
|
|
tryAttack(0, true)
|
|
func attack(type: int):
|
|
if type == 0:
|
|
BulletBase.generate(ComponentManager.getBullet("ChickSprint"), self, position, 0)
|
|
trySprint()
|
|
return true
|
|
func sprint():
|
|
move((currentFocusedBoss.position - position).normalized() * sprintMultiplier, true)
|