void ShowPrompt(PromptText prompt) { StopAllCoroutines(); this.prompt.text = prompt.text; this.prompt.color = prompt.color; StartCoroutine(PromptMove()); }
IEnumerator RemoveFireBoost(float boost, float time, Color tint) { yield return(new WaitForSeconds(time)); attackRate *= boost; PromptText prompt = "- Firerate"; prompt.color = tint; Message <PromptText> .Raise(prompt); }
IEnumerator RemoveSpeed(float strength, float length, Color tint) { yield return(new WaitForSeconds(length)); speed -= strength; PromptText prompt = "- Speed"; prompt.color = tint; Message <PromptText> .Raise(prompt); }
IEnumerator DoInvincible(float time, Color tint) { StopCoroutine("DoInvulnerab"); vulnerable = false; yield return(new WaitForSeconds(time)); vulnerable = true; PromptText prompt = "- Invincibility"; prompt.color = tint; Message <PromptText> .Raise(prompt); }