Mathf
- Abs
- Acos
- Approximately
- Asin
- Atan2
- Atan
- CeilToInt
- Ceil
- Clamp01
- Clamp
- ClosestPowerOfTwo
- Cos
- Deg2Rad
- DeltaAngle
- Epsilon
- Exp
- FloorToInt
- Floor
- Infinity
- InverseLerp
- IsPowerOfTwo
- LerpAngle
- Lerp
- Log10
- Log
- Max
- Min
- MoveTowardsAngle
- MoveTowards
- NegativeInfinity
- NextPowerOfTwo
- PingPong
- PI
- Pow
- Rad2Deg
- Repeat
- RoundToInt
- Round
- Sign
- Sin
- SmoothDampAngle
- SmoothDamp
- SmoothStep
- Sqrt
- Tan
Mathf.Min 最小值
static function Min (a : float, b : float) : float
static function Min (params values : float[]) : float
Description描述
Returns the smallest of two or more values.
返回两个或更多值中最小的值。
using UnityEngine;
using System.Collections;
public class example : MonoBehaviour {
public void Awake() {
print(Mathf.Min(1.2F, 2.4F));
}
}
// prints 1.2
print(Mathf.Min(1.2, 2.4));
•static function Min (a : int, b : int) : int
•static function Min (params values : int[]) : int
Description描述
Returns the smallest of two or more values.
返回两个或更多值中最小的值。
using UnityEngine;
using System.Collections;
public class example : MonoBehaviour {
public void Awake() {
print(Mathf.Min(1, 2));
}
}
// prints 1
print(Mathf.Min(1, 2));
最后修改:2011年2月22日 Tuesday 19:12