public void Setup(StageMaster master) { DispatchEvent <Action <UI.StageCanvas> >(StageEvents.RequestStageCanvas, c => _stageCanvas = c); DispatchEvent <Action <CharacterManager> >(StageEvents.RequestCharacterManager, c => _characterManager = c); _stageMaster = master; CreateGround(master.RoundSettings, () => CurrentGround.ActivationWalls(true)); StartStage(); }
private void StartRound() { _grounds.ForEach(c => c.CloseAllExit()); _grounds.ForEach(c => c.ActivationWalls(false)); CurrentGround.ActivationWalls(true); _characterManager.ClearEnemies(); if (Player == null) { _characterManager.CreateNewPlayer(_playerParent, OnCreatePlayer); } _bornEnemyLoopCoroutine = StartCoroutine(BornEnemyLoop()); Player.SetCanMove(true); _stageCanvas.RoundTimer.StartTimer(3, OnEndTimer); }