Пример #1
0
        private static void OnModdedplayerjoinReceived(string sender, string data)
        {
            ModdedUser mu = JsonConvert.DeserializeObject <ModdedUser>(data);

            lock (moddedUserList)
            {
                if (!moddedUserList.ContainsKey(mu.id))
                {
                    moddedUserList.Add(mu.id, mu);
                }
            }
        }
Пример #2
0
        private static void OnModdedplayerjoinReceived(string sender, string data)
        {
            ModdedUser mu = JsonUtility.FromJson <ModdedUser>(data);

            lock (moddedUserList)
            {
                if (!moddedUserList.ContainsKey(mu.id))
                {
                    moddedUserList.Add(mu.id, mu);
                }
            }
        }
Пример #3
0
 private static void OnModdedplayerlistonjoinReceived(string sender, string data)
 {
     ModdedUser[] muld = ModdedUser.ParseJson(data);
     lock (moddedUserList)
     {
         foreach (ModdedUser mu in muld)
         {
             if (!moddedUserList.ContainsKey(mu.id))
             {
                 moddedUserList.Add(mu.id, mu);
             }
         }
     }
 }