Ejemplo n.º 1
0
 public void LoadStageSelect()
 {
     if (gameManager != null || NGameManager.TryGetInstance(out gameManager))
     {
         gameManager.LoadRandomLevel();
     }
 }
Ejemplo n.º 2
0
 public void SetPlayerCharacterChoices(int[] c)
 {
     if (gameManager != null || NGameManager.TryGetInstance(out gameManager))
     {
         gameManager.SetPlayerCharacterChoices(c);
     }
 }
Ejemplo n.º 3
0
 public void SetRounds(int r)
 {
     if (gameManager != null || NGameManager.TryGetInstance(out gameManager))
     {
         gameManager.SetRounds(r);
     }
 }
Ejemplo n.º 4
0
    private IEnumerator EndSequence()
    {
        yield return(new WaitForSeconds(2.5f));

        if (gameManager != null || NGameManager.TryGetInstance(out gameManager))
        {
            gameManager.LoadRandomLevel();
        }
    }
Ejemplo n.º 5
0
 void Start()
 {
     eventSystem = EventSystem.current;
     fightButton.onClick.AddListener(ToCharacterSelect);
     characterSelectManager.SetActive(false);
     if (NGameManager.TryGetInstance(out gameManager))
     {
         gameManager.SetEventSystemSelected(fightButton.gameObject);
     }
 }
Ejemplo n.º 6
0
 void Start()
 {
     cam         = Camera.main;
     cameraQueue = new Queue <IEnumerator>();
     players     = new Dictionary <GameObject, NPlayerController>();
     for (int i = 0; i < 4; i++)
     {
         players.Add(playersObject.GetChild(i).gameObject, playersObject.GetChild(i).GetComponent <NPlayerController>());
     }
     spawnPoints = new LinkedList <Transform>();
     for (int i = 0; i < spawnPointsObject.childCount; i++)
     {
         spawnPoints.AddLast(spawnPointsObject.GetChild(i));
     }
     if (NGameManager.TryGetInstance(out gameManager))
     {
         gameData = gameManager.SetLevelManager(this);
     }
     Initialize();
     StartSequence();
 }