29 lines
469 B
C#
29 lines
469 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
public class EndEnemy : Enemy
|
|
{
|
|
public bool isGetTarget;
|
|
|
|
|
|
public override void OnUpdate()
|
|
{
|
|
// if (!isGetTarget)
|
|
// {
|
|
// GetTarget();
|
|
// }
|
|
base.OnUpdate();
|
|
}
|
|
|
|
public void GetTarget()
|
|
{
|
|
if (target != null)
|
|
{
|
|
isGetTarget = true;
|
|
return;
|
|
}
|
|
target = GameManager.Ins.GetPlayerAi(transform);
|
|
}
|
|
}
|