DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
CrashBase.c
См. документацию.
1class CrashBase extends House
2{
4 static bool m_Init = Init();
5
6 static bool Init()
7 {
8 CrashSoundSets.RegisterSoundSet("HeliCrash_Distant_SoundSet");
9 CrashSoundSets.RegisterSoundSet("SledgeCrash_Distant_SoundSet");
10 CrashSoundSets.RegisterSoundSet("HeliCrash_big_SoundSet");
11 CrashSoundSets.RegisterSoundSet("HeliCrash_big_no_explosions_SoundSet");
12 return true;
13 }
14
15 override void EEOnCECreate()
16 {
17 super.EEOnCECreate();
19 }
20
22 {
23 Param3<bool, vector, int> playSound = new Param3<bool, vector, int>(true, GetPosition(), GetSoundSet().Hash());
24 g_Game.RPCSingleParam( null, ERPCs.RPC_SOUND_HELICRASH, playSound, true );
25 }
26
27 // needs to have the soundset registered in CrashBase.Init()
28 string GetSoundSet()
29 {
30 return "HeliCrash_Distant_SoundSet";
31 }
32
33 override void EEInit()
34 {
35 super.EEInit();
36 //Setup for local sound tests
37 #ifdef DEVELOPER
38 if ( !g_Game.IsMultiplayer() )
39 {
41 eff.SetAutodestroy(true);
42 }
43 #endif
44 }
45
46 override void EEDelete(EntityAI parent)
47 {
48 if ( !g_Game.IsHeadlessOrDedicatedServer() )
49 {
50 if ( m_ParticleEfx )
51 m_ParticleEfx.Stop();
52 }
53 }
54};
DayZGame g_Game
Определения DayZGame.c:4074
override Widget Init()
Определения DayZGame.c:127
ERPCs
Определения ERPCs.c:2
override string GetSoundSet()
Определения Wreck_Chinook.c:11
Определения Wreck_Chinook.c:2
static void RegisterSoundSet(string sound_set)
Определения DayZGame.c:48
Определения DayZGame.c:45
override void SetAutodestroy(bool auto_destroy)
Sets whether Effect automatically cleans up when it stops.
Определения EffectSound.c:607
Wrapper class for managing sound through SEffectManager.
Определения EffectSound.c:5
override void EEInit()
Определения CrashBase.c:33
void RequestSoundEvent()
Определения CrashBase.c:21
override void EEOnCECreate()
Определения CrashBase.c:15
static bool Init()
Определения CrashBase.c:6
override void EEDelete(EntityAI parent)
Определения CrashBase.c:46
static bool m_Init
Определения CrashBase.c:4
Particle m_ParticleEfx
Определения CrashBase.c:3
string GetSoundSet()
Определения CrashBase.c:28
Legacy way of using particles in the game.
Определения Particle.c:7
static EffectSound PlaySound(string sound_set, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound.
Определения EffectManager.c:178
Manager class for managing Effect (EffectParticle, EffectSound)
Определения EffectManager.c:6
vector GetPosition()
Get the world position of the Effect.
Определения Effect.c:473