void Awake()
 {
     if (Instance == null)
     {
         Instance = this;
     }
     else if (Instance != this)
     {
         Destroy(gameObject);
     }
     Time.timeScale       = 1;
     GameControl.isSingle = false;
 }
Exemplo n.º 2
0
 //public GameObject terminalObj;
 // Use this for initialization
 void Awake()
 {
     if (instance == null)
     {
         instance = this;
     }
     else if (instance != this)
     {
         Destroy(gameObject);
     }
     gameOver                 = false;
     frogStop                 = true;
     youDied                  = false;
     numberOfAlive            = 0;
     myStyle.normal.textColor = Color.white;
     myStyle.fontSize         = 60;
     myStyle.fontStyle        = FontStyle.Bold;
     myStyle.alignment        = TextAnchor.MiddleCenter;
     this.photonView.RPC("updatePlayerNumber", PhotonTargets.MasterClient);
 }