env_render Last edited 4 months ago2024-08-06 16:21:29 UTC

You are viewing an older revision of this wiki page. The current revision may be more detailed and up-to-date. Click here to see the current revision of this page.

env_render - Point Entity

The env_render entity allows you to change the rendering properties of most of the visible entities in the game (monsters, func_walls etc.), while the map is running. The four render properties of the env_render will be copied to its target. Exactly how different entities are affected by different render properties varies, so only general information about them will be provided below. If you require more specific information, check the entity guide page for the entity you want to alter.

Attributes

Flags

Notes

From the VERC Archive

Usage

The simplest example involves creating a crate that you make disappear -
  1. Create a crate (func_wall) and give it a Name (targetname) of crate1.
  2. Place an env_render in your level, near the crate. Give it a Name of crate1_render. Set its target to crate1. Set its render mode to 'texture' (2), and its fx amount to '0'.
  3. Create a func_button and set its target to crate1_render.
When the button gets pressed, the crate disappears. Note that you could use a multi_manager and a string of env_render entities to make the crate gradually fade out of existence rather than disappear suddenly.

This effect is useful for creating the illusion of entities that are bound together in some impossible way (at least for the engine). For example, if you wanted a tank to drive onto a field then start firing, that would seem to imply a func_train (for the movement) and a func_tank (for the firing) being bound together. Instead, the func_tank was always sitting on the field, but it started invisible. When the func_train drove out to the func_tank position, two things happen - the func_train is triggered invisible (as the above crate example), and the func_tank is triggered to be visible.

Note: in the above example with the tanks, its important to restrict the player from interacting with the "invisible tank" as this would ruin any sense of illusion that has been created.

Relationship by model type

The following are tables of how render properties interact with each other.

Brush model (brush entity)

Render Mode Render Amount Render Color Bullet decal Lightmap Alpha Transparency
Normal (0) Scroll speed Solid Black, opaque
Color (1) Opacity Colour None N/A
Texture (2) Opacity Scroll speed Glass Transparent
Glow (3) Opacity Scroll speed Glass Transparent
Solid (4) Fully opaque if >0 Scroll speed None Transparent
Additive (5) Opacity Scroll speed Glass Transparent
Notes:
  • In color mode, the entity will be of a pure colour as set in FX Color on screen with opacity as in FX amount. All other features – decals, lightmaps, textures – are removed.
  • Bullet decals are determined based on render mode at time of impact and remains unchanged as the mode changes.
  • Solid mode will have no decal whatsoever; even existing decals will be removed if the mode is changed to solid.
  • Render Color encodes scroll speed for faces with scroll* textures. See func_conveyor page for more info. Otherwise it has no other effect in non-color mode.
  • In modes that don't apply lightmaps, VHLT supports zhlt_embedlightmap property which bakes the lightmaps onto the individual face's textures. See Tutorial: The Complete Guide to Lighting, Section 3.8 for more info.
Render FX Normal Color Texture Glow Solid Additive
Normal (0) N/A N/A N/A N/A N/A N/A
Pulse effects (1-4)
Fade effects (5-6)
Solid effects (7-8)
Strobe effects (9-11)
Flicker effects (12-13)
Constant Glow (14)
Distort (15)
Hologram (16)
Bulge Sideways (18)
Glow shell (19)

Studio model

Render Mode Render Amount Render Color
Normal (0)
Color (1) Opacity
Texture (2) Opacity
Glow (3) Opacity
Solid (4) Opacity
Additive (5) Opacity
For all intents and purposes, modes Color through Solid (1-4) renders identically on models.
Render FX Normal Color Texture Glow Solid Additive Remarks
Normal (0) N/A N/A N/A N/A N/A N/A
Pulse effects (1-4)
Fade effects (5-6)
Solid effects (7-8)
Strobe effects (9-11)
Flicker effects (12-13)
Constant Glow (14)
Distort (15) ✔* ✔* ✔* ✔* ✔* [Note 1]
Hologram (16) ✔* ✔* ✔* ✔* ✔* [Note 1]
Bulge Sideways (18) [Note 2]
Glow shell (19) ✔* ✔* ✔* ✔* ✔* [Note 3]
Notes:
  1. Modes other than normal has additional opacity distortions.
  2. Loops (frozen entities are stuck in wide mode).
  3. FX Amount also controls offset of glow aura from model, clashing with non-normal render modes.

Sprites

Render Mode Render Amount Render Color Black part of additive sprites
Normal (0) No effect Tint colour Opaque
Color (1) Fully opaque if >0 No effect Opaque
Texture (2) Opacity Tint colour Opaque
Glow (3) Opacity Tint colour Transparent
Solid (4) Opacity Tint colour Opaque
Additive (5) Opacity Tint colour Transparent
Considering most sprites are additive type, only Additive (or Glow) modes should be considered in typical use cases.
Render FX Normal Color Texture Glow Solid Additive Remarks
Normal (0) N/A N/A N/A N/A N/A N/A
Pulse effects (1-4)
Fade effects (5-6)
Solid effects (7-8)
Strobe effects (9-11)
Flicker effects (12-13)
Constant Glow (14) [Note 1]
Distort (15)
Hologram (16)
Bulge Sideways (18)
Glow shell (19)
Notes:
  1. Cancels out glow mode's distance-based dissipation effect. No special effects otherwise.

Example maps

Loading embedded content: Vault Item #6933

Comments

You must log in to post a comment. You can login or register a new account.