Exemplo n.º 1
0
    public void PreviousPower()
    {
        LinkPowerColors temp = GetComponent <LinkPowerColors>();

        if (powerIndex > 0)
        {
            powerIndex--;
        }
        else
        {
            powerIndex = temp.powers.Length - 1;
        }
        currentPower = temp.powers[powerIndex];
        main.color   = currentPower.main;
        gems.color   = currentPower.gems;
    }
Exemplo n.º 2
0
    //Power stuff
    public void NextPower()
    {
        LinkPowerColors temp = GetComponent <LinkPowerColors>();

        if (powerIndex < temp.powers.Length - 1)
        {
            powerIndex++;
        }
        else
        {
            powerIndex = 0;
        }
        currentPower = temp.powers[powerIndex];
        main.color   = currentPower.main;
        gems.color   = currentPower.gems;
    }