using UnityEngine;
using LitMotion.Adapters;
namespace LitMotion
{
public static partial class LMotion
{
///
/// API for creating Shake motions.
///
public static class Shake
{
///
/// Create a builder for building Shake motion.
///
/// Start value
/// Vibration strength
/// Duration
/// Created motion builder
public static MotionBuilder Create(float startValue, float strength, float duration)
{
return Create(startValue, strength, duration)
.WithOptions(ShakeOptions.Default);
}
///
/// Create a builder for building Shake motion.
///
/// Start value
/// Vibration strength
/// Duration
/// Created motion builder
public static MotionBuilder Create(Vector2 startValue, Vector2 strength, float duration)
{
return Create(startValue, strength, duration)
.WithOptions(ShakeOptions.Default);
}
///
/// Create a builder for building Shake motion.
///
/// Start value
/// Vibration strength
/// Duration
/// Created motion builder
public static MotionBuilder Create(Vector3 startValue, Vector3 strength, float duration)
{
return Create(startValue, strength, duration)
.WithOptions(ShakeOptions.Default);
}
}
}
}