Skip to main content

Effect Class

Description:

  A class for creating Effect objects.

__call

Type: Metamethod.

Description:

  A metamethod that allows you to create a new Effect object.

Signature:

metamethod __call: function(self: EffectClass, vertShader: string, fragShader: string): Effect

Parameters:

ParameterTypeDescription
vertShaderstringThe vertex shader file string.
fragShaderstringThe fragment shader file string.A shader file string must be one of the formats: "builtin:" + theBuiltinShaderName "Shader/compiled_shader_file.bin"

Returns:

Return TypeDescription
EffectA new Effect object.

__call

Type: Metamethod.

Description:

  Another metamethod that allows you to create a new empty Effect object.

Signature:

metamethod __call: function(self: EffectClass): Effect

Returns:

Return TypeDescription
EffectA new empty Effect object.