Dayz Explorer 1.28.160049
Loading...
Searching...
No Matches
hit_foliage.c
Go to the documentation of this file.
2{
3 void Hit_Foliage()
4 {
5 SetEnterParticle(ParticleList.IMPACT_FOLIAGE_ENTER);
6 SetExitParticle(ParticleList.IMPACT_FOLIAGE_EXIT);
7 SetRicochetParticle(ParticleList.IMPACT_FOLIAGE_RICOCHET);
8 }
9
10 override float CalculateStoppingForce(float in_speedf, float out_speedf, string ammoType, float weight)
11 {
12 if ( m_ImpactType == ImpactTypes.MELEE )
13 {
14 return 500;
15 }
16
17 float projectile_weight_coef = weight / DEFAULT_PROJECTILE_WEIGHT;
18
19 float stopping_force = in_speedf * projectile_weight_coef * 0.5;
20
21 return stopping_force;
22 }
23}
int m_ImpactType
ImpactTypes