Implemented Academy / Set GoalPoint / Bug: Training does not move agents
This commit is contained in:
@@ -5,5 +5,21 @@ using UnityEngine;
|
||||
|
||||
public class CozmoAcademy : Academy
|
||||
{
|
||||
|
||||
public GameObject cozmo;
|
||||
public Transform startPoint;
|
||||
//public bool testAcademyReset = false;
|
||||
|
||||
public override void AcademyReset()
|
||||
{
|
||||
cozmo.transform.position = startPoint.position;
|
||||
}
|
||||
|
||||
//private void Update()
|
||||
//{
|
||||
// if (testAcademyReset)
|
||||
// {
|
||||
// AcademyReset();
|
||||
// testAcademyReset = !testAcademyReset;
|
||||
// }
|
||||
//}
|
||||
}
|
||||
|
||||
@@ -112,6 +112,15 @@ public class CozmoAgent : Agent
|
||||
}
|
||||
|
||||
|
||||
private void OnTriggerEnter(Collider other)
|
||||
{
|
||||
if (other.transform.CompareTag("Goal"))
|
||||
{
|
||||
print("Collission");
|
||||
Done();
|
||||
}
|
||||
}
|
||||
|
||||
private void WaitTimeInference()
|
||||
{
|
||||
if (renderCamera != null)
|
||||
|
||||
Reference in New Issue
Block a user