2025-09-07 22:11:29 +08:00
|
|
|
extends EntityBase
|
2025-09-08 22:14:05 +08:00
|
|
|
class_name KukeMC
|
2025-09-08 22:35:24 +08:00
|
|
|
func register():
|
2025-09-14 14:10:07 +08:00
|
|
|
fields[FieldStore.Entity.MAX_HEALTH] = 2500
|
|
|
|
|
fields[FieldStore.Entity.OFFSET_SHOOT] = 15
|
|
|
|
|
fields[FieldStore.Entity.MOVEMENT_SPEED] = 0.5
|
|
|
|
|
attackCooldownMap[0] = 2000
|
2025-09-08 22:14:05 +08:00
|
|
|
func ai():
|
2025-09-14 14:10:07 +08:00
|
|
|
PresetEntityAI.follow(self, currentFocusedBoss, 500)
|
2025-09-08 22:35:24 +08:00
|
|
|
for bullet in get_tree().get_nodes_in_group("bullets"):
|
2025-09-08 22:14:05 +08:00
|
|
|
if (
|
|
|
|
|
bullet is LGBTBullet and
|
2025-09-14 13:57:53 +08:00
|
|
|
bullet.position.distance_to(self.position) < 200 # 酷可mc会去摧毁200半径以内的七彩飞星
|
2025-09-08 22:14:05 +08:00
|
|
|
):
|
|
|
|
|
bullet.tryDestroy()
|
2025-09-14 13:57:53 +08:00
|
|
|
tryAttack(0)
|
|
|
|
|
func attack(type):
|
|
|
|
|
if type == 0:
|
2025-09-14 14:10:07 +08:00
|
|
|
for i in randi_range(8, 16):
|
2025-09-14 13:57:53 +08:00
|
|
|
BulletBase.generate(preload("res://components/Bullets/PurpleCrystal.tscn"), self, findWeaponAnchor("normal"), position.angle_to_point(currentFocusedBoss.position))
|
2025-09-14 14:10:07 +08:00
|
|
|
await TickTool.millseconds(randi_range(10, 50))
|