Package debug in Unity without affecting the redirection of debug

Source: Internet
Author: User

Debug.Log, debug.logwarning, debug.logerror often need to wrap one more layer in project. Do some customization. Also convenient to switch log. But there is a problem when. When the debug package is wrapped in a class, the log in the console is double-clicked, jumping to the implementation of your own class, rather than log records.

Tangled up for a while, and then came across a log that wrote the question.

http://www.xuanyusong.com/archives/2782, the class that wraps the debug into a DLL is imported into project. can be very convenient to use, double-click will jump directly to the place to write the log.

The log does not write this solution is how to come, the author himself said is blind ... I think it should be that the class has been plugged into the. dll. Double-clicking the log in the console cannot jump to the class in the. dll, so it jumps to the other default location: the log record.

The DLL made by the author in the log is under the Mac platform and a line of scripts is done. Under Windows, you can create a new class library project and put the package Debug class in. The corresponding UnityEngine.dll should be imported according to the need.

Special attention is needed. Project settings may need to be changed, and Unity's adaptation Projecttarget framework needs to be Unity3.5. NE full/subset Base Class libararies.

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvdtaxmde1mzcwmw==/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">


Set OK, the. dll is available directly rebuild,debug the version number and release version number.

Place it directly under Unityproject's assets folder, and suggest placing it in the Plugins folder.



Package debug in Unity without affecting the redirection of debug

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.