PDA

View Full Version : Config.cpp for weapons?



ComradeJD
Jul 3 2002, 10:25
I just made a model with a friend and I made a config.cpp. But i'm still getting errors. Wait, here's the config.cpp :

// 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 Terminator
    {
        units[] = {Terminator};
        weapons[] = {};
        requiredVersion = 1.30;
    };
    class SSG3000
    {
        units[] = {};
        weapons[] = {SSG3000};
        requiredVersion = 1.30;
    };
};


class CfgAmmo
{
    class default {};
    class M21 : Default {};
    class SSG3000 : M21 {};
    class SSG3000ammo : M21
    {
        hit=800;
        indirectHit=200;
        indirectHitRange=2;
   
        picture="\m21_lod.pac";
    };
};

class CfgWeapons
{
class Default {};
class MGun : Default {};
class Riffle: MGun {};
class SniperRiffle : Riffle {};
class M21 : SniperRiffle {};
   class SSG3000 : M21
    {


        model="\ssg3000\ssg3000.p3d";

        picture="\m21_lod.pac";
        displayName = SSG3000;
        displayNameMagazine = SSG3000;
        shortNameMagazine = SSG;

        ammo = SSG3000ammo;

        initspeed=250;
        count = 16;
        maxLeadSpeed=300;
    };
};

class CfgNonAIVehicles
{
    class ProxyWeapon {};
    class ProxySSG3000: ProxyWeapon {};
};

That terminator thing has to be an NATO soldier but don't konw what that has to be http://www.flashpoint1985.com/ikonboard301/iB_html/non-cgi/emoticons/sad.gif . PLZ look to the CfgWeapons too. I think that's wrong  http://www.flashpoint1985.com/ikonboard301/iB_html/non-cgi/emoticons/confused.gif


EDIT : And the player has to be West http://www.flashpoint1985.com/ikonboard301/iB_html/non-cgi/emoticons/tounge.gif

Jackal326
Jul 14 2002, 01:01
// 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 Terminator
{
units[] = {Terminator};
weapons[] = {};
requiredVersion = 1.30;
};
};
class SSG3000
{
units[] = {};
weapons[] = {SSG3000};
requiredVersion = 1.30;
};
};


class CfgAmmo
{
class default {};
class M21 : Default {};
class SSG3000ammo : M21
{
hit=800;
indirectHit=200;
indirectHitRange=2;

picture="\m21_lod.pac";
};
};

class CfgWeapons
{
class Default {};
class MGun : Default {};
class Riffle: MGun {};
class SniperRiffle : Riffle {};
class M21 : SniperRiffle {};
class SSG3000 : M21
{


model="\ssg3000\ssg3000.p3d";

picture="\m21_lod.pac";
displayName = SSG3000;
displayNameMagazine = SSG3000;
shortNameMagazine = SSG;

ammo = SSG3000ammo;

initspeed=250;
count = 16;
maxLeadSpeed=300;
};
};

class CfgNonAIVehicles
{
class ProxyWeapon {};
class ProxySSG3000: ProxyWeapon {};
};
Try that
Just made a few tweaks.