格式
typescript
Vector3.LerpUnclamped(lhs, rhs, t)所属类: Vector3
描述
使用t在向量lhs和向量rhs之间进行线性插值。
不限制 t 的值。
参数
| 参数名 | 类型 | 描述 |
|---|---|---|
| lhs | Vector3 | 起始向量 |
| rhs | Vector3 | 结束向量 |
| t | number | 插值系数,表示插值在起点和终点之间的比例 |
返回值
| 类型 | 描述 |
|---|---|
Vector3 | 新Vector3对象 |
代码示例
typescript
let from = new Vector3(1,2,3);
let to = new Vector3(3,4,5);
Debug.Log("LerpUnclamped is",Vector3.LerpUnclamped(from,to,5));