Exemple #1
0
 public override void OnPlayerLeftRoom(Player otherPlayer)
 {
     if (PhotonNetwork.IsMasterClient)
     {
         SetupGameRef.PlayerLeftRoom(otherPlayer);
         SetupGameRef.RefreshUIWrite();
     }
 }
Exemple #2
0
    public void NextColor()
    {
        if (OnlineNumber != PhotonNetwork.LocalPlayer.ActorNumber)
        {
            return;
        }

        MyColor++;
        if (MyColor == SetupGameRef.ColorOptions.Count)
        {
            MyColor = 0;
        }

        //Hashtable hash = PhotonNetwork.CurrentRoom.CustomProperties;
        //hash["Player_" + PlayerNumber + "_Color"] = MyColor;
        //PhotonNetwork.CurrentRoom.SetCustomProperties(hash);
        SetupGameRef.RefreshUIWrite();

        MyColorDisplay.color = GetColor();
    }