I’m been trying to send debug messages to the Console, but with no luck - nothing is displayed there.
I’ve made sure the executable doesn’t strip debug symbols - but is there anything else to do ?
I’m been trying to send debug messages to the Console, but with no luck - nothing is displayed there.
I’ve made sure the executable doesn’t strip debug symbols - but is there anything else to do ?
I don’t think it’s possible to debug your scripts with something like gdb/Xcode even if you leave debug symbols in the executable, since the scripts aren’t native code. As far as I can tell, this is only useful for the purpose of determining where the Unity player app went wrong in a crash log.
I can certainly send debug messages to the console in my code. What are you doing that doesn’t work? Is the code that’s printing debug messages even being called?
You have to use Debug.Log(string) to send messages to the console.
To debug complex scripts I think it’s faster to use a external ide/compiler/debugger with something like this:
#if WINDEBUG
…logging code
#else
…graphic code
#endif
I’m putting in a couple of Log statements in with the main code (Update - which works, because the Javascript code is being run) - I dont know whether the Log function is actually being called or not though, as nothing is being displayed… I’m not at my machine, so I cant add the code yet.
Speaking of which, is it possible to get Javascript to call C/C++ plug-ins - all the instructions talk about is doing it from C#
If you are testing your app outside Unity you can open the applications/utility/console app to see all logs.
In windows the logfile is in apppath/data/output_log.txt
I use c#, I can’t help you with javascript
Its being run from Unity (created as an Intel Mac program).
If you create the app with “build and run” is outside Unity. Hit the “play” button to run it in Unity.
Thats probably where I’m going wrong!
Btw, for Windows, I can highly recommened BareTail: http://www.baremetalsoft.com - if you’re used to using tail or the Mac Console, it feels rather awkward having to open a text file, reopen it to see the updates and so on. BareTail solves that in a very nice manner, and there’s a nice freeware version (only “annoyance” is a little splash-screen, but that’s not really annoying).
Jashan