Marss911 0 Posted September 8, 2002 Ok maybe its not the right spot. but here it is. Can somebody help me whit the cpp? Its not working fine. Saying something whit error Rifle. PLease help // British Army Pack Version 1 // Weapons Made By Marcel // Cpp Made by Marcel // some basic defines #define TEast 0 #define TWest 1 #define TGuerrila 2 #define TCivilian 3 #define TSideUnknown 4 #define TEnemy 5 #define TFriendly 6 #define TLogic 7 #define true 1 #define false 0 // type scope #define private 0 #define protected 1 #define public 2 #define WeaponNoSlot 0// dummy weapons #define WeaponSlotPrimary 1// primary weapons #define WeaponSlotSecondary 16// secondary weapons #define WeaponSlotItem 256// items #define WeaponSlotBinocular 4096// binocular #define WeaponHardMounted 65536 class CfgPatches { class Mk1_Lee_Enfield_Sniper { units[] = {}; weapons[] = {Mk1_Lee_Enfield_Sniper}; requiredVersion = 1.01; }; class Mk1_Lee_Enfield { units[] = {}; weapons[] = {Mk1_Lee_Enfield}; requiredVersion = 1.01; }; class Mk3_Lee_Enfield { units[] = {Mk3_Lee_Enfield}; weapons[] = {}; requiredVersion = 1.01; }; class Sten_Mark_2 { units[] = {Sten_Mark_2}; weapons[] = {}; requiredVersion = 1.01; }; class Sten_Mark_3 { units[] = {Sten_Mark_3}; weapons[] = {}; requiredVersion = 1.01; }; class Sten_Mark_5 { units[] = {Sten_Mark_5}; weapons[] = {}; requiredVersion = 1.01; }; }; class CfgModels { class Default{}; class Weapon: Default{}; class Mk1_Lee_Enfield_Sniper: Weapon{}; class Mk1_Lee_Enfield: Weapon{}; class Mk3_Lee_Enfield: Weapon{}; class Sten_Mark_2: Weapon{}; class Sten_Mark_3: Weapon{}; class Sten_Mark_5: Weapon{}; class Man: Default {}; class uelut: Man{}; }; class CfgAmmo { class Default {}; class BulletSingle : Default {}; class 303_British : BulletSingle { hit=8; indirectHit=4; indirectHitRange=0.1; initspeed="853"; tracerColor[]={0,0,0,0}; minRange=0; minRangeProbab=0.500000; midRange=50; midRangeProbab=0.800000; maxRange=350; maxRangeProbab=0.200000; }; }; class CfgWeapons { class default {}; class MGun: Default {}; class Riffle: MGun {}; class Mk1_Lee_Enfield_Sniper:Riffle { scopeWeapon=2; scopeMagazine=0; weaponType=1; magazineType=256; modelOptics="optika_snpierw"; optics = true; picture="\B1\Pictures\Garand.jpg"; opticsZoomMin=0.040000; opticsZoomMax=0.120000; distanceZoomMin=400; distanceZoomMax=80; displayName="Mk1 Lee-Enfield Sniper"; displayNameMagazine=".303 British"; shortNameMagazine="303_British"; drySound[]={"weapons\M16dry",db-40,1}; ammo = 303_British; count = 10; multiplier = 1; burst = 1; dispersion = 0.000865; model="\B1\Mk1_Lee_Enfield_Sniper.p3d"; sound[]={\B1\Sound\Lee_Enfield_Shoot,db0,1}; reloadMagazineSound[]={\B1\Sound\Lee_Enfield_Reload,db-30,1}; soundContinuous = false; magazines[]={"303_British"}; reloadTime=0.35; ffCount=1; recoil=sniperSingle; recoilFixed=RiffleSingleFixed; autoFire = 0; aiRateOfFire=2; aiRateOfFireDistance=500; useAction = 0; useActionTitle = ""; }; class Mk1_Lee_Enfield:Riffle { scopeWeapon=2; scopeMagazine=0; weaponType=1; magazineType=256; modelOptics="optika_m16.p3d"; optics = true; picture="\B1\Pictures\Garand.jpg"; opticsZoomMin=0.35; opticsZoomMax=0.35; displayName="Mk1 Lee-Enfield"; displayNameMagazine=".303 British"; shortNameMagazine="303_British"; drySound[]={"weapons\M16dry",db-40,1}; ammo = 303_British; count = 10; multiplier = 1; burst = 1; dispersion = 0.000865; model="\B1\Mk1_Lee_Enfield.p3d"; sound[]={\B1\Sound\Lee_Enfield_Shoot,db0,1}; reloadMagazineSound[]={\B1\Sound\Lee_Enfield_Reload,db-30,1}; soundContinuous = false; magazines[]={"303_British"}; reloadTime=0.35; ffCount=1; recoil=sniperSingle; recoilFixed=RiffleSingleFixed; autoFire = 0; aiRateOfFire=2; aiRateOfFireDistance=500; useAction = 0; useActionTitle = ""; }; }; class Mk3_Lee_Enfield:Riffle { scopeWeapon=2; scopeMagazine=0; weaponType=1; magazineType=256; modelOptics="optika_m16.p3d"; optics = true; picture="\B1\Pictures\Garand.jpg"; opticsZoomMin=0.35; opticsZoomMax=0.35; displayName="Mk3 Lee-Enfield"; displayNameMagazine=".303 British"; shortNameMagazine="303_British"; drySound[]={"weapons\M16dry",db-40,1}; ammo = 303_British; count = 10; multiplier = 1; burst = 1; dispersion = 0.000865; model="\B1\Mk3_Lee_Enfield.p3d"; sound[]={\B1\Sound\Lee_Enfield_Shoot,db0,1}; reloadMagazineSound[]={\B1\Sound\Lee_Enfield_Reload,db-30,1}; soundContinuous = false; magazines[]={"303_British"}; reloadTime=0.35; ffCount=1; recoil=sniperSingle; recoilFixed=RiffleSingleFixed; autoFire = 0; aiRateOfFire=2; aiRateOfFireDistance=500; useAction = 0; useActionTitle = ""; }; class Sten_Mark_2:Riffle { scopeWeapon=2; scopeMagazine=0; weaponType=1; magazineType=256; modelOptics="optika_m16.p3d"; optics = true; picture="\B1\Pictures\Thompson.jpg"; opticsZoomMin=0.60; opticsZoomMax=0.60; displayName="Lee-Enfield Sten Mark II"; displayNameMagazine="9 mm Para"; shortNameMagazine="303_British"; drySound[]={"weapons\M16dry",0.5,1}; ammo = 303_British; count = 30; model="\B1\Sten_Mark_2.p3d"; reloadMagazineSound[]={\B1\Sound\Tom_load.ogg,db-30,1}; soundContinuous = false; magazines[]={"303_British"}; modes[]={"Single","Fullauto"}; class Single { ammo="303_British"; multiplier=1; burst=1; displayName="Sten Mark II (Single)"; reloadTime=0.09; sound[]={\B1\Sound\Tom_Shoot.wav,db0,1}; soundContinuous=0; dispersion=0.01; ffCount=30; recoil="riffleBurst3"; autoFire=0; aiRateOfFire=2; aiRateOfFireDistance=300; useAction = 0; useActionTitle = ""; }; class Fullauto { ammo="303_British"; multiplier=1; burst=1; displayName="Sten Mark II (Auto)"; reloadTime=0.09; sound[]={\B1\Sound\Tom_Shoot.wav,db0,1}; soundContinuous=0; dispersion=0.015; ffCount=30; recoil="riffleBurst3"; autoFire=1; aiRateOfFire=0; aiRateOfFireDistance=300; useAction = 0; useActionTitle = ""; }; class Sten_Mark_3:Riffle { scopeWeapon=2; scopeMagazine=0; weaponType=1; magazineType=256; modelOptics="optika_m16.p3d"; optics = true; picture="\B1\Pictures\Thompson.jpg"; opticsZoomMin=0.60; opticsZoomMax=0.60; displayName="Lee-Enfield Sten Mark III"; displayNameMagazine="9 mm Para"; shortNameMagazine="303_British"; drySound[]={"weapons\M16dry",0.5,1}; ammo = 303_British; count = 30; model="\B1\Sten_Mark_3.p3d"; reloadMagazineSound[]={\B1\Sound\Tom_load.ogg,db-30,1}; soundContinuous = false; magazines[]={"303_British"}; modes[]={"Single","Fullauto"}; class Single { ammo="303_British"; multiplier=1; burst=1; displayName="Sten Mark III (Single)"; reloadTime=0.09; sound[]={\B1\Sound\Tom_Shoot.wav,db0,1}; soundContinuous=0; dispersion=0.01; ffCount=30; recoil="riffleBurst3"; autoFire=0; aiRateOfFire=2; aiRateOfFireDistance=300; useAction = 0; useActionTitle = ""; }; class Fullauto { ammo="303_British"; multiplier=1; burst=1; displayName="Sten Mark III (Auto)"; reloadTime=0.09; sound[]={\B1\Sound\Tom_Shoot.wav,db0,1}; soundContinuous=0; dispersion=0.015; ffCount=30; recoil="riffleBurst3"; autoFire=1; aiRateOfFire=0; aiRateOfFireDistance=300; useAction = 0; useActionTitle = ""; }; }; class Sten_Mark_5:Riffle { scopeWeapon=2; scopeMagazine=0; weaponType=1; magazineType=256; modelOptics="optika_m16.p3d"; optics = true; picture="\B1\Pictures\Thompson.jpg"; opticsZoomMin=0.60; opticsZoomMax=0.60; displayName="Lee-Enfield Sten Mark V"; displayNameMagazine="9 mm Para"; shortNameMagazine="303_British"; drySound[]={"weapons\M16dry",0.5,1}; ammo = 303_British; count = 30; model="\B1\Sten_Mark_5.p3d"; reloadMagazineSound[]={\B1\Sound\Tom_load.ogg,db-30,1}; soundContinuous = false; magazines[]={"303_British"}; modes[]={"Single","Fullauto"}; class Single { ammo="303_British"; multiplier=1; burst=1; displayName="Sten Mark V (Single)"; reloadTime=0.09; sound[]={\B1\Sound\Tom_Shoot.wav,db0,1}; soundContinuous=0; dispersion=0.01; ffCount=30; recoil="riffleBurst3"; autoFire=0; aiRateOfFire=2; aiRateOfFireDistance=300; useAction = 0; useActionTitle = ""; }; class Fullauto { ammo="303_British"; multiplier=1; burst=1; displayName="Sten Mark V (Auto)"; reloadTime=0.09; sound[]={\B1\Sound\Tom_Shoot.wav,db0,1}; soundContinuous=0; dispersion=0.015; ffCount=30; recoil="riffleBurst3"; autoFire=1; aiRateOfFire=0; aiRateOfFireDistance=300; useAction = 0; useActionTitle = ""; }; }; class CfgNonAIVehicles { class ProxyWeapon {}; class ProxyMk1_Lee_Enfield_Sniper: ProxyWeapon {}; class ProxyMk1_Lee_Enfield: ProxyWeapon {}; class ProxyMk3_Lee_Enfield: ProxyWeapon {}; class ProxySten_Mark_2: ProxyWeapon {}; class ProxySten_Mark_3: ProxyWeapon {}; class ProxySten_Mark_5: ProxyWeapon {}; }; Over and out Marcel Share this post Link to post Share on other sites
SelectThis 0 Posted September 8, 2002 error is with the closing off of the class Mk1_Lee_Enfield:Riffle you've got an extra }; at the end of the section. also with the cfgpatches do it like this: class CfgPatches { class Nameofaddon { units[] = {}; weapons[] = {Mk1_Lee_Enfield_Sniper, Mk1_Lee_Enfield, Mk3_Lee_Enfield, etc...}; requiredVersion = 1.75; }; ie: you only need one entry for all the classes. SelectThis Share this post Link to post Share on other sites
KKB 0 Posted September 8, 2002 Additionaly to what STT said, you need to add a }; at the end of the class Sten_Mark_2 section and at the end of the whole cfgWeapons section Share this post Link to post Share on other sites
Marss911 0 Posted September 8, 2002 Tnx. Ill c if it while work. (i gues it will ) Marcel Share this post Link to post Share on other sites