float型からint型に変換することができるらしいのでメモ。
[ 変換方法 ]
下記はfloat型のFloatTestをint型に変換しIntTestに代入しています。
using System; using System.Collections.Generic; using UnityEngine; public class ScriptTest : MonoBehaviour { void Start() { float FloatTest = 3.0f; int IntTest = 0; IntTest = (int)FloatTest; } }