x


Build failed with JS calling C# code

Hello Everyone! First i'd like to say that I appreciate the efforts of everyone here to help others, the community has helped me a lot. Thanks to everyone.

Second... I am triying to build an app for iPhone. As I am new to unity I have made the "mistake" of mixing languages and I have a JS calling a C# method.

I already have read the docs about placing the script on /Standard Assets and on the viewport the app runs. without any problem. The PROBLEM COMES when I try to build for Xcode. bassically the class gets ignored, and I get the message I have this missing method in C# ( because it has not been compiled yet )

Any ideas?

I have also read that other people had have this problem before in Android.

Thanks in advanced

Cheers!

more ▼

asked Mar 23 '11 at 03:01 PM

ForceFollower gravatar image

ForceFollower
1 1 1 1

(comments are locked)
10|3000 characters needed characters left

1 answer: sort voted first

Hey everyone!

I am leaving some information I used to solve my problem :

After the "great response" of answers I decided to rewrite the code in JS, I though this would solve the problem, but it didn't, then I found out that the main problem was "Dynamic typing" when developing for iOS.

I read this and helped me out to get the problem.

http://forum.unity3d.com/threads/44903-Dynamic-typing-in-javascript-Errors

I noticed as the example the problem was on "GetComponent". so I decide to modify the script and use SendMessage, thats how i made it work

I hope someone can find this useful.

Cheers

more ▼

answered Mar 24 '11 at 02:31 PM

ForceFollower gravatar image

ForceFollower
1 1 1 1

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x665
x123

asked: Mar 23 '11 at 03:01 PM

Seen: 924 times

Last Updated: Mar 23 '11 at 03:01 PM