When I was trying to create some custom suppressor and make it the gun recoils less, I encountered this problem.
It seems like the game engine doesn't execute any changes to the recoil of the weapon.
thanks for any help.
Description
Description
Details
Details
- Severity
- Major
- Resolution
- Open
- Reproducibility
- Always
- Operating System
- Windows 10 x64
- Category
- Engine
Steps To Reproduce
1.Create any suppressor mod to make the attached gun recoil less/more.
2.write a code like below and load the mod in game, you'll find nothing has affected the gun behaviors.
Here is the part of my "config.cpp" in my weapon mod.
class CfgWeapons { class RifleCore; class Rifle: RifleCore { class WeaponSlotsInfo; }; class ItemCore; class InventoryFlashLightItem_Base_F; class InventoryMuzzleItem_Base_F; class InventoryUnderItem_Base_F; class Rifle_Base_F: Rifle { class WeaponSlotsInfo { class MuzzleSlot; class CowsSlot; class PointerSlot; }; class GunParticles; }; class muzzle_snds_H: ItemCore ///!!!!! { class ItemInfo; }; class otty_acc_pbs1: muzzle_snds_H ///!!!!! { displayName = "Otty's PBS-1"; picture = "\366VEPRS\data\acc\PBS1_001.paa"; model = "\366VEPRS\data\acc\pbs1.p3d"; author = "Otty"; class ItemInfo: InventoryMuzzleItem_Base_F { mass = 12; //seems work class MagazineCoef //seems work { initSpeed = 1.015; }; class AmmoCoef //seems work { hit = 1.0; visibleFire = 0.2; audibleFire = 0.4; visibleFireTime = 0.5; audibleFireTime = 1.0; cost = 1.0; typicalSpeed = 1; airFriction = 1.0; }; class MuzzleCoef //partially works { dispersionCoef = 0.97; //seems work artilleryDispersionCoef = 15.05; fireLightCoef = 0.05; recoilCoef = 15.05; //doesnt work recoilProneCoef = 0.05; //doesn't work minRangeCoef = 0.05; minRangeProbabCoef = 0.05; midRangeCoef = 0.05; midRangeProbabCoef = 0.05; maxRangeCoef = 0.05; maxRangeProbabCoef = 0.05; }; muzzleEnd = "zaslehPoint"; alternativeFire = "Zasleh2"; soundTypeIndex = 1; inertia = 0.2; }; };
Additional Information
I tested out other params in MuzzleCoef and found that at least dispersionCoef works.