void Start()
    {
        // Targetting laser will belong to a 'sibling' object
        // of the targetting laser, for the mech.

        targetter = transform.parent.GetComponentInChildren <PlayerTargetter>();

        if (targetter == null)
        {
            Debug.Log("Could not find a targetter for the reticule");
            Destroy(gameObject);
        }
    }
Ejemplo n.º 2
0
    void Start()
    {
        // Targetting laser will belong to a 'sibling' object
        // of the targetting laser, for the mech.

        targetter = transform.parent.GetComponentInChildren <PlayerTargetter>();

        if (targetter == null)   // TIDYME: 2018-07-07: Use assertion
        {
            Debug.Log("Could not find a targetter for the projectile shooter.");
            Destroy(gameObject);
        }
    }