DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
EffCloudDust.c
См. документацию.
2{
4 {
6 }
7
8 void SetDefault()
9 {
10 int particleID = ParticleList.DUST_CLOUD;
11
12 if (!m_EffectSound)
13 {
14 EffectSound effectSound = SEffectManager.CreateSound("DustWindGust_SoundSet", vector.Zero, 3, 3, true);
15 SetEffectSound(effectSound);
16 }
17
18 if (m_ParticleID != particleID)
19 {
20 if (particleID != 0)
21 {
22 SetParticleState(particleID);
23 }
24 else
25 {
26 Stop();
27 }
28 }
29 }
30
31 override void SelectFromSurface(SurfaceInfo surfaceInfo)
32 {
33 int particleID = surfaceInfo.GetCloudEffectParticleId();
34 string soundSet = surfaceInfo.GetCloudEffectSoundSetName();
35 EffectSound effectSound = null;
36
37 if (soundSet != "")
38 {
39 if (m_EffectSound == null || m_EffectSound.GetSoundSet() != soundSet)
40 {
41 effectSound = SEffectManager.CreateSound(soundSet, vector.Zero, 3, 3, true);
42 SetEffectSound(effectSound);
43 }
44 }
45 else
46 {
47 if (m_EffectSound)
48 {
49 SetEffectSound(null);
50 }
51 }
52
53 if (m_ParticleID != particleID)
54 {
55 if (particleID != 0)
56 {
57 SetParticleState(particleID);
58 }
59 else
60 {
61 Stop();
62 }
63 }
64 }
65
66 override void SetParticleState( int state )
67 {
68 bool wasPlaying = IsPlaying();
69
70 Stop();
71 SetParticleID(state);
72
73 if (wasPlaying)
74 Start(); // resume effect
75 }
76}
bool IsPlaying()
Returns true when the Effect is playing, false otherwise.
Определения Effect.c:197
void EffCloudDust()
Определения EffCloudDust.c:3
override void SelectFromSurface(SurfaceInfo surfaceInfo)
Определения EffCloudDust.c:31
override void SetParticleState(int state)
Определения EffCloudDust.c:66
void SetDefault()
Определения EffCloudDust.c:8
override void Stop()
Stops all elements this effect consists of.
Определения EffectParticle.c:224
override void Start()
Plays all elements this effect consists of.
Определения EffectParticle.c:185
void SetParticleID(int id)
Sets the id of the particle to be used.
Определения EffectParticle.c:327
void DisableParticleInUI(bool disable)
Disable creating particle for preview player.
Определения EffectParticle.c:569
void EffectParticle()
ctor
Определения EffectParticle.c:36
EffectSound m_EffectSound
Name of sound set that is going to be played when particle starts playback.
Определения EffectParticle.c:18
int m_ParticleID
The ID in the ParticleList to create Particle from.
Определения EffectParticle.c:14
void SetEffectSound(EffectSound effectSound)
Set effect sound play with particle.
Определения EffectParticle.c:599
Wrapper class for managing sound through SEffectManager.
Определения EffectSound.c:5
static const int DUST_CLOUD
Определения ParticleList.c:406
Определения ParticleList.c:12
static EffectSound CreateSound(string sound_set, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false, bool enviroment=false)
Create an EffectSound.
Определения EffectManager.c:153
Manager class for managing Effect (EffectParticle, EffectSound)
Определения EffectManager.c:6
proto int GetCloudEffectParticleId()
proto string GetCloudEffectSoundSetName()
Определения SurfaceInfo.c:9
static const vector Zero
Определения EnConvert.c:123
Определения EnConvert.c:119