mirror of
https://github.com/celisej567/Fake-CSM-Mapbase.git
synced 2025-12-31 21:48:38 +03:00
I find out that the alpha of the color doesnt work correctly, so i add a Brightness Scale Keyvalue and csm_brightness_general ConVar for this. When you set Brightness Scale, csm_brightness_general uses this value. If you want to change brightness In-Game, you can use Console or for mappes they can use point_clientcommand to change csm_brightness_general.
53 lines
2.7 KiB
Plaintext
53 lines
2.7 KiB
Plaintext
|
|
@include "halflife2.fgd"
|
|
|
|
@PointClass base(Targetname, Parentname, Angles) studio("models/editor/cone_helper.mdl") frustum(lightfov,nearz,farz,lightcolor,-1) = env_cascade_light :
|
|
"An entity to control the sunlight that casts cascaded shadows in the map."
|
|
[
|
|
spawnflags(flags) =
|
|
[
|
|
1 : "Enabled" : 1
|
|
]
|
|
lightcolor(color255) : "Light Color" : "255 255 255 200" : "Light Color RGB-Intensity"
|
|
brightnessscale(float) : "Brightness Scale" : "1" : "ConVar csm_brightness_general = this parameter. You change this parameter - game changes csm_brightness_general to this value. Want to change brightness using inputs - use point_servercommand and change csm_brightness_general itself."
|
|
cameraspace(integer) : "Camera Space" : 0 : "Angles are interpreted as being relative to camera."
|
|
|
|
uselightenvangles(Choices) : "Use light_environment's angles" : 1 : "If true, the CSM shadow angles are automatically harvested from the light_environment's angles. If false, this entity's angles are used." =
|
|
[
|
|
1 : "Yes"
|
|
0 : "No"
|
|
]
|
|
|
|
enablethird(Choices) : "Enable Third level?" : 1 : "Enable Third CSM level? CSM will effect at more distance but its more expensive." =
|
|
[
|
|
1 : "Yes"
|
|
0 : "No"
|
|
]
|
|
|
|
|
|
ambient(integer) :"Ambient" : 0 : "[DOESNT WORK] Ambient of the light. I know how to make it work, but i will do it later."
|
|
|
|
input Enable(void) : "Turn on the texture"
|
|
input Disable(void) : "Turn off the texture"
|
|
input EnableShadows(bool) : "Turn off the shadows"
|
|
input Texture(string) : "Change texture"
|
|
input LightColor(color255) : "Set the light color."
|
|
input SetAngles(string) : "Set the sun direction."
|
|
input AddAngles(string) : "Add angle for the sun"
|
|
input ResetAngles(void) : "Reset angle of the sun"
|
|
]
|
|
|
|
@PointClass base(Angles) iconsprite("editor/light_env.vmt") = light_environment :
|
|
"Sets the color and angle of the light from the sun and sky."
|
|
[
|
|
targetname(string) : "Name"
|
|
pitch(integer) : "Pitch" : 0 : "The downward pitch of the light from the sun. 0 is horizontal, -90 is straight down."
|
|
_light(color255) : "Brightness" : "255 255 255 200"
|
|
_ambient(color255) : "Ambient" : "255 255 255 20"
|
|
_lightHDR(color255) : "BrightnessHDR" : "-1 -1 -1 1"
|
|
_lightscaleHDR(float) : "BrightnessScaleHDR" : "1" : "Amount to scale the light by when compiling for HDR."
|
|
_ambientHDR(color255) : "AmbientHDR" : "-1 -1 -1 1"
|
|
_AmbientScaleHDR(float) : "AmbientScaleHDR" : "1" : "Amount to scale the ambient light by when compiling for hdr."
|
|
pitch(integer) : "Pitch" : 0 : "The downward pitch of the light from the sun. 0 is horizontal, -90 is straight down."
|
|
SunSpreadAngle(float) : "SunSpreadAngle" : 0 : "The angular extent of the sun for casting soft shadows. Higher numbers are more diffuse. 5 is a good starting value."
|
|
] |