Пример #1
0
    public void ZerarBarcos()
    {
        Nv01Barco01A.SetActive(false);
        Nv01Barco01B.SetActive(false);
        Nv01Barco02A.SetActive(false);
        Nv01Barco02B.SetActive(false);
        Nv01Barco03A.SetActive(false);
        Nv01Barco03B.SetActive(false);
        Nv01Barco04A.SetActive(false);
        Nv01Barco04B.SetActive(false);

        Nv02Barco01A.SetActive(false);
        Nv02Barco01B.SetActive(false);
        Nv02Barco02A.SetActive(false);
        Nv02Barco02B.SetActive(false);
        Nv02Barco03A.SetActive(false);
        Nv02Barco03B.SetActive(false);
        Nv02Barco04A.SetActive(false);
        Nv02Barco04B.SetActive(false);

        Nv03Barco01A.SetActive(false);
        Nv03Barco01B.SetActive(false);
        Nv03Barco02A.SetActive(false);
        Nv03Barco02B.SetActive(false);
        Nv03Barco03A.SetActive(false);
        Nv03Barco03B.SetActive(false);
        Nv03Barco04A.SetActive(false);
        Nv03Barco04B.SetActive(false);

        Nv04Barco01A.SetActive(false);
        Nv04Barco01B.SetActive(false);

        Nv05Barco01A.SetActive(false);
        Nv05Barco01B.SetActive(false);
    }
Пример #2
0
    public void DesativarRadarBarcos()
    {
        //Nivel01
        if (posicao == 1)
        {
            Nv01Barco01A.SetActive(true);
            Nv01Barco01B.SetActive(false);
        }
        if (posicao == 2)
        {
            Nv01Barco01A.SetActive(false);
            Nv01Barco01B.SetActive(false);

            Nv01Barco02A.SetActive(true);
            Nv01Barco02B.SetActive(false);
        }
        if (posicao == 3)
        {
            Nv01Barco02A.SetActive(false);
            Nv01Barco02B.SetActive(false);

            Nv01Barco03A.SetActive(true);
            Nv01Barco03B.SetActive(false);
        }
        if (posicao == 4)
        {
            Nv01Barco03A.SetActive(false);
            Nv01Barco03B.SetActive(false);

            Nv01Barco04A.SetActive(true);
            Nv01Barco04B.SetActive(false);
        }

        //Nivel02
        if (posicao == 5)
        {
            Nv01Barco04A.SetActive(false);
            Nv01Barco04B.SetActive(false);

            Nv02Barco01A.SetActive(true);
            Nv02Barco01B.SetActive(false);
        }
        if (posicao == 6)
        {
            Nv02Barco01A.SetActive(false);
            Nv02Barco01B.SetActive(false);

            Nv02Barco02A.SetActive(true);
            Nv02Barco02B.SetActive(false);
        }
        if (posicao == 7)
        {
            Nv02Barco02A.SetActive(false);
            Nv02Barco02B.SetActive(false);

            Nv02Barco03A.SetActive(true);
            Nv02Barco03B.SetActive(false);
        }
        if (posicao == 8)
        {
            Nv02Barco03A.SetActive(false);
            Nv02Barco03B.SetActive(false);

            Nv02Barco04A.SetActive(true);
            Nv02Barco04B.SetActive(false);
        }

        //Nivel03
        if (posicao == 9)
        {
            Nv02Barco04A.SetActive(false);
            Nv02Barco04B.SetActive(false);

            Nv03Barco01A.SetActive(true);
            Nv03Barco01B.SetActive(false);
        }
        if (posicao == 10)
        {
            Nv03Barco01A.SetActive(false);
            Nv03Barco01B.SetActive(false);

            Nv03Barco02A.SetActive(true);
            Nv03Barco02B.SetActive(false);
        }
        if (posicao == 11)
        {
            Nv03Barco02A.SetActive(false);
            Nv03Barco02B.SetActive(false);

            Nv03Barco03A.SetActive(true);
            Nv03Barco03B.SetActive(false);
        }
        if (posicao == 12)
        {
            Nv03Barco03A.SetActive(false);
            Nv03Barco03B.SetActive(false);

            Nv03Barco04A.SetActive(true);
            Nv03Barco04B.SetActive(false);
        }

        //Nivel04
        if (posicao > 12 && posicao <= 16)
        {
            Nv04Barco01A.SetActive(true);
            Nv04Barco01B.SetActive(false);
        }

        //Nivel05
        if (posicao > 16)
        {
            Nv05Barco01A.SetActive(true);
            Nv05Barco01B.SetActive(false);
        }
    }