public void OnGameStateChanged(CurrentGameScreen screen) { List <GameObject> toHide = screen == CurrentGameScreen.Custle ? this.MapViewObjects : this.CastleViewObjects; List <GameObject> toShow = screen == CurrentGameScreen.Custle ? this.CastleViewObjects : this.MapViewObjects; this.HodeObjects(toHide); this.ShowObjects(toShow); }
public void SetState(CurrentGameScreen screen) { this.Screen = screen; this.UIManager.OnGameStateChanged(screen); Camera.main.transform.position = cachedCamPosition; Object.FindObjectOfType <CameraControllerScript>().DoMovement = screen == CurrentGameScreen.Map; }