Env projectedtexture: Difference between revisions
Jump to navigation
Jump to search
Note:Shadows are only drawn when the user is running with "High" shadow detail.
Note:mp_flashlight (in multiplayer) and mat_flashlight must be set to 1 in order for it to work; for this reason, it is not supported by default in Team Fortress 2.
Bug:Does not accept a configurable texture value from Hammer - will always default to the flashlight. You must use the
(a few more facts about support) |
mNo edit summary |
||
Line 2: | Line 2: | ||
[[Image:trainstationdlight_0.jpg|thumb|[[Env_projectedtexture]]s allow for self-shadows, shadow-receivers, and properly oriented and proportioned shadows. Two of these entities are currently being used in this scene. After "grain" fix]] | [[Image:trainstationdlight_0.jpg|thumb|[[Env_projectedtexture]]s allow for self-shadows, shadow-receivers, and properly oriented and proportioned shadows. Two of these entities are currently being used in this scene. After "grain" fix]] | ||
{{base point ep2|env_projectedtexture}} It creates a dynamic [[Wikipedia:Shadow mapping|shadow-mapping]] light that affects all objects in the world. It is used to create the flashlights in [[Source 2009]] games and ''[[Left 4 Dead]]''. (''[[Left 4 Dead 2]] uses the old flashlight.) | {{base point ep2|env_projectedtexture}} It creates a dynamic [[Wikipedia:Shadow mapping|shadow-mapping]] light that affects all objects in the world. It is used to create the flashlights in [[Source 2009]] games and ''[[Left 4 Dead]]''. (''[[Left 4 Dead 2]]'' uses the old flashlight.) | ||
Support for projected textures will be greatly enhanced in [[Portal 2]], which appears to use them for the majority of its lighting. | Support for projected textures will be greatly enhanced in [[Portal 2]], which appears to use them for the majority of its lighting. |
Revision as of 17:58, 20 March 2011

Projecting a colourful texture.

Env_projectedtextures allow for self-shadows, shadow-receivers, and properly oriented and proportioned shadows. Two of these entities are currently being used in this scene. After "grain" fix
Template:Base point ep2 It creates a dynamic shadow-mapping light that affects all objects in the world. It is used to create the flashlights in Source 2009 games and Left 4 Dead. (Left 4 Dead 2 uses the old flashlight.)
Support for projected textures will be greatly enhanced in Portal 2, which appears to use them for the majority of its lighting.



SpotlightTexture
input or use the code fix available on the Bug Fixes page. [todo tested in ?]Bug fixes
See env_projectedtexture/fixes.
Keyvalues
- target
<string>
- The entity will rotate to point at its target, no matter where it is in the world. See also
lightonlytarget
.Bug:Does not work with stock SDK code. See Env_projectedtexture/fixes#Fixing targeting. [todo tested in ?]
- FOV
<float>
- The angle at which the texture is projected. The projection is square, but the texture can make it appear of any shape.
- Remember the default Player FOV is 75°.
- NearZ
<float>
- Near Z for projected texture. Default value is 4.0.
- Objects closer than this will not receive the projection.
- FarZ
<float>
- Far Z for projected texture. Default value is 750.0.
- Objects beyond this distance will not receive the projection. Think of it as the range limit.
- Enable Shadows
<bool>
- Should I cast shadows?
- Shadow Quality
<bool>
- Quality of shadows (Todo: what's the difference?)
- Light Only Target
<bool>
- Should I light only the entity that is my
target
? The world will still be lit. - Light World
<bool>
- Should I light the world?
- Camera Space
<bool>
- Display relative to player's view. Breaks things horribly unless the entity moves with the player.
- Light Color
⇆#000000rgb(0,0,0)⇆
- Tint of projected texture.
- texturename
<VTF/string>
- Sets the current projected texture associated with this entity.
Bug:Does not work with stock SDK code. See Env_projectedtexture/fixes#Fix configurable texture value in Hammer. [todo tested in ?]
Parentname:
- Parent (parentname) <targetname>
- Specifies a movement parent. An entity will maintain its initial offset from its parent. An attachment point can be added to the end of the name, separated by a comma.
Bug:Does not work with stock SDK code. See Env_projectedtexture/fixes#Fixing Parenting. [todo tested in ?]
- Pitch Yaw Roll (Y Z X) (angles) <QAngle>
- This entity's orientation in the world. Pitch is rotation around the Y axis, yaw is the rotation around the Z axis, roll is the rotation around the X axis.
- Name (targetname) <string>[ Edit ]
- The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g.
parentname
ortarget
).
Also displayed in Hammer's 2D views and Entity Report.See also: Generic Keyvalues, Inputs and Outputs available to all entities
Flags
- Enabled
Inputs
These inputs are accepted by the entity but not known to Hammer:
target <string>
- Specify a new target entity to point at.
cameraspace <bool>
- See above keyvalues.
LightOnlyTarget <bool>
- See above keyvalues.
Bug:Non-functional. [todo tested in ?]
LightWorld <bool>
- See above keyvalues.
Bug:Cannot be re-enabled. [todo tested in ?]
EnableShadows <bool>
- See above keyvalues.
Ambient <float>
- Allows for an ambiance light, much like the shadow color for it.
SpotlightTexture <VTF/string>
- A VTF file (not VMT), relative to
/materials
.
These inputs are known to Hammer:
TurnOn
TurnOff
- Enable or disable the light.
FOV <float>
- See lightfov keyvalue above.
Parentname:
- SetParent <string >
- Move with this entity. See Entity Hierarchy (parenting).
- SetParentAttachment <string >
- Change this entity to attach to a specific attachment point on its parent. The entity will teleport so that the position of its root bone matches that of the attachment. Entities must be parented before being sent this input.
- SetParentAttachmentMaintainOffset <string >
- As above, but without teleporting. The entity retains its position relative to the attachment at the time of the input being received.
- ClearParent
- Removes this entity from the the movement hierarchy, leaving it free to move independently.