Exemplo n.º 1
0
    protected void Awake()
    {
        controller = this.GetComponent<CharacterController2D>();
        myPhotonView = this.GetComponent<PhotonView>();
        myHealth = this.GetComponent<Health>();

        moveState = moveStates.secondJump;
        fxManager = GameObject.FindObjectOfType<FXManager>();

        if(fxManager)
        {
            fxManagerPhotonView = fxManager.GetComponent<PhotonView>();
        }

        netMan = GameObject.FindObjectOfType<MovementTestingNetMan>();
        netManPhotonView = netMan.GetComponent<PhotonView>();
    }
Exemplo n.º 2
0
    void Awake()
    {
        characterScript = this.GetComponent<Character>();
        myPV = this.GetComponent<PhotonView>();
        netMan = FindObjectOfType<MovementTestingNetMan>();
        netManPV = netMan.GetComponent<PhotonView>();

        healthPerFive = characterScript.healthPerFive;
        maxHealth = characterScript.maxHealth;
        currentHealth = maxHealth;

        physicalDefense = characterScript.physicalDefense;
        magicalDefense = characterScript.magicalDefense;
    }