static bool HasFunction( string name )

book_4_sparkGenerated
code_blocksInput

Description

The HasFunction method is a static member of the Editor.ShaderGraph.ShaderTemplate class. It checks whether a shader function with the specified name exists within the shader template.

Usage

To use the HasFunction method, call it with the name of the function you want to check for. The method returns a boolean value indicating whether the function exists.

Example

// Example usage of HasFunction method
bool functionExists = ShaderTemplate.HasFunction("ColorBurn_blend");
if (functionExists)
{
    // The function exists, proceed with logic
}
else
{
    // The function does not exist, handle accordingly
}