DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ UpdateAnimation()

override void Mag_MP18_Drum32Rnd::UpdateAnimation ( )
inlineprotected

См. определение в файле Magazines.c строка 84

85 {
86 int ammoCount = GetAmmoCount();
87 float animPhase = Math.Lerp(m_AnimStart, m_AnimEnd, (ammoCount - m_AmmoOffset) * m_MaxAmmoPercentage);
88 SetAnimationPhase(m_AnimationSource, animPhase);
89 m_LastAnimPhase = animPhase;
90 if(g_Game && !g_Game.IsDedicatedServer())
91 {
92 if(ammoCount >= m_AmmoOffset)
93 {
94 EffectSound sound;
95 PlaySoundSetAtMemoryPoint(sound, m_DrumLeverSoundset, "drum_sound");
96 sound.SetAutodestroy(true);
97 }
98 }
99 }
DayZGame g_Game
Определения DayZGame.c:4074
override void SetAutodestroy(bool auto_destroy)
Sets whether Effect automatically cleans up when it stops.
Определения EffectSound.c:607
float m_AmmoOffset
the number of bullets at which the animation reaches m_AnimEnd (e.g. animation finishes at 12 bullets...
Определения Magazines.c:79
float m_MaxAmmoPercentage
Определения Magazines.c:80
string m_DrumLeverSoundset
Определения Magazines.c:82
float m_AnimStart
at 1.0 the magazine is at max bullets
Определения Magazines.c:71
float m_AnimEnd
at 0.0 the magazine is at 12 bullets and anim stops there as requested by designers
Определения Magazines.c:74
string m_AnimationSource
Определения Magazines.c:81
float m_LastAnimPhase
Определения Magazines.c:76

Перекрестные ссылки g_Game, Math::Lerp(), m_AmmoOffset, m_AnimationSource, m_AnimEnd, m_AnimStart, m_DrumLeverSoundset, m_LastAnimPhase, m_MaxAmmoPercentage и EffectSound::SetAutodestroy().