예제 #1
0
        public static TSVector2 Lerp(TSVector2 value1, TSVector2 value2, FP amount)
        {
            amount = TSMath.Clamp(amount, 0, 1);

            return(new TSVector2(
                       TSMath.Lerp(value1.x, value2.x, amount),
                       TSMath.Lerp(value1.y, value2.y, amount)));
        }
예제 #2
0
 public static void LerpUnclamped(ref TSVector2 value1, ref TSVector2 value2, FP amount, out TSVector2 result)
 {
     result = new TSVector2(
         TSMath.Lerp(value1.x, value2.x, amount),
         TSMath.Lerp(value1.y, value2.y, amount));
 }
예제 #3
0
 public static TSVector2 LerpUnclamped(TSVector2 value1, TSVector2 value2, FP amount)
 {
     return(new TSVector2(
                TSMath.Lerp(value1.x, value2.x, amount),
                TSMath.Lerp(value1.y, value2.y, amount)));
 }