KDScriptRendering effects


This script works only with NewDark version 1.20 or later. With NewDark 1.19, which does not support zone-based environment maps, it only writes an error to the monolog.

ParameterTypeDescriptionDefault value
env_zoneintegerzone to change the texture for (063)0 (global)
env_map_onstringenvironment map texture to apply when turned on
env_map_offstringenvironment map texture to apply when turned off

When triggered, KDTrapEnvMap changes the texture associated with an environment zone. If the env_zone parameter is 0, the global texture is changed. (The default textures, both global and per zone, are defined in the Mission Variables → Environment Maps dialog. See the NewDark documentation for more details on environment maps and reflective materials.)

When turned on, this script sets the texture for the specified zone to the value of the env_map_on parameter, if defined. When turned off, this script sets the texture to the value of env_map_off, if defined. Values should be specified as relative paths, e.g. tex\envmaps\hallway. The usual trap control flags, locking, and timing are respected.

This script is part of the KDScript module. Copyright © 2012–2013 Kevin Daughtridge. See introduction for details.