Esempio n. 1
0
        public Vector2 GetShake(float speed, float amp)
        {
            float shakeVal = ShapesMath.Frac(Time.time * speed);
            float shakeX   = shakeAnimX.Evaluate(shakeVal);
            float shakeY   = shakeAnimY.Evaluate(shakeVal);

            return(new Vector2(shakeX, shakeY) * amp);
        }