HasEffectShader

From GECK

A function added by the JIP NVSE Plugin.

Description

Checks if the specified effect shader is playing on the calling reference, and if so returns the number of instances of that shader playing on it. Otherwise returns zero.

Syntax

(instanceCount:int) reference.HasEffectShader effectShader:ref

Example

set iShaderInstances to someObjectRef.HasEffectShader GlowingOneFXShader

Notes

  • This function may return a value greater than 0 for a short period after calling StopMagicShaderVisuals. This is because the shader is not fully removed until its ending sequence has played out.

NVSE Version

  • This function is also added by NVSE 5.0.2, but this version just returns a boolean, 1 if the reference has the shader, or 0 if not, rather than the number of instances.

See Also

Personal tools