Ejemplo n.º 1
0
    void ReceiveSharedOrder(int type, bool isSimon, string text, string[] players, int color, int direction, string word)
    {
        if ((int)PhotonNetwork.LocalPlayer.CustomProperties["Lifes"] > 0)
        {
            orderText.text = text;
        }
        List <string> orderPlayers = new List <string>(players);
        float         waitTime;

        if (type == 0)
        {
            waitTime = markerTime;
        }
        else
        {
            waitTime = voiceTime;
        }

        //Set time bar
        StartCoroutine(StartOrderCountdown(waitTime));

        if (type == 0)
        {
            markersController.MovementOrder(color, isSimon, orderPlayers, direction, waitTime);
        }
        else
        {
            voiceController.CheckVoice(word, isSimon, orderPlayers, waitTime);
        }
    }
Ejemplo n.º 2
0
    string GenerateMarkerOrder(string preOrder)
    {
        int colorDifficulty = difficulty;
        int direction       = Random.Range(0, directions.Count);
        int color           = Random.Range(0, colorDifficulty + 1);

        if (difficulty == 3)
        {
            colorDifficulty++;
        }
        preOrder += " dice mueve la esfera de color " + colors[color] + " hacia " + directions[direction];



        markersController.MovementOrder(color, true, new List <string>(), direction, orderTime);

        return(preOrder);
    }