DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
EffectManager.c
См. документацию.
1
6{
8 protected static ref map<int, ref Effect> m_EffectsMap;
10 protected static ref array<int> m_FreeEffectIDs;
12 protected static int m_HighestFreeEffectID = 1;
14 static const int INVALID_ID = 0;
16 protected static bool m_IsCleanup;
18 protected static bool m_IsInitialized;
19
22
25
28 protected static ref array<int> m_FreeEffecterIDs;
29
30 protected static int m_HighestFreeEffecterID = 1;
31
37
47 static int PlayInWorld(notnull Effect eff, vector pos)
48 {
49 // Stop the effect first, just in case
50 eff.Stop();
51
52 int id = EffectRegister(eff);
53
54 eff.SetPosition( pos );
55 eff.Start();
56
57 return id;
58 }
59
70 static int PlayOnObject(notnull Effect eff, Object obj, vector local_pos = "0 0 0", vector local_ori = "0 0 0", bool force_rotation_relative_to_world = false)
71 {
72 // Stop the effect first, just in case
73 eff.Stop();
74
75 int id;
76
77 if (eff.IsRegistered())
78 {
79 id = eff.GetID();
80 }
81 else
82 {
83 id = EffectRegister(eff);
84 }
85
86 if (!obj)
87 {
88 ErrorEx("Parent object is null.", ErrorExSeverity.WARNING);
89 eff.SetPosition(local_pos);
90 }
91 else
92 {
93 eff.SetPosition(obj.GetPosition());
94 }
95
96 eff.SetParent(obj);
97 eff.SetLocalPosition(local_pos);
98 eff.SetAttachedLocalOri(local_ori);
99
100 if (force_rotation_relative_to_world)
101 {
102 EffectParticle eff_particle = EffectParticle.Cast(eff);
103
104 if (eff_particle)
105 {
106 eff_particle.ForceParticleRotationRelativeToWorld(force_rotation_relative_to_world);
107 }
108 }
109
110 eff.Start();
111
112 return id;
113 }
114
119 static void Stop(int effect_id)
120 {
121 Effect eff = m_EffectsMap.Get(effect_id);
122
123 if (eff)
124 {
125 eff.Stop();
126 }
127 else
128 {
129 ErrorEx(string.Format("Failed to stop Effect with ID %1. The ID is not registered in m_EffectsMap!", effect_id));
130 }
131 }
132
134
135
136
141
153 static EffectSound CreateSound(string sound_set, vector position, float play_fade_in = 0, float stop_fade_out = 0, bool loop = false, bool enviroment = false)
154 {
155 EffectSound effect_sound = new EffectSound();
156 effect_sound.SetSoundSet(sound_set);
157 effect_sound.SetPosition(position);
158 effect_sound.SetSoundFadeIn(play_fade_in);
159 effect_sound.SetSoundFadeOut(stop_fade_out);
160 effect_sound.SetSoundLoop(loop);
161 effect_sound.SetEnviromentVariables(enviroment);
162
163 EffectRegister( effect_sound );
164
165 return effect_sound;
166 }
167
178 static EffectSound PlaySound(string sound_set, vector position, float play_fade_in = 0, float stop_fade_out = 0, bool loop = false)
179 {
180 EffectSound effect_sound = CreateSound(sound_set, position, play_fade_in, stop_fade_out, loop, false);
181
182 effect_sound.SoundPlay();
183
184 return effect_sound;
185 }
186
197 static EffectSound PlaySoundParams(notnull SoundParams params, vector position, float play_fade_in = 0, float stop_fade_out = 0, bool loop = false)
198 {
199 EffectSound effect_sound = CreateSound(params.GetName(), position, play_fade_in, stop_fade_out, loop, false);
200
201 effect_sound.SoundPlayEx(params);
202
203 return effect_sound;
204 }
205
216 static EffectSound PlaySoundCachedParams(string sound_set, vector position, float play_fade_in = 0, float stop_fade_out = 0, bool loop = false)
217 {
218 SoundParams params = GetCachedSoundParam(sound_set);
219
220 EffectSound effect_sound = CreateSound(params.GetName(), position, play_fade_in, stop_fade_out, loop, false);
221
222 effect_sound.SoundPlayEx(params);
223
224 return effect_sound;
225 }
226
237 static EffectSound PlaySoundEnviroment(string sound_set, vector position, float play_fade_in = 0, float stop_fade_out = 0, bool loop = false)
238 {
239 EffectSound effect_sound = CreateSound(sound_set, position, play_fade_in, stop_fade_out, loop, true);
240
241 effect_sound.SoundPlay();
242
243 return effect_sound;
244 }
245
256 static EffectSound PlaySoundOnObject(string sound_set, Object parent_object, float play_fade_in = 0, float stop_fade_out = 0, bool loop = false)
257 {
258 EffectSound effect_sound = CreateSound(sound_set, parent_object.GetPosition(), play_fade_in, stop_fade_out, loop);
259
260 effect_sound.SetParent( parent_object );
261 effect_sound.SetLocalPosition( vector.Zero );
262 effect_sound.SoundPlay();
263
264 return effect_sound;
265 }
266
268
269
270
275
280 static void DestroyEffect(Effect effect)
281 {
282 if (effect)
283 {
284 if (effect.CanDestroy())
285 {
286 // Functionality already happens in dtor of Effect to be safe
287 delete effect;
288 }
289 else
290 {
291 // Make it clean up itself when done
292 effect.SetAutodestroy(true);
293 effect.Stop();
294 }
295 }
296 }
297
303 static bool IsEffectExist( int effect_id )
304 {
305 if (!m_IsCleanup)
306 return m_EffectsMap[effect_id] != null;
307 else
308 return false;
309 }
310
316 static Effect GetEffectByID(int effect_id)
317 {
318 if (!m_IsCleanup)
319 return m_EffectsMap[effect_id];
320 else
321 return null;
322 }
323
331 static int EffectRegister(Effect effect)
332 {
333 if (effect.IsRegistered())
334 {
335 ErrorEx(string.Format("Attempted to register Effect '%1' which was already registered.", effect.GetDebugName()), ErrorExSeverity.INFO);
336 return effect.GetID();
337 }
338
339 int id;
340
341 if (!m_IsCleanup)
342 {
343 id = GetFreeEffectID();
344 m_EffectsMap.Insert(id, effect);
345 effect.Event_OnRegistered(id);
346 }
347 else
348 ErrorEx("Attempted to register Effect while SEffectManager is cleaning up, request ignored.", ErrorExSeverity.WARNING);
349
350 return id;
351 }
352
353 protected static int GetFreeEffecterID()
354 {
355 int return_id;
356
357 if (m_FreeEffecterIDs.Count() > 0)
358 {
359 return_id = m_FreeEffecterIDs.Get(0);
360 m_FreeEffecterIDs.Remove(0);
361 }
362 else
363 {
364 return_id = m_HighestFreeEffecterID;
366 }
367
368 return return_id;
369 }
370
378 static void EffectUnregister(int id)
379 {
380 if (m_IsCleanup)
381 return; // No error needed, since it will have been unregistered anyways after cleanup is finished
382
383 Effect effect;
384 if ( m_EffectsMap.Find(id, effect) )
385 {
386 effect.Event_OnUnregistered();
387 m_EffectsMap.Remove(id);
388 }
389
390 if ( m_FreeEffectIDs.Find(id) == -1 )
391 {
392 m_FreeEffectIDs.Insert(id);
393 }
394 }
395
400 static void EffectUnregisterEx(Effect effect)
401 {
402 EffectUnregister(effect.GetID());
403 }
404
409 protected static int GetFreeEffectID()
410 {
411 int return_id;
412
413 if (m_FreeEffectIDs.Count() > 0)
414 {
415 return_id = m_FreeEffectIDs.Get(0);
416 m_FreeEffectIDs.Remove(0);
417 }
418 else
419 {
420 return_id = m_HighestFreeEffectID;
422 }
423
424 return return_id;
425 }
426
428
429
430
435
441 static bool DestroySound(EffectSound sound_effect)
442 {
443 DestroyEffect(sound_effect);
444 return true;
445 }
446
452 static SoundParams GetCachedSoundParam(string soundset)
453 {
454 SoundParams params;
455 if (!m_ParamsMap.Find(soundset, params))
456 {
457 params = new SoundParams(soundset);
458 m_ParamsMap.Insert(soundset, params);
459 }
460 return params;
461 }
462
464
465
466
471
477 static void Event_OnSoundWaveEnded(EffectSound effect_sound)
478 {
479
480 }
481
489 static void Event_OnFrameUpdate(float time_delta)
490 {
491 Event_OnFrameUpdate.Invoke(time_delta);
492 }
493
495
496
497
502
516
517 static void InitServer()
518 {
521 }
522
527 static void Cleanup()
528 {
529 // Nothing to clean
530 if (!m_IsInitialized)
531 return;
532
533 m_IsCleanup = true;
534
535 // There should not be anything in here on server
536 if (g_Game && g_Game.IsHeadlessOrDedicatedServer())
537 {
538 if (m_ParamsMap.Count() > 0)
539 ErrorEx(string.Format("SEffectManager containing SoundParams on server."), ErrorExSeverity.WARNING);
540
541 if (m_EffectsMap.Count() > 0)
542 ErrorEx(string.Format("SEffectManager containing Effect on server."), ErrorExSeverity.WARNING);
543 }
544
545 // These are intentionally cached, just clear them
546 m_ParamsMap.Clear();
547
548 // These might not be intentionally still here, so log how many there are
549 #ifdef DEVELOPER
550 Print("--- SEffectManager Cleanup dump - Begin ------------------------");
551 Print(string.Format("Effect count: %1", m_EffectsMap.Count()));
552 #endif
553
554 // Best to call the unregister event before clearing the map
555 // In case some ref is still being held elsewhere and will still be kept alive
556 foreach (int id, Effect eff : m_EffectsMap)
557 {
558 eff.Event_OnUnregistered();
559 #ifdef SFXM_DUMP
560 Print(string.Format( "%1 :: %2 :: %3", eff, typename.EnumToString(EffectType, eff.GetEffectType()), eff.GetDebugName() ));
561 #endif
562 }
563
564 foreach (int i, EffecterBase effecter : m_EffectersMap)
565 {
566 effecter.Delete();
567 }
568
569 #ifdef DEVELOPER
570 Print("--- SEffectManager Cleanup dump - End --------------------------");
571 #endif
572
573 // Now we can clear it
574 m_EffectsMap.Clear();
575 m_EffectersMap.Clear();
576
577 // Reset the state
579 Event_OnFrameUpdate.Clear();
580 m_IsCleanup = false;
581 }
582
584
587 {
588 EffecterBase eff;
589 eff = EffecterBase.Cast(g_Game.CreateObjectEx(parameters.m_EffecterType, pos, ECE_PLACE_ON_SURFACE));
590
591 if (eff)
592 {
593 int id = GetFreeEffecterID();
594 m_EffectersMap.Insert(id, eff);
595 }
596
597 eff.Init(id, parameters);
598 return id;
599 }
600
602 static void ReinitParticleServer(int effecterID, EffecterParameters parameters)
603 {
604 EffecterBase eff = m_EffectersMap.Get(effecterID);
605 if (eff)
606 {
607 eff.Init(effecterID,parameters);
608 }
609 }
610
611 static void ReactivateParticleServer(int effecterID)
612 {
613 EffecterBase eff = m_EffectersMap.Get(effecterID);
614 if (eff)
615 {
616 eff.Reactivate();
617 }
618 }
619
620 static void StartParticleServer(int effecterID)
621 {
622 EffecterBase eff = m_EffectersMap.Get(effecterID);
623 if (eff)
624 {
625 eff.Start();
626 }
627
628 }
629
630 static void StopParticleServer(int effecterID)
631 {
632 EffecterBase eff = m_EffectersMap.Get(effecterID);
633 if (eff)
634 {
635 eff.Stop();
636 }
637 }
638
639 static void DestroyEffecterParticleServer(int effecterID)
640 {
641 EffecterBase eff = m_EffectersMap.Get(effecterID);
642 if (eff)
643 {
644 m_EffectersMap.Remove(effecterID);
645 eff.DeleteSafe();
646 }
647 }
648
649 static EffecterBase GetEffecterByID(int effecterID)
650 {
651 return m_EffectersMap.Get(effecterID);
652 }
653
654 static void OnUpdate(float timeslice)
655 {
656 if (m_EffectersMap)
657 {
658 foreach (int i, EffecterBase effecter : m_EffectersMap)
659 {
660 effecter.DecreaseLifespan(timeslice);
661 }
662 }
663 }
664}
665
666enum EffecterCommands
667{
668 NONE = -1,
672 REACTIVATE1
673}
674
676{
679 void EffecterParameters(string type, float lifespan)
680 {
681 m_EffecterType = type;
682 m_Lifespan = lifespan;
683 }
684}
685
687{
689 void ParticleEffecterParameters(string type, float lifespan, int particleID)
690 {
691 m_ParticleID = particleID;
692 }
693}
694
695
697{
698 const float NOT_DEFINED_LIFESPAN = -1;
699 protected float m_Lifespan;
700 protected int m_ID;
701 protected int m_Command = EffecterCommands.NONE;
702 protected int m_CommandSync = EffecterCommands.NONE;
703
705 {
706 RegisterNetSyncVariableInt("m_CommandSync");
707 }
708
709 void Init(int id, EffecterParameters parameters)
710 {
711 m_ID = id;
712 SetLifespan(parameters.m_Lifespan);
713 }
714
715 void DecreaseLifespan(float timeSlice)
716 {
718 return;
719
720 m_Lifespan -= timeSlice;
721 if (m_Lifespan < 0)
722 {
724 }
725 }
726
727 void SetLifespan(float lifespan)
728 {
729 m_Lifespan = lifespan;
730 }
731
732 void Start()
733 {
734 m_CommandSync = EffecterCommands.START;
735 Process();
736 }
737
738 void Stop()
739 {
740 m_CommandSync = EffecterCommands.STOP;
741 Process();
742 }
743
745 {
746 if (m_CommandSync == EffecterCommands.REACTIVATE0)
747 {
748 m_CommandSync = EffecterCommands.REACTIVATE1;
749 }
750 else
751 {
752 m_CommandSync = EffecterCommands.REACTIVATE0;
753 }
754 Process();
755 }
756
757 void Process()
758 {
759 if (g_Game.IsMultiplayer())
760 {
761 SetSynchDirty();
762 }
763 else
764 {
766 }
767 }
768
769 override int GetHideIconMask()
770 {
771 return EInventoryIconVisibility.HIDE_VICINITY;
772 }
773}
774
776{
777 protected int m_ParticleEffectID = -1;
778 protected int m_ParticleEffectIDSync = -1;
779 protected ref EffectParticleGeneral m_Effect = null;
780 //protected int m_EffectID = -1;
781
782 void ParticleEffecter(int lifespan)
783 {
784 RegisterNetSyncVariableInt("m_ParticleEffectIDSync");
785 }
786
787 override void Init(int id, EffecterParameters parameters)
788 {
789 super.Init(id, parameters);
790
793 }
794
795 void SetParticle(int particleID)
796 {
797 m_ParticleEffectIDSync = particleID;
798 Process();
799 }
800
802 {
804 {
805 if (m_Effect)
806 {
807 m_Effect.SetParticle(m_ParticleEffectIDSync);
808 }
809 else
810 {
812 m_Effect.SetParticle(m_ParticleEffectIDSync);
813 SEffectManager.PlayInWorld(m_Effect, GetWorldPosition());
814 }
816 }
817
819 {
820 switch (m_CommandSync)
821 {
822 case EffecterCommands.START:
823 if (m_Effect && !m_Effect.IsPlaying())
824 {
825 m_Effect.SetParticle(m_ParticleEffectID);
826 m_Effect.Start();
827 }
828 break;
829
830 case EffecterCommands.STOP:
831 if (m_Effect && m_Effect.IsPlaying())
832 {
833 m_Effect.Stop();
834 }
835 break;
836
837 case EffecterCommands.REACTIVATE0:
838 case EffecterCommands.REACTIVATE1:
839 if (m_Effect)
840 {
841 m_Effect.SetParticle(m_ParticleEffectID);
842 }
843 if (!m_Effect.IsPlaying())
844 {
845 m_Effect.Start();
846 }
847 break;
848
849 default:
850 break;
851 }
852
854 }
855 }
856
857 protected typename GetEffectTypename()
858 {
860 }
861
866}
867
869{
872 {
873 }
874
875 void SetParticle( int particleID )
876 {
877 bool was_playing = IsPlaying();
878
879 Stop();
880
881 SetParticleID(particleID);
882
883 if (was_playing)
884 {
885 Start();
886 }
887 }
888
889 override void SetParticleID( int id )
890 {
891 super.SetParticleID(id);
892 m_LastParticleID = id;
893 }
894}
void Spawn()
spawn damage trigger
Определения AreaDamageManager.c:70
const int ECE_PLACE_ON_SURFACE
Определения CentralEconomy.c:38
override void OnVariablesSynchronized()
Определения ContaminatedArea_Dynamic.c:94
DayZGame g_Game
Определения DayZGame.c:4074
override Widget Init()
Определения DayZGame.c:127
int m_ID
Определения DustKickupEffects.c:26
vector position
Определения DustKickupEffects.c:20
void Start()
Plays all elements this effects consists of.
Определения Effect.c:157
EffectType
Enum to determine what type of effect the Effect is.
Определения Effect.c:3
bool IsPlaying()
Returns true when the Effect is playing, false otherwise.
Определения Effect.c:197
void Effect()
ctor
Определения Effect.c:72
void DecreaseLifespan(float timeSlice)
Определения EffectManager.c:715
ParticleEffecter m_LastParticleID
class SEffectManager m_EffecterType
void EffecterParameters(string type, float lifespan)
Определения EffectManager.c:679
float m_Lifespan
Определения EffectManager.c:678
class SEffectManager REACTIVATE0
void SetParticle(int particleID)
Определения EffectManager.c:875
void EffectParticleGeneral()
Определения EffectManager.c:871
class SEffectManager START
void SetLifespan(float lifespan)
Определения EffectManager.c:727
int m_Command
Определения EffectManager.c:701
override int GetHideIconMask()
Определения EffectManager.c:769
ParticleEffecterParameters NOT_DEFINED_LIFESPAN
void Reactivate()
Определения EffectManager.c:744
void EffecterBase()
Определения EffectManager.c:704
override void SetParticleID(int id)
Определения EffectManager.c:889
void Process()
Определения EffectManager.c:757
int m_CommandSync
Определения EffectManager.c:702
void ForceParticleRotationRelativeToWorld(bool state)
Set orientation setting to be used by the effect when the Effect starts.
Определения EffectParticle.c:542
Wrapper class for managing particles through SEffectManager.
Определения EffectParticle.c:5
void SetSoundSet(string snd)
Set soundset for the sound.
Определения EffectSound.c:798
bool SoundPlayEx(out SoundParams params)
Plays sound.
Определения EffectSound.c:152
void SetSoundLoop(bool loop)
Set if the sound loops.
Определения EffectSound.c:816
void SetSoundFadeIn(float fade_in)
Set the sound fade in duration.
Определения EffectSound.c:899
void SetSoundFadeOut(float fade_out)
Set the sound fade out duration.
Определения EffectSound.c:908
void SetEnviromentVariables(bool setEnvVariables)
Sets whether AddEnvSoundVariables needs to be called during Loading.
Определения EffectSound.c:828
override void SetParent(Object parent_obj, int pivot)
Set parent for the sound to follow.
Определения EffectSound.c:658
bool SoundPlay()
Plays sound.
Определения EffectSound.c:199
Wrapper class for managing sound through SEffectManager.
Определения EffectSound.c:5
Определения ObjectTyped.c:2
override void Init(int id, EffecterParameters parameters)
Определения EffectManager.c:787
ref EffectParticleGeneral m_Effect
Определения EffectManager.c:779
void ParticleEffecter(int lifespan)
Определения EffectManager.c:782
void SetParticle(int particleID)
Определения EffectManager.c:795
override void OnVariablesSynchronized()
Определения EffectManager.c:801
int m_ParticleEffectID
Определения EffectManager.c:777
void ~ParticleEffecter()
Определения EffectManager.c:862
int m_ParticleEffectIDSync
Определения EffectManager.c:778
GetEffectTypename()
Определения EffectManager.c:857
void ParticleEffecterParameters(string type, float lifespan, int particleID)
Определения EffectManager.c:689
static void Event_OnSoundWaveEnded(EffectSound effect_sound)
Event called from EffectSound.Event_OnSoundWaveEnded.
Определения EffectManager.c:477
static int GetFreeEffecterID()
Определения EffectManager.c:353
static EffectSound PlaySoundEnviroment(string sound_set, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound, updating environment variables.
Определения EffectManager.c:237
static void EffectUnregister(int id)
Unregisters Effect in SEffectManager.
Определения EffectManager.c:378
static void Cleanup()
Cleanup method to properly clean up the static data.
Определения EffectManager.c:527
static ref map< int, EffecterBase > m_EffectersMap
Определения EffectManager.c:26
static EffectSound PlaySoundParams(notnull SoundParams params, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound.
Определения EffectManager.c:197
static ref array< int > m_FreeEffecterIDs
Static array of IDs that were previously used, but freed up by unregistering Effecters.
Определения EffectManager.c:28
static void DestroyEffecterParticleServer(int effecterID)
Определения EffectManager.c:639
static EffectSound PlaySoundCachedParams(string sound_set, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound, using or creating cached SoundParams.
Определения EffectManager.c:216
static void InitServer()
Определения EffectManager.c:517
static int GetFreeEffectID()
Helper function for EffectRegister to decide an Effect ID.
Определения EffectManager.c:409
static EffecterBase GetEffecterByID(int effecterID)
Определения EffectManager.c:649
static ref array< int > m_FreeEffectIDs
Static array of IDs that were previously used, but freed up by unregistering.
Определения EffectManager.c:10
static const int INVALID_ID
As the counter starts at 1, Effect ID can never be 0.
Определения EffectManager.c:14
static int PlayInWorld(notnull Effect eff, vector pos)
Play an Effect.
Определения EffectManager.c:47
static ref ScriptInvoker Event_OnFrameUpdate
Static invoker for the SEffectManager.Event_OnFrameUpdate called form MissionGameplay....
Определения EffectManager.c:24
static int m_HighestFreeEffecterID
Определения EffectManager.c:30
static int PlayOnObject(notnull Effect eff, Object obj, vector local_pos="0 0 0", vector local_ori="0 0 0", bool force_rotation_relative_to_world=false)
Play an Effect.
Определения EffectManager.c:70
static int CreateParticleServer(vector pos, EffecterParameters parameters)
returns unique effecter ID
Определения EffectManager.c:586
static Effect GetEffectByID(int effect_id)
Gets the Effect with the given registered Effect ID.
Определения EffectManager.c:316
static EffectSound PlaySoundOnObject(string sound_set, Object parent_object, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound.
Определения EffectManager.c:256
static ref map< int, ref Effect > m_EffectsMap
Static map of all registered effects <id, Effect>
Определения EffectManager.c:8
static int m_HighestFreeEffectID
Counter for quickly getting the next ID if FreeEffectIDs array is empty.
Определения EffectManager.c:12
static bool m_IsCleanup
Bool to check whether Cleanup is happening, which means that the maps should no longer be accessed.
Определения EffectManager.c:16
static void OnUpdate(float timeslice)
Определения EffectManager.c:654
static void Init()
Initialize the containers.
Определения EffectManager.c:507
static void StartParticleServer(int effecterID)
Определения EffectManager.c:620
static void Stop(int effect_id)
Stops the Effect.
Определения EffectManager.c:119
static SoundParams GetCachedSoundParam(string soundset)
Get or create a cached SoundParams object.
Определения EffectManager.c:452
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
static bool m_IsInitialized
Bool to check whether Init was called.
Определения EffectManager.c:18
static bool IsEffectExist(int effect_id)
Checks whether an Effect ID is registered in SEffectManager.
Определения EffectManager.c:303
static bool DestroySound(EffectSound sound_effect)
Legacy, backwards compatibility.
Определения EffectManager.c:441
static void EffectUnregisterEx(Effect effect)
Unregisters Effect in SEffectManager.
Определения EffectManager.c:400
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
static ref map< string, ref SoundParams > m_ParamsMap
Static map of cached sound params, to prevent having to recreate them.
Определения EffectManager.c:21
static void ReinitParticleServer(int effecterID, EffecterParameters parameters)
allows re-initializing existing effecter with new parameters (extept m_EffecterType,...
Определения EffectManager.c:602
static int EffectRegister(Effect effect)
Registers Effect in SEffectManager.
Определения EffectManager.c:331
static void DestroyEffect(Effect effect)
Unregisters, stops and frees the Effect.
Определения EffectManager.c:280
static void StopParticleServer(int effecterID)
Определения EffectManager.c:630
static void Event_OnFrameUpdate(float time_delta)
Event called on frame.
Определения EffectManager.c:489
static void ReactivateParticleServer(int effecterID)
Определения EffectManager.c:611
Manager class for managing Effect (EffectParticle, EffectSound)
Определения EffectManager.c:6
ScriptInvoker Class provide list of callbacks usage:
Определения 2_GameLib/DayZ/tools.c:116
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
Определения Transport.c:70
static const vector Zero
Определения EnConvert.c:123
Определения EnConvert.c:119
ErrorExSeverity
Определения EnDebug.c:62
proto void Print(void var)
Prints content of variable to console/log.
enum ShapeType ErrorEx
@ NONE
body is not in simulation, nor in collision world
Определения SimulationState.c:15
class SoundObject SoundParams(string name)
void Stop()
Stops all elements this effect consists of.
Определения Effect.c:183
@ STOP
Определения EnWidgets.c:508