Ejemplo n.º 1
0
    public IEnumerator ApplyCCEffects(CC.CCEffect effect, float cooldown)
    {
        switch (effect)
        {
        default:
            break;

        case CC.CCEffect.Snare:

            float defJumpForce     = JumpForce;
            float defMovementSpeed = MovementSpeed;

            isSnared      = true;
            MovementSpeed = 0;
            JumpForce     = 0;

            yield return(new WaitForSeconds(cooldown));

            MovementSpeed = defMovementSpeed;
            JumpForce     = defJumpForce;
            isSnared      = false;

            break;
        }
    }
Ejemplo n.º 2
0
 public void ApplyCC(CC.CCEffect effect, float cooldown)
 {
     StartCoroutine(ApplyCCEffects(effect, cooldown));
 }