Small knowledge, big challenge! This article is participating in the creation activity of “Essential Tips for Programmers”.

👉 About the author

As we all know, life is a long process of constantly overcoming difficulties and reflecting on progress. In this process, there will be a lot of questions and thoughts about life, so I decided to share my thoughts, experiences and stories to find resonance!!

Focus on Android/Unity and various game development tips, as well as various resource sharing (websites, tools, materials, source code, games, etc.)

Welcome to pay attention to the public account [Mr. Empty name] for more resources and communication!

👉 premise

Playing games is an effective way to learn.

👉 Practice

😜 Scenario editor

You can freely switch between 3D view and 2D view

3D View shortcut keys:

  • Left mouse button + Alt: Rotate the view center.
  • Middle mouse button: Pan view.
  • Mouse Wheel: Zooms in and out the view from the center point.
  • Right mouse button + WASD: Camera roaming.
  • F Shortcut: Focus the camera on the selected node.

2D View shortcut keys:

  • Middle mouse button: Pan view.
  • Mouse wheel: Zooms in and out from the current mouse hover position.
  • Right mouse button: Pan view.
  • F Shortcut: Focus the camera on the selected node.

Transform tool:

Note: The text is automatically filled by default and the width is adaptive. The Rectangle transform tool cannot be used to expand or shrink the width and height at any time.

😜 Resource/hierarchy manager and property inspector

Same as Unity, no significant difference.

😜 console

Display is no different from Unity, with multiple customizations that allow you to quickly open hyperlinks, images, and locate nodes in the log. (Unity can also do this with plug-ins.)

The following output is supported:

  • Jump to a link from a URL
  • Display images according to urls
  • Locate the Asset resource based on the URL or UUID
  • Locate the Node based on the UUID
  • Locate the script file based on the disk file path
  • Output copy in the corresponding language

-link is an external jump link, Image is an Image, Asset is a resource, node is a node, i18n is a multilingual translation) :

console.log('Open {link[the help doc url](https://docs.cocos.com/creator/manual/en/editor/console/)}');
console.log('Locate {link[ the file in library](D:/cocos-creator/a/library/36/36b55a90-1547-4695-8105-abd89f8a0e5f.js)}');
console.log('Locate Node UUID {node(f6zHdGKiZDhqbDizUsp8mK)}');
console.warn('Locate Asset UUID {asset(17185449-5194-4d6c-83dc-1e785375acdb)}');
console.error('Locate Asset URL {asset(db://assets/animation.anim)}');
console.log('The URL is {asset[{asset(db://assets/animation.anim)}](db://assets/animation.anim)}');
console.log('Show image {image(https://forum.cocos.org/images/logo.png)}');
console.log('Translate: {i18n(console.description)}');
Copy the code

😜 Preference Settings

Numeric default Step: Used to set the magnitude of the step when adjusting numeric properties through the step button in the property inspector. The default step size is 0.001.

Engine manager

  • Use the built-in TypeScript engine: Whether to use the engine path in the Cocos Creator installation path as the TypeScript engine path. This engine is used for rendering scenes in the editor, declaring built-in components (i.e. smart hints when using code editors such as VSCode), and previewing scenes in the Web environment.
  • Custom TypeScript engine paths: In addition to using their own engine, can also go to engine warehouse (making | Gitee) cloning or fork a engine to local customization of any position, and then cancel the check Use the built-in TypeScript engine, Specify the custom TypeScript engine path as the custom engine path, and you can use the custom engine in the editor.
  • Use the built-in native engine: Whether to use the cocos2D-x path in the Cocos Creator installation path as the native engine path. This engine is used to build engineering builds and compilations for all native platforms (iOS, Android, Mac, Windows) at the time of release.
  • Custom native engine paths: You can specify the native engine paths manually by canceling the previous option to use the built-in native engine. Pay attention to the native engine used here must be from the engine – native (making | Gitee) or download the fork of the warehouse.

👉 other

📢 author: Kom and Kom in Kom

📢 reprint instructions – be sure to specify the source: Zhim Granular’s personal home page – column – Nuggets (juejin. Cn)

📢 welcome to like 👍 collect 🌟 message 📝