Sunday 9 November 2014

Memanggil Fungsi dari Gameobject Lain

 GameObject go = GameObject.Find("somegameobjectname");  
 ScriptB other = (ScriptB) go.GetComponent(typeof(ScriptB));  
 other.DoSomething();  


sumber:
http://answers.unity3d.com/questions/7555/how-do-i-call-a-function-in-another-gameobjects-sc.html

0 comments :

Post a Comment