Unity Products:Amplify Shader Editor/Static Switch
The Static Switch node creates and/or uses shader keywords through #if #elif/#else #endif directives. Its input True will be used inside the #if directive body while the False input will be used on the #else directive. If multiple keywords are defined on the Type then an #elif directive will be created to each one of the middle items.
|Node Parameter||Description||Default Value|
|Type|| Type of keyword to be specified
||Shader Feature Keyword|
|Material Toggle||If activated, creates a Toggle property so keyword can be set via the material inspector.||True|
|Toggle Type|| Defines the toggle default behavior when it's checked on
|Default Value||Defines the default value for the Material Toggle property. This property is only visible if Material Toggle is turned on.||False|
|Shader Feature/Multi Compile|
|Name||Name of the keyword that will be created and used by the node.||Keyword #|
|Property Name||This is the variable name that contains the value which is automatically generated from the Name parameter, it's greyed out and not editable. The generation process removes special characters, whitespaces and adds an underscore at the beginning ( ie: "My Keyword Name" becomes "_MyKeywordName" ).||_Keyword#|
|Keyword Name||This is the generated keyword name which is automatically generated using the Name parameter, it's greyed out and not editable. The generation process removes special characters, whitespaces, adds an underscore(_) at the beginning, convert all characters to upper case and adds _ON at the end ( ie: "My Keyword Name" becomes "_MYKEYWORDNAME_ON" ).||_Keyword#|
|Keyword|| Allows to select already existing Unity keywords or select a new custom new one. This list will continuously grow according to community needs/feedback.
|Custom||Write custom keyword to be used. This property is only visible if Keyword property is set to Custom.|
|True||Value to be outputted if selected keyword is being defined (#if body).||Float |
|False||Value to be outputted if selected keyword is not being defined (#else body).||Float |