Dayz Explorer 1.28.160049
Loading...
Searching...
No Matches
chemlightlight.c
Go to the documentation of this file.
1class ChemlightLight extends PointLightBase
2{
3 private static float m_DefaultBrightness = 1.5;
4 private static float m_DefaultRadius = 7.5;
5
6 void ChemlightLight()
7 {
8 SetVisibleDuringDaylight(false);
9 SetRadiusTo(m_DefaultRadius);
10 SetBrightnessTo(m_DefaultBrightness);
11 FadeIn(1);
12 SetFadeOutTime(2);
13 SetFlareVisible(false);
14 }
15
16 void SetIntensity( float coef, float time )
17 {
18 FadeBrightnessTo(m_DefaultBrightness * coef, time);
19 FadeRadiusTo(m_DefaultRadius * coef, time);
20 }
21
22 void SetColorToWhite()
23 {
24 SetAmbientColor(0.9, 0.9, 1.0);
25 SetDiffuseColor(0.9, 0.9, 1.0);
26 }
27
28 void SetColorToRed()
29 {
30 SetAmbientColor(1.0, 0.3, 0.2);
31 SetDiffuseColor(1.0, 0.3, 0.2);
32 }
33
34 void SetColorToGreen()
35 {
36 SetAmbientColor(0.3, 1.0, 0.2);
37 SetDiffuseColor(0.3, 1.0, 0.2);
38 }
39
40 void SetColorToBlue()
41 {
42 SetAmbientColor(0.3, 0.3, 1.0);
43 SetDiffuseColor(0.3, 0.3, 1.0);
44 }
45
46 void SetColorToYellow()
47 {
48 SetAmbientColor(1.0, 1.0, 0.3);
49 SetDiffuseColor(1.0, 1.0, 0.3);
50 }
51}
float m_DefaultRadius
enum EGrenadeType m_DefaultBrightness
For backward compatibility.