warnAboutOutOfDateShaders
Whether Unity logs a warning when it loads a SubShader built with a different major or minor Unity version.
Read time 1 minuteLast updated 4 days ago
Definition
- Type: Property
- Namespace: UnityEditor
- Assembly: UnityEditor.CoreModule
public static bool warnAboutOutOfDateShaders { get; set; }
Remarks
Set this property to to display a warning in the Console when Unity loads a built with a different Unity version. An out-of-date can render incorrectly or lead to reduced performance. To fix the warning, rebuild the AssetBundle or content directory that contains the shader.
trueSubShaderSubShadersUnity checks each in a shader separately. Unity compares only the major and minor parts of the version, and ignores the patch version. For example, for a built with Unity 7000.1.2f1:
SubShaderSubShader- Unity 7000.1.5f1 doesn't display a warning when it loads the , because only the patch version differs.
SubShader - Unity 7000.2.0f1 displays a warning when it loads the , because the minor version differs.
SubShader
Unity skips the check if any of the following is true:
- The AssetBundle or a content directory containing a shader was built while this property was set to .
false - The Player that loads the content was built with this setting set to .
false - The Editor that loads the content has this property set to .
false
If the AssetBundle or content directory was built with a Unity version earlier than 7.0, Unity skips the and displays an error. Unity does this even if this property is false.
SubShader