superunitybuild / buildtool

A powerful automation tool for quickly and easily generating builds with Unity.
MIT License
1.19k stars 121 forks source link

Possible to skip "Compiling shader variants" ? #124

Closed mathisevaveo closed 1 year ago

mathisevaveo commented 1 year ago

Hello !

I discovered SuperUnityBuild very recently and find the package incredible! It's super practical for my corss-platform project and it's already saved me a huge amount of time!

Unfortunately, Unity is still causing problems ahah! I wanted to know if with the package you could deactivate the "Compiling Shader Variants" because it takes almost 45 minutes per version even though I'm using a super M2!

Thanks in advance for your answers! Best regards

robinnorth commented 1 year ago

Thanks for your kind words, @mathisevaveo!

Once you've created a build with shaders compiled, you can set your Release Type to only compile script changes for subsequent runs by selecting 'Build Scripts Only' option from the 'Advanced Options' dropdown:

image

Alternatively, I can highly recommend Shader Control on the Unity Asset Store as a means of cutting down the number of shader variants that need to be compiled for your project.

Hope this helps!

mathisevaveo commented 1 year ago

Perfect, thank you, i will check this today !