diff --git a/Assets/Scripts/Bots/CharacterFactory.cs b/Assets/Scripts/Bots/CharacterFactory.cs index 0ca7c1d..ba1f681 100644 --- a/Assets/Scripts/Bots/CharacterFactory.cs +++ b/Assets/Scripts/Bots/CharacterFactory.cs @@ -1,4 +1,6 @@ using System.Collections.Generic; +using Unity.Barracuda; +using Unity.MLAgents.Policies; using UnityEngine; public class CharacterFactory : MonoBehaviour @@ -70,7 +72,9 @@ public class CharacterFactory : MonoBehaviour } else { - gameobject.GetComponent().GetCharacter.Team = team; + var npc = gameobject.GetComponent(); + npc.GetCharacter.Team = team; + npc.SetModel(team.ToString(), ScriptableObject.CreateInstance(), InferenceDevice.Default ); gameobject.GetComponent().PointStartID = spawnPoint.PointId; bots.Add(gameobject); }