Running out of Shader Keywords
This page used to describe a real constraint. On the Unity versions this asset supports it is not one anymore, and there is nothing you need to do about it.
The current limits
Section titled “The current limits”Unity allows more than four billion global keywords, and up to 65,534 local keywords per shader. The old ceilings, a couple of hundred global and 64 local, are what used to make a keyword heavy asset a problem in a keyword heavy project. They are gone.
One number is still worth knowing: a shader that uses more than 128 keywords pays a small runtime cost.
How many this asset uses
Section titled “How many this asset uses”The effects account for 64 keywords. Each variant then adds a few of its own, for things like atlas support, billboarding, fog and feeding the glow into 2D lights, which brings the total to between 66 and 69 depending on the shader variant.
Unity then adds its own on top of yours, from multi_compile directives for fog, GPU instancing, UI clipping and 2D shape lights, plus the four it always reserves. Those count towards the 128 too, so the real figure per shader is higher than the asset’s own numbers, and still under the line.
Why that no longer matters
Section titled “Why that no longer matters”Every keyword this asset declares is a local keyword, which scopes it to the shader and means it is set per material rather than project wide. None of them touch the global budget at all, so no number of All In 1 materials in your project can use it up.
Older versions of this page asked you to open the shaders and replace shader_feature with shader_feature_local by hand. Do not do that. The conversion already shipped, and two of the shader files are regenerated automatically whenever the Unity version or render pipeline changes, so edits to those are overwritten.
If you landed here because sprites vanish in a build
Section titled “If you landed here because sprites vanish in a build”That is a different problem with a similar smell. It is caused by a shader variant that was never built, not by running out of keywords, and it comes up when effects are toggled by keyword at runtime. See How to Enable/Disable Effects at Runtime.
