Exemplo n.º 1
0
 // Start is called before the first frame update
 void Start()
 {
     if (objectState == null)
     {
         objectState = new ObjectState(new List <object>()
         {
             isAlive, objectLoadSceneLock, new SortedDictionary <string, ReceiveBase>(messageHandler), new SortedList(prefixList), maxPlayers, messageIsSend, gameStarted, timer, id, new State(), timeIsPassed, timePassedTrying, bytesLen, spawnId, serverIp, isDisconnected, connectionThreadJoin
         });
     }
     else
     {
         objectState.AddVariables(new List <object>()
         {
             isAlive, objectLoadSceneLock, new SortedDictionary <string, ReceiveBase>(messageHandler), new SortedList(prefixList), maxPlayers, messageIsSend, gameStarted, timer, id, new State(), timeIsPassed, timePassedTrying, bytesLen, spawnId, serverIp, isDisconnected, connectionThreadJoin
         });
     }
 }
Exemplo n.º 2
0
 void Start()
 {
     if (state == null)
     {
         state = new ObjectState(new List <object>()
         {
             new Dictionary <string, ReceiveBase>(messageHandler), new Dictionary <string, ReceiveBase>(messageHandlerForBoth), reset, isAlive
         });
     }
     else
     {
         state.AddVariables(new List <object>()
         {
             new Dictionary <string, ReceiveBase>(messageHandler), new Dictionary <string, ReceiveBase>(messageHandlerForBoth), reset, isAlive
         });
     }
 }
Exemplo n.º 3
0
 void Start()
 {
     if (state == null)
     {
         state = new ObjectState(new List <object>()
         {
             playerPrefabRef, playerById, freePlayerManagers, playersID, playerCreated
         });
     }
     else
     {
         state.AddVariables(new List <object>()
         {
             playerPrefabRef, playerById, freePlayerManagers, playersID, playerCreated
         });
     }
 }
Exemplo n.º 4
0
 private void Start()
 {
     if (state == null)
     {
         state = new ObjectState(new List <object>()
         {
             actionToExecuteOnMainThread, executeCopiedOnMainThread
         });
     }
     else
     {
         state.AddVariables(new List <object>()
         {
             actionToExecuteOnMainThread, executeCopiedOnMainThread
         });
     }
 }
Exemplo n.º 5
0
 protected void Start()
 {
     //Debug.Log("Handler added");
     if (state == null)
     {
         state = new ObjectState(new List <object>()
         {
             new SortedList(), scriptEnabled, prefix, packageIndex
         });
     }
     else
     {
         state.AddVariables(new List <object>()
         {
             new SortedList(), scriptEnabled, prefix, packageIndex
         });
     }
 }
Exemplo n.º 6
0
        // Start is called before the first frame update

        protected void Start()
        {
            if (state == null)
            {
                state = new ObjectState(new List <object>()
                {
                    prefix, scriptEnabled
                });
            }
            else
            {
                state.AddVariables(new List <object>()
                {
                    prefix, scriptEnabled
                });
            }
            ThreadManager.AddAction(delegate { CustomUpdate(); });
        }