Shadow control: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(→‎Entity Description: added workaround warning)
mNo edit summary
Line 3: Line 3:


==Entity Description==
==Entity Description==
[[Image:{{PAGENAME}}.png|left]]Controls dynamically projected shadows (produced by player models, NPCs, and physics props) in the entire map.{{clr}}
[[Image:{{PAGENAME}}.png|left]] Defines the direction, color and attenuation distance of [[Dynamic Shadows]] for the entire map.{{clr}}
{{Warning|[[light_environment]], [[env_sun]] and [[shadow_control]] should be used together. Each entity represents only a one aspect of a naturally unified phenomenon; Sunlight. [[light_environment]] defines the direct sunlight settings and creates (buggy, unconfigurable) dynamic shadows which can only be overridden/controlled by [[shadow_control]]. [[env_sun]] places a glow sprite in the skybox where the sunlight comes from. To make sense of it all, just make sure that the <angles> (Pitch/Yaw/Roll) are set the same for all three entities. Unfortunately [[shadow_control]] does not have the Pitch override parameter, so its Pitch will be determined by the first of its <angles>. Even more unfortunately, the Pitch override rotation cannot be switched off and is measured counter-clockwise from the horizontal (so straight down is -90 degrees) whereas the <angles> Pitch is rotation is clockwise (so straight down is +90 degrees).}}
{{Warning|[[light_environment]], [[env_sun]] and [[shadow_control]] should be used together. Each entity represents only a one aspect of a naturally unified phenomenon; Sunlight. [[light_environment]] defines the direct sunlight settings and creates (buggy, unconfigurable) dynamic shadows which can only be overridden/controlled by [[shadow_control]]. [[env_sun]] places a glow sprite in the skybox where the sunlight comes from. To make sense of it all, just make sure that the <angles> (Pitch/Yaw/Roll) are set the same for all three entities. Unfortunately [[shadow_control]] does not have the Pitch override parameter, so its Pitch will be determined by the first of its <angles>. Even more unfortunately, the Pitch override rotation cannot be switched off and is measured counter-clockwise from the horizontal (so straight down is -90 degrees) whereas the <angles> Pitch is rotation is clockwise (so straight down is +90 degrees).}}



Revision as of 10:14, 15 April 2008

Template:Wrongtitle Template:Base point

Entity Description

Shadow control.png

Defines the direction, color and attenuation distance of Dynamic Shadows for the entire map.

Warning.pngWarning:light_environment, env_sun and shadow_control should be used together. Each entity represents only a one aspect of a naturally unified phenomenon; Sunlight. light_environment defines the direct sunlight settings and creates (buggy, unconfigurable) dynamic shadows which can only be overridden/controlled by shadow_control. env_sun places a glow sprite in the skybox where the sunlight comes from. To make sense of it all, just make sure that the <angles> (Pitch/Yaw/Roll) are set the same for all three entities. Unfortunately shadow_control does not have the Pitch override parameter, so its Pitch will be determined by the first of its <angles>. Even more unfortunately, the Pitch override rotation cannot be switched off and is measured counter-clockwise from the horizontal (so straight down is -90 degrees) whereas the <angles> Pitch is rotation is clockwise (so straight down is +90 degrees).

Keyvalues

  • color
#000000 The color of the shadows.
  • distance
<float> The maximum distance the shadow is allowed to cast, in inches.
<boolean> All Shadows Disabled

Inputs

  • color #000000
Set the shadow color.
  • direction <vector>
Set the shadow direction.
  • SetDistance <float>
Set the maximum shadow cast distance.
Set the shadow direction.
Set shadows disabled state.

Outputs