Color.gray 灰色
static var gray : Color
Description描述
Gray. RGBA is (0.5, 0.5, 0.5, 1).
灰色。 RGBA 是 (0.5, 0.5, 0.5, 1) 。
C#
JavaScript
using UnityEngine;using System.Collections;public class example : MonoBehaviour {public void Awake() {transform.renderer.material.color = Color.gray;}}
// Assign a gray color to this transform's material// 赋一个灰色给这个变换的材质。transform.renderer.material.color = Color.gray;