DayZ
1.24
Loading...
Searching...
No Matches
ChristmasTree.c
Go to the documentation of this file.
1
class
ChristmasTree
extends
House
2
{
3
XmasTreeLight
m_TreeLight
;
4
EffectSound
m_AmbientSoundLoop
;
5
const
string
LOOP_SOUND =
"ChristmasMusic_SoundSet"
;
6
7
void
ChristmasTree
()
8
{
9
if
(!
GetGame
().IsDedicatedServer())
10
{
11
m_TreeLight = XmasTreeLight.Cast(
ScriptedLightBase
.CreateLight(XmasTreeLight,
"0 0 0"
));
12
m_TreeLight.AttachOnMemoryPoint(
this
,
"action"
);
13
}
14
}
15
16
override
void
EEInit
()
17
{
18
if
(!
GetGame
().IsDedicatedServer())
19
PlaySoundSetLoop(m_AmbientSoundLoop, LOOP_SOUND, 0, 0);
20
}
21
22
override
void
EEDelete
(
EntityAI
parent)
23
{
24
if
(!
GetGame
().IsDedicatedServer())
25
{
26
if
(m_TreeLight)
27
m_TreeLight.Destroy();
28
if
(m_AmbientSoundLoop)
29
SEffectManager
.
DestroyEffect
(m_AmbientSoundLoop);
30
}
31
}
32
};
33
class
ChristmasTree_Green
extends
ChristmasTree
{};
ChristmasTree
Definition
ChristmasTree.c:33
EffectSound
Wrapper class for managing sound through SEffectManager.
Definition
EffectSound.c:5
EntityAI
Definition
Building.c:6
House
Definition
CrashBase.c:2
House::EEInit
override void EEInit()
Definition
ChristmasTree.c:16
House::m_AmbientSoundLoop
EffectSound m_AmbientSoundLoop
Definition
ChristmasTree.c:4
House::m_TreeLight
XmasTreeLight m_TreeLight
Definition
ChristmasTree.c:3
House::EEDelete
override void EEDelete(EntityAI parent)
Definition
ChristmasTree.c:22
House::ChristmasTree
void ChristmasTree()
Definition
ChristmasTree.c:7
Param3
Definition
EntityAI.c:95
SEffectManager
Manager class for managing Effect (EffectParticle, EffectSound)
Definition
EffectManager.c:6
SEffectManager::DestroyEffect
static void DestroyEffect(Effect effect)
Unregisters, stops and frees the Effect.
Definition
EffectManager.c:256
ScriptedLightBase
Definition
PointLightBase.c:2
GetGame
proto native CGame GetGame()
scripts
4_World
Entities
WoodBase
ChristmasTree.c
Generated by
1.10.0