DayZ
1.24
Loading...
Searching...
No Matches
UniversallightLight.c
Go to the documentation of this file.
1
class
UniversallightLight
extends
SpotLightBase
2
{
3
private
static
float
m_DefaultBrightness
= 6.05;
4
private
static
float
m_DefaultRadius
= 25;
5
private
static
float
m_DefaultAngle = 100;
6
7
void
UniversallightLight
()
8
{
9
SetVisibleDuringDaylight(
true
);
10
SetRadiusTo(
m_DefaultRadius
);
11
SetSpotLightAngle(m_DefaultAngle);
12
SetCastShadow(
true
);
13
SetBrightnessTo(
m_DefaultBrightness
);
14
SetFadeOutTime(0.15);
15
SetAmbientColor(0.95, 0.88, 0.8);
16
SetDiffuseColor(0.95, 0.88, 0.8);
17
SetDisableShadowsWithinRadius(1.2);
18
}
19
20
void
SetIntensity
(
float
coef,
float
time
)
21
{
22
FadeBrightnessTo(
m_DefaultBrightness
* coef,
time
);
23
FadeRadiusTo(
m_DefaultRadius
* coef,
time
);
24
}
25
26
override
void
UpdateLightMode
(
string
slotName
)
27
{
28
switch
(
slotName
)
29
{
30
case
"weaponFlashlight"
:
31
SetSpotLightAngle(m_DefaultAngle / 2);
32
SetRadiusTo(
m_DefaultRadius
* 1.8);
33
break
;
34
35
default
:
36
SetSpotLightAngle(m_DefaultAngle);
37
SetRadiusTo(
m_DefaultRadius
);
38
break
;
39
}
40
}
41
}
slotName
PlayerSpawnPreset slotName
m_DefaultRadius
float m_DefaultRadius
Definition
ContaminatedArea_Dynamic.c:14
m_DefaultBrightness
enum eAreaDecayStage m_DefaultBrightness
Param3
Definition
EntityAI.c:95
SpotLightBase
Definition
CarLightBase.c:2
SpotLightBase::UniversallightLight
void UniversallightLight()
Definition
UniversallightLight.c:7
SpotLightBase::SetIntensity
void SetIntensity(float coef, float time)
Definition
UniversallightLight.c:20
SpotLightBase::UpdateLightMode
override void UpdateLightMode(string slotName)
Definition
UniversallightLight.c:26
scripts
4_World
Entities
ScriptedLightBase
SpotLightBase
UniversallightLight.c
Generated by
1.10.0