private IEnumerator ApplySpeedBuff(TemplateMovement defaultSpeed, TemplateMovement speedBuffSpeed, float duration) { moveInfo = speedBuffSpeed; yield return(new WaitForSeconds(duration)); moveInfo = defaultSpeed; }
public void ActivateSpeedBuff(TemplateMovement defaultSpeed, TemplateMovement speedBuffSpeed, float duration) { StartCoroutine(ApplySpeedBuff(defaultSpeed, speedBuffSpeed, duration)); }