Cocos2d-js Write logs log view logs log Android Debug view

Source: Internet
Author: User

1 the way to output the log, of course, is cc.log 2 How to view the log?

A) If the applet can run on the browser first, for example with chrome, the output log can be seen in the console;

b) If you are debugging on a real machine, you need to use the log tool. Use Logcat on Android.

3 Android Debugging using Logcat method

Logcat Location: Android SDK Directory in D:\AndroidDevelopTools\sdk\platform-tools

To view the steps:

      • Connect your phone
      • CMD mode open Logcat:adb.exe Logcat
      • This can see the log of the Cocos program, but in addition to the Cocos log, there are a variety of system program logs.

Logcat specific command line parameters, you can see the online description, you can also see Logcat own Help

I'm a bit clumsy, and I can't find the correct usage of filter. So, I was too lazy to toss, instead of using the CMD filter. Find "Cocos2d-x Debug Info"

Final command to enable Logcat:

Adb.exe logcat | find "cocos2d-x Debug Info"

Related Article

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.