Esempio n. 1
0
    // Use this for initialization
    void Start()
    {
        if (transform.parent.networkView.viewID.owner != Network.player) {
            isActive = false;
        }

        tPT = thirdPerson.GetComponent<thirdPersonTower> ();
        fPT = firstPerson.GetComponent<firstPersonTower> ();
        if (tPT != null && !isActive) {
            tPT.shutDownControl ();
        }
        if(fPT != null && !isActive)
        {
            fPT.cleanUpOnExit();
        }
        if (isActive) {
            tPT.shutDownControl ();
            fPT.makeActive ();
        }
    }