IPB


Welcome Guest ( Log In | Register )

 Forum Rules ArmedAssault.info Forum Rules
> File ownweapon\config.cpp, line 4: 'cfgWeapons.': '{' encountered instead of ':', D*mn error :@
SGJackson
post Nov 9 2010, 06:42
Post #1


Member
***

Group: Members
Posts: 131
Joined: 22-May 10
Member No.: 7,651



File ownweapon\config.cpp, line 4: 'cfgWeapons.': '{' encountered instead of ':'
So, I was boring and decided just to stick a random model, that I made in 2 secs (a weapon), in ArmA II: OA...

I don't have no textures to it yet due to it's a TOTALLY invented model... I've extracted this piece of config.cpp (that I'm using here) from my other post in this section:
CODE
class cfgWeapons
{
    class AK_74;
    {
        model="\ownweapon"; //The directory of the model for the weapon
        displayname="OWN_WEAPON"; //The display name ingame
        class Single: Mode_SemiAuto //The semiautomatic firemode class
        {
            begin1[] = {"ca\sounds\weapons\rifles\AK74_single2",1.77828,1,1000}; //The firing sound
            soundBegin[] = {"begin1",1}; //As above, this is a coding relic, to when weapons made different sounds for semi or auto fire back in OFP
            reloadTime = 0.1; //How fast the weapon fires
            recoil = "recoil_single_primary_4outof10"; //The recoil, as defined in cfgrecoils, you'll usually just want to use one of the predefined values for this
            recoilProne = "recoil_single_primary_prone_4outof10"; //As above, but for prone-firing
            dispersion = 0.00125; //The dispersion
            minRange = 2;minRangeProbab = 0.3; //For AI, the minimum engagement range with this weapon
            midRange = 300;midRangeProbab = 0.7; //For AI, the medium engagement range with this weapon
            maxRange = 600;maxRangeProbab = 0.04; //For AI, the maximum engagement range with this weapon
        };
        class Burst: Mode_Burst
        {
            begin1[] = {"ca\sounds\weapons\rifles\AK74_single2",1.77828,1,1000};
            soundBegin[] = {"begin1",1};
            soundBurst = 0;
            reloadTime = 0.1;
            ffCount = 3;
            recoil = "recoil_auto_primary_3outof10";
            recoilProne = "recoil_auto_primary_prone_3outof10";
            dispersion = 0.00125;
            minRange = 50;minRangeProbab = 0.3;
            midRange = 200;midRangeProbab = 0.7;
            maxRange = 500;maxRangeProbab = 0.05;
        };
        class FullAuto: Mode_FullAuto
        {
            begin1[] = {"ca\sounds\weapons\rifles\AK74_single2",1.77828,1,1000};
            soundBegin[] = {"begin1",1};
            reloadTime = 0.1;
            ffCount = 30;
            recoil = "recoil_auto_primary_4outof10";
            recoilProne = "recoil_auto_primary_prone_4outof10";
            dispersion = 0.00125;
            minRange = 0;minRangeProbab = 0.1;
            midRange = 150;midRangeProbab = 0.7;
            maxRange = 300;maxRangeProbab = 0.05;
        };
    };
};


I don't care what sound it has, or if it has muzzleflash or not, or any detail... I just want my weapon to appear and being able to fire it.
Now the error that turns out to be the title of my post is the error that I get when trying to initialize the game __furious.gif
Really have no idea of what's going on, so if any of you got the idea, post it and also (if you feel kindfull) explain how to give my weapon to a unit. stupid.gif

Thanks to ya'll thumbsup.gif
 
Quote Post

Posts in this topic


Reply to this topicStart new topic
3 User(s) are reading this topic (3 Guests and 0 Anonymous Users)
0 Members:

 



Lo-Fi Version Time is now: 19th March 2024 - 03:52