using UnityEngine; using System.Collections; public class ExampleClass : MonoBehaviour { public bool _bool ; public byte _byte ; public sbyte _sbyte ; public char _char ; public decimal _decimal; // × public double _double ; public float _float ; public int _int ; public uint _uint ; public long _long ; public ulong _ulong ; public object _object ; // × public short _short ; public ushort _ushort ; public string _string ; }

| 型 | 表示 |
|---|---|
| bool | ○ |
| byte | ○ |
| sbyte | ○ |
| char | ○ |
| decimal | × |
| double | ○ |
| float | ○ |
| int | ○ |
| uint | ○ |
| long | ○ |
| ulong | ○ |
| object | × |
| short | ○ |
| ushort | ○ |
| string | ○ |
Unity 4.6 までのころは byte 型などの変数は
Inspector で表示できなかった気がするのですが
Unity 5.3 ではほぼすべての組み込み型の変数が
Inspector で表示できるようです