Env sprite: Difference between revisions
Jump to navigation
Jump to search
Note:When choosing a sprite from the sprite browser, the name it provides does not contain the required
Note:The sprite preview doesn't display sprites at the right scale. The sprite preview scale is preset to
(Worte some stuff about the missing file extention, sprite axis (non-)control, and the scale preview bug.) |
Needles-Kane (talk | contribs) mNo edit summary |
||
Line 2: | Line 2: | ||
==Entity Description== | ==Entity Description== | ||
An entity that controls the drawing of a sprite in the world. | An entity that controls the drawing of a sprite in the world. For instance, it can be used to add a glowing effect to light sources. | ||
Note that the only rendering modes (set by its ''rendermode'' keyvalue) that can render a sprite properly, | Note that the only rendering modes (set by its ''rendermode'' keyvalue) that can render a sprite properly, are ''Glow'', ''Additive'', ''Additive Fractional Frame'' and ''World Space Glow''. See [[Render Modes]] for more info. | ||
Sprites will always be displayed as facing the player, but they can be displayed as rotating around all axis (as glow sprites), or as being locked to rotate around the Z axis only (as fire sprites). These two forms of axis control | Sprites will always be displayed as facing the player, but they can be displayed as rotating around all axis (as glow sprites), or as being locked to rotate around the Z axis only (as fire sprites). These two forms of axis control are built into the sprite itself, and cannot be changed in Hammer. | ||
==Keyvalues== | ==Keyvalues== |
Revision as of 13:05, 19 December 2006
Entity Description
An entity that controls the drawing of a sprite in the world. For instance, it can be used to add a glowing effect to light sources.
Note that the only rendering modes (set by its rendermode keyvalue) that can render a sprite properly, are Glow, Additive, Additive Fractional Frame and World Space Glow. See Render Modes for more info.
Sprites will always be displayed as facing the player, but they can be displayed as rotating around all axis (as glow sprites), or as being locked to rotate around the Z axis only (as fire sprites). These two forms of axis control are built into the sprite itself, and cannot be changed in Hammer.
Keyvalues
- Template:Kv targetname
- Template:Kv parentname
- Template:Kv renderfields
- Template:Kv dxlevelchoice
- Template:Kv hdrcolorscale
- framerate
- <float> Rate at which the sprite should animate, if at all.
- model
- <sprite> Material of the sprite to be drawn.

.spr
/.vmt
file extention. While the sprite preview can find the sprite, the extention needs to be typed in by hand for the engine to be able to find the sprite in-game.- scale
- <float> Scale multiplier of the sprite.

0.25
, while sprite scale in-game is preset to 1
. To correct the preview scale, set this keyvalue (to any value).- GlowProxySize
- <float> Size of the glow to be rendered for visibility testing. Must be larger than the distance from the sprite center to empty space. So if this glow is inside geometry (like a light bulb), set this value to be bigger than the bulb's radius. Any time a sphere of this radius would be visible (poking through any nearby geometry), the glow will be rendered.
Flags
- 1 : Start on
- 2 : Play Once
Inputs
- Template:I targetname
- Template:I renderfields
- Template:I parentname
- SetScale <float>
- Set the scale.
- HideSprite
- Hide the sprite. Won't be drawn until the 'ShowSprite' input is received.
- ShowSprite
- Show the sprite.
- ToggleSprite
- Toggle the sprite between hidden and shown.