$alpha: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
No edit summary
Line 4: Line 4:
If ''any'' material on a [[brush]] has <code>$alpha</code>, the brush will stop affecting [[VVIS]] and become entirely transparent to [[NPC]]s from every angle.
If ''any'' material on a [[brush]] has <code>$alpha</code>, the brush will stop affecting [[VVIS]] and become entirely transparent to [[NPC]]s from every angle.


This may be used with <code>[[$translucent]]</code>.
This may be used with <code>[[$translucent]]</code>, although using <code>[[$translucent]]</code> here is redundant, as any <code>[[$alpha]]</code> different than 1 will already apply the <code>[[$translucent]]</code> parameter.
 
This cannot be used with <code>[[$alphatest]]</code>. If used, the material will be invisible.


==Syntax==
==Syntax==

Revision as of 10:53, 3 June 2023

English (en)Deutsch (de)Español (es)Français (fr)Русский (ru)Translate (Translate)

$alpha is a material shader parameter. It scales the opacity of an entire material by the given value. 1 is entirely opaque, 0 is invisible.

If any material on a brush has $alpha, the brush will stop affecting VVIS and become entirely transparent to NPCs from every angle.

This may be used with $translucent, although using $translucent here is redundant, as any $alpha different than 1 will already apply the $translucent parameter.

This cannot be used with $alphatest. If used, the material will be invisible.

Syntax

$alpha	<normal>

See also