GameObject
- active
- AddComponent.<T>
- AddComponent
- animation
- audio
- BroadcastMessage
- camera
- collider
- CompareTag
- constantForce
- CreatePrimitive
- FindGameObjectsWithTag
- FindWithTag
- Find
- GameObject
- GetComponent.<T>
- GetComponentInChildren.<T>
- GetComponentInChildren
- GetComponents.<T>
- GetComponentsInChildren.<T>
- GetComponentsInChildren
- GetComponents
- GetComponent
- guiTexture
- guiText
- hingeJoint
- isStatic
- layer
- light
- networkView
- particleEmitter
- renderer
- rigidbody
- SampleAnimation
- SendMessageUpwards
- SendMessage
- SetActiveRecursively
- tag
- transform
GameObject.renderer 渲染器
var renderer : Renderer
Description描述
The Renderer attached to this GameObject (Read Only). (null if there is none attached)
附属于这个游戏物体上的渲染器(只读)。(如果没有则为空)
using UnityEngine;
using System.Collections;
public class example : MonoBehaviour {
public GameObject other;
public void Awake() {
other.renderer.material.color = Color.green;
}
}
var other : GameObject;
other.renderer.material.color = Color.green;
最后修改:2010年12月15日 Wednesday 22:20