This shows you the differences between two versions of the page.
ded:light [2017-03-16 07:18] – skyjake | ded:light [2017-03-16 07:18] (current) – skyjake | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Light (DED) ====== | ||
+ | |||
+ | A //Light// definition is used to attach a light and/or halo to a [[sprite]]' | ||
+ | |||
+ | If you want to attach a light to a texture or flat please check the section on texture [[decoration]]s as the method used for that is slightly different. | ||
+ | |||
+ | |||
+ | ===== Details ===== | ||
+ | |||
+ | |||
+ | Doomsday is also able to use lightmaps in place of the standard light texture, this makes it possible to limit the directions an object casts light in, or to do fancy effects like flickering fire. | ||
+ | |||
+ | To attach a light to [[modding: | ||
+ | |||
+ | < | ||
+ | |||
+ | |||
+ | ===== Syntax ===== | ||
+ | |||
+ | | ||
+ | < | ||
+ | { | ||
+ | # If " | ||
+ | # copied to this one as defaults. For the first definition in a | ||
+ | # file " | ||
+ | | ||
+ | Red = 0.0 | ||
+ | # Red color component (0-1). | ||
+ | | ||
+ | Green = 0.0 | ||
+ | # Green color component (0-1). | ||
+ | | ||
+ | Blue = 0.0 | ||
+ | # Blue color component (0-1). | ||
+ | | ||
+ | Color { 0.0 0.0 0.0 } | ||
+ | # Sets all three color components at the same time. | ||
+ | | ||
+ | # Dynamic Light only: | ||
+ | # The following settings are only available with dynamic lights | ||
+ | | ||
+ | State = "" | ||
+ | # The State with which the light properties defined here will | ||
+ | # be used. | ||
+ | | ||
+ | Flags = flaga | flagb | flagc etc... | ||
+ | # nohalo: No lens flare (halo) is rendered. | ||
+ | # dontturnhalo: | ||
+ | # | ||
+ | | ||
+ | X Offset = 0.0 | ||
+ | # In pixels, offset from the center of the source. The offset | ||
+ | # is parallel with the view plane. Negative values shift the | ||
+ | # source leftward, while positive values move the source to the right. | ||
+ | | ||
+ | Y Offset = 0.0 | ||
+ | # In pixels, offset from the top of the source object. | ||
+ | # A negative value will move the source upward and | ||
+ | # and a positive value moves the source downward. | ||
+ | | ||
+ | Size = 0.0 | ||
+ | # Size (strength) of the light. Should be between 0 and 1. | ||
+ | | ||
+ | Halo radius = 0.0 | ||
+ | # New as of 1.9.0-beta6. | ||
+ | # Radius of the halo. Zero means no halo is rendered. Note | ||
+ | # that halo radius 1.0 produces quite a large flare. | ||
+ | | ||
+ | Flare map = "" | ||
+ | # New as of 1.9.0-beta6. | ||
+ | # Name of the flare map to use OR a built-in flare texture id to use for the primary flare (i.e. the halo itself). | ||
+ | # Eg: | ||
+ | # Flare map = " | ||
+ | # Flare map = " | ||
+ | | ||
+ | # Built-in flare texture ids: | ||
+ | # 0 = Texture chosen automatically. | ||
+ | # 1 = Default dynamic light texture. | ||
+ | # 2 = FLARE. | ||
+ | # 3 = BRFLARE. | ||
+ | # 4 = BIGFLARE. | ||
+ | | ||
+ | Top map = "" | ||
+ | Bottom map = "" | ||
+ | Side map = "" | ||
+ | # Name of the light map to use. The top map is used for ceiling | ||
+ | # planes, the bottom map for floors and the side map for walls. | ||
+ | # If left blank (the default), the standard round dynlight texture | ||
+ | # is used. Use " | ||
+ | # cast in the direction. | ||
+ | | ||
+ | # BIAS source only: | ||
+ | # The following settings are only available with BIAS sources | ||
+ | | ||
+ | Map = mapid|game|pwad/ | ||
+ | eg = " | ||
+ | # Indicates that this is a bias light source and not a dynamic | ||
+ | # light. This tells doomsday which map the bias source is for | ||
+ | | ||
+ | Origin { 0.0 0.0 0.0 } | ||
+ | # The location of the bias source in the map (X Y Z) | ||
+ | | ||
+ | Intensity = 200 | ||
+ | # How bright the bias light source is. | ||
+ | | ||
+ | Sector levels { 0 0 } | ||
+ | # The light levels at which the source is fully " | ||
+ | # eg if { 80 200 } would mean the light is off if the sector | ||
+ | # light is lower than 80 and gradualy increases to full brightness | ||
+ | # untill the sector light is 200 at which point it is fully " | ||
+ | # Values can also be inversed so that the light is fully on when | ||
+ | # the sector light is eg 40 and fully off at 255 | ||
+ | } | ||
+ | |||
+ | |||
+ | |||