ammocamparams.c 774 B

1234567891011121314151617
  1. class AmmoCamParams
  2. {
  3. void Load(string ammoType)
  4. {
  5. string cfgPath = "CfgAmmo " + ammoType + " Effects" + " CameraShake ";
  6. m_Radius = GetGame().ConfigGetFloat(cfgPath + "radius");
  7. m_Strength = GetGame().ConfigGetFloat(cfgPath + "strength");
  8. m_ModifierClose = GetGame().ConfigGetFloat(cfgPath + "modifierClose");
  9. m_ModifierFar = GetGame().ConfigGetFloat(cfgPath + "modifierFar");
  10. }
  11. float m_Radius = 40;//the max distance at which the cam shake is triggered
  12. float m_Strength = 4;//strength of the cam shake
  13. float m_ModifierClose = 1;//shake 'strength' modifier when the player is at distance 0 from the source of explosion
  14. float m_ModifierFar = 0;//shake 'strength' modifier when the player is at distance 'radius' from the source of explosion
  15. }