Exemple #1
0
 public Target(int identity, int id, Transform transformToAdd, ParagonAI.TargetScript script)
 {
     uniqueIdentifier = identity;
     teamID           = id;
     transform        = transformToAdd;
     targetScript     = script;
 }
Exemple #2
0
 //Add a TargetScript to the game
 //Without this, agents wouldn't be able to find a target
 public int AddTarget(int id, Transform transformToAdd, ParagonAI.TargetScript script)
 {
     currentID++;
     ParagonAI.Target agentToAdd = new ParagonAI.Target(currentID, id, transformToAdd, script);
     currentTargets.Add(agentToAdd);
     UpdateAllEnemiesEnemyLists();
     return(currentID);
 }
        void Awake()
        {
            targetScript = gameObject.GetComponent <ParagonAI.TargetScript>();

            //If no teams are provided, then look for agents that are on the same team as the target we are modifying.
            if (teamNumbersToLookFor.Length == 0)
            {
                teamNumbersToLookFor    = new int[1];
                teamNumbersToLookFor[0] = targetScript.myTeamID;
            }

            //Square the radius so that we don't have to use costly SqrRoot
            SetRadiusToIncrease(radiusToIncreasePriority);
        }
        void Awake()
        {
            targetScript = gameObject.GetComponent<ParagonAI.TargetScript>();

            //If no teams are provided, then look for agents that are on the same team as the target we are modifying.
            if(teamNumbersToLookFor.Length == 0)
                {
                    teamNumbersToLookFor = new int[1];
                    teamNumbersToLookFor[0] = targetScript.myTeamID;
                }

            //Square the radius so that we don't have to use costly SqrRoot
            SetRadiusToIncrease(radiusToIncreasePriority);
        }
 public Target(int identity, int id, Transform transformToAdd, ParagonAI.TargetScript script)
 {
     uniqueIdentifier = identity;
     teamID = id;
     transform = transformToAdd;
     targetScript = script;
 }
Exemple #6
0
 //Setters
 public void SetTargetObj(ParagonAI.TargetScript x)
 {
     myTargetScript = x;
 }
Exemple #7
0
 //Setters
 public void SetTargetObj(ParagonAI.TargetScript x)
 {
     myTargetScript = x;
 }