Example #1
0
    void Start()
    {
        bic = GetComponent <ButtonInteractionController>();
        an  = GetComponent <Animator>();

        shooter = transform.GetChild(0).gameObject;
        beam    = transform.GetChild(1).gameObject;
        lr      = beam.GetComponent <LineRenderer>();
    }
    void Start()
    {
        an = GetComponent <Animator>();

        /* Get the ButtonIntercationController for each associated object */
        bics = new ButtonInteractionController[interactableObjects.Length];
        for (int i = 0; i < interactableObjects.Length; i++)
        {
            GameObject interactableObject   = interactableObjects[i];
            ButtonInteractionController bic = interactableObject.GetComponent <ButtonInteractionController>();
            if (!bic)
            {
                print("The object associated with this button doesn't have a ButtonInterectionController.");
            }
            else
            {
                bics[i] = bic;
            }
        }
    }
Example #3
0
 // Start is called before the first frame update
 void Start()
 {
     isRunning            = false;
     playButtonController = FindObjectOfType <ButtonInteractionController>();
     createPathFunction();
 }
Example #4
0
 void Start()
 {
     bic           = GetComponent <ButtonInteractionController>();
     currentTarget = maxPosition;
 }