Call JavaScript function from C# in Unity3D
Mostly developer use a particular language to do code in Unity3D.
But some times you need to use two types of Scripts. At same point you also may required to call vise a versa functions
of both scripts. Which is little tricky to call.
GameObject.FindgameObjectWithtag("MainCamera").GetComponent("OtherScript").SendMessage("Test");
You can drop this "OtherScript" to main camera.
0 Comment(s)