poprawki materialy unity 6, pajaki, podmiana katalogu FSM w AIControlerze, zmiana w Spider 2.0 Behaviours , skopane zycie bylo, ladowalo pajaka z zyciem 2.
This commit is contained in:
@@ -7,6 +7,7 @@ namespace Invector.vCharacterController.AI
|
||||
public vControlAI ai;
|
||||
public Transform target;
|
||||
public vAIMovementSpeed speed= vAIMovementSpeed.Running;
|
||||
public bool testEnabled;
|
||||
public void MoveToTarget()
|
||||
{
|
||||
ai.MoveTo(target.position, speed);
|
||||
@@ -22,6 +23,19 @@ namespace Invector.vCharacterController.AI
|
||||
ai.LookToTarget(target, 2f, 0f);
|
||||
}
|
||||
|
||||
public void RotateToTarget()
|
||||
{
|
||||
var direction = target.position - transform.position;
|
||||
direction.y = 0;
|
||||
ai.RotateTo(direction.normalized);
|
||||
}
|
||||
public void Attack()
|
||||
{
|
||||
if (ai is vIControlAICombat)
|
||||
{
|
||||
(ai as vIControlAICombat).Attack(false, forceCanAttack: true);
|
||||
}
|
||||
}
|
||||
public void Attack(bool strong = false)
|
||||
{
|
||||
if(ai is vIControlAICombat)
|
||||
@@ -29,5 +43,9 @@ namespace Invector.vCharacterController.AI
|
||||
(ai as vIControlAICombat).Attack(strong,forceCanAttack: true);
|
||||
}
|
||||
}
|
||||
public void GoToTarget(Transform target)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user