public void DisposeInterfaceRemovesEntities() { var hud = new HudInterface(); hud.Dispose(); Assert.IsFalse(hud.ScoreDisplay.IsActive); Assert.IsFalse(hud.GameOverText.IsActive); }
public void SetScore() { var hud = new HudInterface(); hud.SetScoreText(5); Assert.AreEqual("5", hud.ScoreDisplay.Text); }
public void SetIngameOrGameOver() { var hudIngame = new HudInterface(); hudIngame.SetInGameMode(); var hudGameOver = new HudInterface(); hudGameOver.SetGameOverText(); }
public void DisposeInterfaceRemovesEntities() { var hud = new HudInterface(); hud.Dispose(); Assert.IsFalse(hud.ScoreDisplay.IsActive); Assert.IsFalse(hud.GameOverText.IsActive); }
public void SetIngameOrGameOver() { var hudIngame = new HudInterface(); hudIngame.SetInGameMode(); var hudGameOver = new HudInterface(); hudGameOver.SetGameOverText(); }
public void Awake() { _eventSystem = GetComponentInChildren <EventSystem>(); _hud = Instantiate(_interfaceData.HudPrefab, parent: transform); _hud.gameObject.SetActive(false); _gameOver = Instantiate(_interfaceData.GameOverPrefab, parent: transform); _gameOver.gameObject.SetActive(false); }
private void InitializeHudInterface(HudConfig hudConfig) { HudConstants hudConstants = new HudConstants(droneControl.FrontCameraFieldOfViewDegrees); hudInterface = new HudInterface(hudConfig, hudConstants); }
public void SetScore() { var hud = new HudInterface(); hud.SetScoreText(5); Assert.AreEqual("5", hud.ScoreDisplay.Text); }