示例#1
0
    public void DestroyMatches()
    {
        for (int i = 0; i < width; i++)
        {
            for (int j = 0; j < height; j++)
            {
                if (allDots[i, j] != null)
                {
                    DestroyMatchesAt(i, j);
                }
            }
        }

        /*Debug.Log("special attack =" + specialMultiplier);
         * Debug.Log("shielding =" + shieldMultiplier);
         * Debug.Log("healing =" + healMultiplier);
         * Debug.Log("normal attack =" + attackMultiplier);*/
        if (specialMultiplier > 0)
        {
            if (specialMultiplier == 3)
            {
                healthbar.attackzz(8);
            }
            else if (specialMultiplier == 4)
            {
                healthbar.attackzz(9);
            }
            else
            {
                healthbar.attackzz(10);
            }
        }

        else if (healMultiplier > 0)
        {
            if (healMultiplier == 3)
            {
                healthbar.healzz(8);
            }
            else if (healMultiplier == 4)
            {
                healthbar.healzz(9);
            }
            else
            {
                healthbar.healzz(10);
            }
        }
        else if (coinmultiplayer > 0)
        {
            healthbar.UpdateCoin(coinmultiplayer);
        }
        specialMultiplier = 0;
        healMultiplier    = 0;
        coinmultiplayer   = 0;
        StartCoroutine(DecreaseRowCo());
    }