Beispiel #1
0
    void CmdServerInit()
    {
        sv      = GameObject.FindGameObjectWithTag("Server").GetComponent <ServerMngr>();
        myConId = connectionToClient.connectionId;

        sv.register(myConId, this);
    }
Beispiel #2
0
 private void Awake()
 {
     if (!instance)
     {
         instance = this;
     }
     else
     {
         Destroy(gameObject);
     }
     DontDestroyOnLoad(gameObject);
 }