21 lines
531 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public abstract class TargetedProjectile : Projectile
{
private Vector2 _endPos;
private bool _isTracking;
protected override void Start()
{
base.Start();
_endPos = Target.Position;
_isTracking = true;
}
public Vector2 EndPos { get => _endPos; set => _endPos = value; }
public bool IsTracking { get => _isTracking; set => _isTracking = value; }
public Entity Target { get => Origin.Enemy; }
}