DayZ
1.24
Loading...
Searching...
No Matches
AnniversarySpotLight.c
Go to the documentation of this file.
1
class
AnniversarySpotLight
: Building
2
{
3
#ifndef SERVER
4
protected
AnniversaryMainLight
m_Light
;
5
#endif
6
7
protected
bool
m_LightState
;
8
9
void
AnniversarySpotLight
()
10
{
11
RegisterNetSyncVariableBool(
"m_LightState"
);
12
}
13
14
override
void
OnVariablesSynchronized
()
15
{
16
super
.OnVariablesSynchronized();
17
18
#ifndef SERVER
19
if
(
m_LightState
)
20
m_Light
=
AnniversaryMainLight
.Cast(
ScriptedLightBase
.CreateLight(
AnniversaryMainLight
,
GetPosition
()));
21
else
22
{
23
if
(
m_Light
)
24
m_Light
.FadeOut(0.5);
25
}
26
#endif
27
}
28
29
override
void
EEDelete
(
EntityAI
parent)
30
{
31
super
.EEDelete(parent);
32
33
#ifndef SERVER
34
if
(
m_Light
)
35
m_Light
.Destroy();
36
#endif
37
}
38
39
void
DeActivate
()
40
{
41
m_LightState
=
false
;
42
SetSynchDirty();
43
}
44
45
void
Activate
()
46
{
47
m_LightState
=
true
;
48
SetSynchDirty();
49
}
50
}
GetPosition
class JsonUndergroundAreaTriggerData GetPosition
Definition
UndergroundAreaLoader.c:9
AnniversaryMainLight
Definition
AnniversaryMainLight.c:2
AnniversarySpotLight
Definition
AnniversarySpotLight.c:2
AnniversarySpotLight::Activate
void Activate()
Definition
AnniversarySpotLight.c:45
AnniversarySpotLight::AnniversarySpotLight
void AnniversarySpotLight()
Definition
AnniversarySpotLight.c:9
AnniversarySpotLight::EEDelete
override void EEDelete(EntityAI parent)
Definition
AnniversarySpotLight.c:29
AnniversarySpotLight::DeActivate
void DeActivate()
Definition
AnniversarySpotLight.c:39
AnniversarySpotLight::m_LightState
bool m_LightState
Definition
AnniversarySpotLight.c:7
AnniversarySpotLight::OnVariablesSynchronized
override void OnVariablesSynchronized()
Definition
AnniversarySpotLight.c:14
AnniversarySpotLight::m_Light
AnniversaryMainLight m_Light
Definition
AnniversarySpotLight.c:4
EntityAI
Definition
Building.c:6
Param3
Definition
EntityAI.c:95
ScriptedLightBase
Definition
PointLightBase.c:2
scripts
4_World
Entities
Building
Specific
AnniversarySpotLight.c
Generated by
1.10.0