/// <summary> /// Updates instructions to collect X things. /// </summary> /// <param name="numToCollect">Number to collect.</param> /// <param name="stage">The object type to collect.</param> public void ShowCollectionText(int numToCollect, GameplayStage stage) { var str = LocalizationManager.Instance.GetString("Collection"); infoText.text = string.Format(str, numToCollect, GetStageString(stage)); infoText.CrossFadeAlpha(1, 0.25f, false); infoDisplayTime = 5f; }
/// <summary> /// Updates instructions to collect X things. /// </summary> /// <param name="numToCollect">Number to collect.</param> /// <param name="stage">The object type to collect.</param> public void ShowCollectionText(int numToCollect, GameplayStage stage) { var str = LocalizationManager.Instance.GetString("Collection"); infoText.text = string.Format(str, numToCollect, GetStageString(stage)); infoText.CrossFadeAlpha(1, 0.25f, false); infoDisplayTime = 5f; }
/// <summary> /// Updates the HUD. /// </summary> /// <param name="time">Time spent.</param> /// <param name="rank">Rank.</param> /// <param name="count">Count.</param> /// <param name="stage">Stage.</param> public void UpdateHUD(float time, PlayerRank rank, int count, GameplayStage stage) { ShowTimer(time); ShowRank(rank); ShowCount(count, stage); }
/// <summary> /// Gets a readable string for the object type. /// </summary> /// <returns>The stage string.</returns> /// <param name="val">Value.</param> string GetStageString(GameplayStage val) { return(LocalizationManager.Instance.GetString(val.ToString())); }
/// <summary> /// Updates the /// </summary> /// <param name="propsCollected">Properties collected.</param> /// <param name="stage">Stage.</param> void ShowCount(int propsCollected, GameplayStage stage) { var format = LocalizationManager.Instance.GetString("HUD Count"); countText.text = string.Format(format, GetStageString(stage), propsCollected.ToString()); }
/// <summary> /// Updates the /// </summary> /// <param name="propsCollected">Properties collected.</param> /// <param name="stage">Stage.</param> void ShowCount(int propsCollected, GameplayStage stage) { var format = LocalizationManager.Instance.GetString("HUD Count"); countText.text = string.Format(format, GetStageString(stage), propsCollected.ToString()); }
/// <summary> /// Gets a readable string for the object type. /// </summary> /// <returns>The stage string.</returns> /// <param name="val">Value.</param> string GetStageString(GameplayStage val) { return LocalizationManager.Instance.GetString(val.ToString()); }
/// <summary> /// Updates the HUD. /// </summary> /// <param name="time">Time spent.</param> /// <param name="rank">Rank.</param> /// <param name="count">Count.</param> /// <param name="stage">Stage.</param> public void UpdateHUD(float time, PlayerRank rank, int count, GameplayStage stage) { ShowTimer(time); ShowRank(rank); ShowCount(count, stage); }