Ejemplo n.º 1
0
 // Use this for initialization
 void Start()
 {
     controller = GameObject.Find("controller").GetComponent <Create_Teams>();
     teamID     = transform.GetComponent <AILogic> ().teamID; // this soldiers team id
     myID       = transform.GetComponent <AILogic> ().myID;   // this soldiers id
     AssignRange();                                           // Randomly assign a range for this soldier
     hp     = 15;                                             // set the HP for this soldier
     damage = 2;                                              // the damage that this soldier does per frame
     target = null;                                           // the target that this soldier will damage
 }
Ejemplo n.º 2
0
 // Use this for initialization
 void Start()
 {
     velocity   = Vector3.zero;
     controller = GameObject.Find("controller").GetComponent <Create_Teams> ();
     // path controller
     pathController = GetComponent <Pathing> ();
     // sanity check if pathing does not exist.
     if (pathController == null)
     {
         pathWeight = 0;
     }
     rb = GetComponent <Rigidbody> ();
 }
Ejemplo n.º 3
0
    private float healthConfidence;//, VIPSafety;


    // Use this for initialization
    void Start()
    {
        logic       = transform.GetComponent <AILogic>();
        interaction = transform.GetComponent <Interaction>();
        controller  = GameObject.Find("controller").GetComponent <Create_Teams>();
    }
Ejemplo n.º 4
0
 // Use this for initialization
 void Start()
 {
     hp    = 30;                                                           // Hp of VIPs
     logic = transform.GetComponent <AILogic>();
     CT    = GameObject.Find("controller").GetComponent <Create_Teams> (); // the accessor for the list we need to remove VIPs from when they are destroyed
 }