迁移敌人模型到新素材上并加入动画
This commit is contained in:
@@ -24,7 +24,7 @@ namespace SepCore.Entity
|
||||
|
||||
if (_target == null)
|
||||
{
|
||||
Movement.SetMove(false);
|
||||
_movementComponent.SetMove(false);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ namespace SepCore.Entity
|
||||
float distanceSquared = toTarget.sqrMagnitude;
|
||||
if (distanceSquared <= _attackRangeSquared)
|
||||
{
|
||||
Movement.SetMove(false);
|
||||
_movementComponent.SetMove(false);
|
||||
if (_canAttack)
|
||||
{
|
||||
TryFireProjectile();
|
||||
@@ -42,8 +42,8 @@ namespace SepCore.Entity
|
||||
}
|
||||
else
|
||||
{
|
||||
Movement.SetMove(true);
|
||||
Movement.SetDirection(GetTargetDirection());
|
||||
_movementComponent.SetMove(true);
|
||||
_movementComponent.SetDirection(GetTargetDirection());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user