Home   Help Search Login Register  

Author Topic: wierd error message  (Read 1112 times)

0 Members and 1 Guest are viewing this topic.

cpt.Hawkeyez

  • Guest
wierd error message
« on: 31 Jan 2004, 22:20:43 »
Code: [Select]
'g3\config.cpp::CfgWeapons.Class:"m" encountered instead of "=" Thats the error message I get everytime when I try start up ofp with my newly made g3a3 assualt rifle heres a copy of the config will someone please take a look through this real quick and tell me if theres anything wrong?
Code: [Select]
//Config file written by OFPCW ofps.cncguild.net/configw
//g3 made by CMP
#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

#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 g3
     {
         units[] = {};
         weapons[] = {g3};
         requiredVersion = 1.05;
     };
};
class CfgAmmo
{
        class Default {};
        class BulletSingle: Default{};
        class CMPG3mag: BulletSingle
        {
                hit= 8;
                indirectHit= 1;
                indirectHitRange= 0.40000;
                minRange=0.5;
                minRangeProbab=0.800000;
                midRange=50;
                midRangeProbab=0.350000;
                maxRange=109;
                maxRangeProbab=0.080000;
                visibleFire= 16;
                audibleFire= 16;
                visibleFireTime= 10;
        };
};


  class CfgWeapons
     {
      class Default {};
      class MGun: Default {};
      class Riffle: Mgun {};
      Class m16: Riffle {};
      class g3: m16
     {
                model="\g3\g3";
                modelOptics="";
                displayName="g3";
                magazines[]={"g3mag"};
                flash="gunfire";
                flashSize=5;
                initSpeed=938;
                opticsFlare= true;
                modes[]= {"Single","Burst"};
                class Single
               {
                      ammo="CMPG3mag";
                      multiplier=1;
                      burst=1;
                      displayName="Semi-Auto";
                      dispersion=0.0002000;
                      ffCount=1;
                      reloadTime=0.100000;
                      recoil="g3RE";
                      autofire=0;
                      aiRateOfFire=5.0000;
                      aiRateOfFireDistance = 200;
                      UseAction=0;
                      useActionTitle="";
               };
               class Burst
               {
                      ammo="CMPG3mag";
                      multiplier=1;
                      burst=3;
                      displayName= "Burst Fire";
                      dispersion= 0.0004000;
                      reloadtime=0.10000;
                      ffCount=3;
                      recoil= "g3RE";
                      autoFire=0;
                      aiRateofFire= 5.0000;
                      aiRateOfFireDistance= 200;
                                     useAction= 0;
                      useActionTitle= "";
               };
       };
        class g3mag: g3
        {
               scopeWeapon=0;
               scopeMagazine=2;
               displayNameMagazine="G3mag";
               shortNameMagazine="G3mag";
        };
};
class CfgRecoils
{
       g3RE[]= {0.04, 0.015,0.030, 0.040,0,0};
};

class CfgNonAIVehicles
{
       class ProxyWeapon {};
       class Proxyg3: ProxyWeapon {};
};
        };

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:wierd error message
« Reply #1 on: 31 Jan 2004, 22:31:50 »
Not 100% sure......but try removing the last '};' from this bit:

 class Burst
              {
                     ammo="CMPG3mag";
                     multiplier=1;
                     burst=3;
                     displayName= "Burst Fire";
                     dispersion= 0.0004000;
                     reloadtime=0.10000;
                     ffCount=3;
                     recoil= "g3RE";
                     autoFire=0;
                     aiRateofFire= 5.0000;
                     aiRateOfFireDistance= 200;
                                    useAction= 0;
                     useActionTitle= "";
              };
       };              <-----------this one


Also try removing the very last '};'



Planck
I know a little about a lot, and a lot about a little.

cpt.Hawkeyez

  • Guest
Re:wierd error message
« Reply #2 on: 31 Jan 2004, 22:44:21 »
No I still get that stupid error message?
telling me theres an m where an = sign is supposed to be am I using the right syntax inorder to use BIS m16 sounds? cause thast what I am trying to do
/CymPatheeY

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:wierd error message
« Reply #3 on: 31 Jan 2004, 23:47:07 »
Noticed something else:

Class m16: Riffle {};
      class g3: m16

Should be:

class m16: Riffle {};
      class g3: m16

Small 'c'


Planck
I know a little about a lot, and a lot about a little.