x


Debug.Log Causes Unity Crash

so as an attempt to debug my program, i put Debug.Log() inside Update cycle and Unity always crashes and when i remove Debug.Log() it does fine It's really a shame debugging in Unity is really pain and the only good is breakpoint in MonoDevelop :(

sorry it's being rude, are there any tips of unity debugging best practice? specifically C# scripting

more ▼

asked Jul 25 '12 at 05:06 AM

azer89 gravatar image

azer89
1 1 3 5

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

2 answers: sort oldest

Debug.Log is expensive, it dumps the stack each time. There are alternates. You might be able to make a GUIText or other type of text object and dump text to that. I'm pretty sure there are some alternate debugging consoles on the script wiki page, and probably in the Asset Store too.

more ▼

answered Jul 25 '12 at 05:08 AM

DaveA gravatar image

DaveA
26.5k 151 171 256

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

by coincidence i found this:

https://gist.github.com/1412228

more ▼

answered Jul 30 '12 at 08:33 AM

azer89 gravatar image

azer89
1 1 3 5

(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:

x239

asked: Jul 25 '12 at 05:06 AM

Seen: 382 times

Last Updated: Jul 30 '12 at 08:33 AM