HELP
Development FAQ

Turn off automatic compilation of Typescript assets

6min

Go to the Unity > Preference menu and disable the Auto Refresh item in the General tab.

Now, the automatic script compilation is disabled, and Unity won't compile scripts automatically when you save changes.

Document image




❗️ Caution

Auto Refresh enables the automatic update of all assets in the Unity project, not limited to Typescript assets. Therefore, it is recommended to utilize Auto Refresh.



Manually Compiling Typescript

When the automatic compilation feature is disabled, you need to manually compile the changed Typescript.

  • Select the Typescript you want to compile in the Project panel and press the Force Rebuild button in the Inspector panel.
  • You can see that the selected Typescript is compiled automatically.
Document image




Manually compiling all Typescript assets

You can initiate a compilation of all Typescript assets in your project via the Rebuild All.

Selecting ZEPETO > Script > Rebuild All will trigger a recompilation of all Typescript assets within the project.

Document image




👍 Tips Rebuild All(for not compiled) menu compiles only Typescript assets that were not previously compiled.



How to check a line of code when a script error occurs

Sometimes, it's challenging to pinpoint the exact location of code that causes errors when you write Typescript and run it at runtime.

Select the Typescript causing the error in the Project panel and click the Open Compiled Script button in the Inspector panel.

Document image




You'll see the Typescript compiled into Javascript in the script editor.

You can find the Javascript lines marked as errors in the Console log.

Document image