1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-06-01 17:01:53 +08:00
Files
Dog-Lynx-And-HCN/scripts/Contents/Bullets/LGBTBullet.gd
T

18 lines
429 B
GDScript
Raw Normal View History

extends BulletBase
class_name LGBTBullet
var tracer: EntityBase = null
var maxTraceTime: float = 0
var tracePower: float
func register():
speed = 1
damage = 5
func ai():
texture.rotation_degrees += speed
speed *= 1.05
speed = clamp(speed, 0, 20)
if is_instance_valid(tracer) and timeLived() < maxTraceTime:
PresetAIs.trace(self, tracer.position, clamp(speed / 50 * tracePower, 0, 1))
PresetAIs.forward(self, rotation)