Ejemplo n.º 1
0
 // Token: 0x06001F99 RID: 8089 RVA: 0x0009788C File Offset: 0x00095A8C
 private void ApplyDamage(WeaponSlot slot, CmunePairList <BaseGameProp, ShotPoint> hits)
 {
     foreach (KeyValuePair <BaseGameProp, ShotPoint> keyValuePair in hits)
     {
         DamageInfo damageInfo = new DamageInfo(Convert.ToInt16(slot.View.DamagePerProjectile * keyValuePair.Value.Count))
         {
             Bullets = (byte)keyValuePair.Value.Count,
             Force   = GameState.Current.Player.WeaponCamera.transform.forward * (float)(slot.View.DamagePerProjectile * keyValuePair.Value.Count),
             UpwardsForceMultiplier = 10f,
             Hitpoint            = keyValuePair.Value.MidPoint,
             ProjectileID        = keyValuePair.Value.ProjectileId,
             SlotId              = slot.SlotId,
             WeaponID            = slot.View.ID,
             WeaponClass         = slot.View.ItemClass,
             CriticalStrikeBonus = WeaponConfigurationHelper.GetCriticalStrikeBonus(slot.View)
         };
         if (keyValuePair.Key != null)
         {
             keyValuePair.Key.ApplyDamage(damageInfo);
         }
     }
 }