Exemplo n.º 1
0
    // Use this for initialization
    void Start()
    {
        pokemonPlayer    = FindObjectOfType(typeof(pokemonPlayer)) as pokemonPlayer;
        battleController = FindObjectOfType(typeof(battleController)) as battleController;
        barraHP          = GameObject.Find("HP_Inimigo").transform;

        pv = pvMax;

        percentualVida     = pv / pvMax;
        vector3            = barraHP.localScale;
        vector3.x          = percentualVida;
        barraHP.localScale = vector3;
    }
Exemplo n.º 2
0
    // Use this for initialization
    void Start()
    {
        pokemonPlayer  = FindObjectOfType(typeof(pokemonPlayer)) as pokemonPlayer;
        pokemonInimigo = FindObjectOfType(typeof(pokemonInimigo)) as pokemonInimigo;

        Treinador = GameObject.Find("Treinador").transform;

        posA = GameObject.Find("PosA").transform;
        posB = GameObject.Find("PosB").transform;

        Pokemon = pokemonPlayer.transform;

        menuA.SetActive(false);
        menuB.SetActive(false);

        idFase = 0;
        fala   = "Um " + pokemonInimigo.nome + " apareceu!";
        StartCoroutine("dialogo", fala);
    }