お好みのスクリプト言語を選択すると、サンプルコードがその言語で表示されます。
Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.
Close布の有効/無効を設定します。
これはインスペクターのコンポーネントラベルの横にあるチェックボックスと同じものです。 無効にした布コンポーネントは物理シミュレーションの更新を行いません。なので布シミュレーションのようなCPUを酷使してしまうのが必要ない時、 布オブジェクトのシミュレーションを一時停止させることが可能です。
GetComponent(InteractiveCloth).enabled = false;
using UnityEngine; using System.Collections; public class ExampleClass : MonoBehaviour { void Example() { GetComponent<InteractiveCloth>().enabled = false; } }
import UnityEngine import System.Collections public class ExampleClass(MonoBehaviour): def Example() as void: GetComponent[of InteractiveCloth]().enabled = false