Lights.rad: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (fixup)
(rewrote it to compact and concise it)
 
(15 intermediate revisions by 6 users not shown)
Line 1: Line 1:
= Overview =
{{disambig}}
'''Lights.rad''', is a file that specifies the color, and Brightness values for materials that can cast and receive Light. This applies to Materials that are of any shader. A lights.rad file already exists within a normal Game directory, however it is possible to make your own.


However these are the current Shaders most ''commonly'' used to cast Light:
{{file|lights|rad}} is a [[RAD file]] which is always automatically read by the lighting compilers. This is used to create texlights. In this file is a texture then an RGB value followed by a brightness value.


* [[LightmappedGeneric]]
* For creation and use of <code>lights.rad</code> file, see the [[RAD file]] page.
* [[UnlitGeneric]]
* For a list of {{src|4.1}} games' <code>lights.rad</code> file, see the [[:Category:Source RAD files]] page.
* For a list of {{goldsrc|4.1}} games' <code>lights.rad</code> file, see the [[:Category:GoldSrc RAD files]] page.


A lights.rad file can be edited with any preferred text editor, and most commonly looks like this:
[[Category:RAD]]
 
lights/white001 250 240 205 100
lights/white002 189 233 247 425
lights/white003 232 246 190 350
lights/white004 170 228 247 425
lights/white005 234 235 220 375
lights/white006 234 235 220 100
 
Aside that, the file can also specify other parameters beside lighting values. It can also tell [[Vrad | VRAD]] to ignore lighting on certain materials, or to calculate shadows based on a Textures [[Alpha]] channel.
 
:The below command tells VRAD to skip shadows casted on this material. Therefore shadows will not be calculated on this material.
noshadow tree_deciduous_01a_branches.vmt
 
This command, however tells VRAD to calculate shadows based on a [[model]]s Texture. More importantly on the textures within the Model that contain an Alpha channel.
 
forcetextureshadow props_wasteland/interior_fence001a.mdl
 
= See Also =
* [[ Vrad | VRAD]]
* [http://developer.valvesoftware.com/wiki/Category:List_of_Shaders List of Shaders]
* [[Creating a Material]]

Latest revision as of 12:57, 6 August 2025

Icon-disambig.png
This is a disambiguation page, a list of pages that otherwise might share the same title.
If an article link referred you to this title, you might want to go back and fix it to point directly to the intended page.

🖿lights.rad is a RAD file which is always automatically read by the lighting compilers. This is used to create texlights. In this file is a texture then an RGB value followed by a brightness value.