Log in or register to post comments

Cant reference C# Scripts in JS due to compilation timing

December 6, 2012 - 10:53pm #1

Hello,

 

I'm using a JS(UnityScript) to determine when the marker is detected (using GetComponent) In order to actually access the script, I have to put the scripts inside the Standard Assets folder (this is done for all scripts that must be loaded first) which slows down the initial loading, but more importantly Vuforia gets an error failing to find all the assets.

How would one send a command in the OnTrackingFound() function in the DefaultTrackableEventHandler.cs script that can be read by a Javascript script?

 

Thank you in advance.

Cant reference C# Scripts in JS due to compilation timing

December 10, 2012 - 6:44am #4

Great !

Glad I could help :)

N

Cant reference C# Scripts in JS due to compilation timing

December 8, 2012 - 1:53pm #3

Thanks 10x, works as advertised.

Cant reference C# Scripts in JS due to compilation timing

December 7, 2012 - 5:34am #2

Hi,

Have you tried creating an empty GameObject and attaching your Javascript file to it, and then using SendMessage as decribed here:

http://docs.unity3d.com/Documentation/ScriptReference/GameObject.SendMessage.html

N

 

 

Log in or register to post comments