Exemplo n.º 1
0
    private IEnumerator RewindEndingCountdownUi()
    {
        WorldUIManager.DisplayBanner(WorldUiElement.SubBanner);

        var timeWaitedForResume = 0f;

        while (true)
        {
            // Banner will exit when status changes for any reason
            if (_currentRewindStatus != RewindStatus.SafeFreeze && timeWaitedForResume > 0)
            {
                break;
            }

            var countdown = Math.Round((Rewinder.WaitBeforeResumeTime - timeWaitedForResume), 1);
            countdown = countdown < 0 ? 0 : countdown;
            WorldUIManager.SetBannerText(WorldUiElement.SubBanner, countdown.ToString());
            timeWaitedForResume += Time.deltaTime;

            yield return(null);
        }

        WorldUIManager.HideElement(WorldUiElement.SubBanner);
    }
Exemplo n.º 2
0
 private void HideDeathUI()
 {
     WorldUIManager.HideElement(WorldUiElement.MainBanner);
     WorldUIManager.HideElement(WorldUiElement.SubBanner);
 }