OFPEC Forum

Addons & Mods Depot => OFP - Addons & Mods General => Topic started by: M1A1MG on 30 Jun 2006, 11:51:48

Title: config.cpp for model
Post by: M1A1MG on 30 Jun 2006, 11:51:48
Can someone tell me if this could be wrong? My vehicle does not show up in the editor at all.  I'm learning how to use O-2 but I think the config is wrong.  This is what I've got......


class CfgModels
{
   class default {};
   class Vehicle: default {};
   class Car: Vehicle {};
   class Jeep: Car {};
   class firstCar: Jeep {};
};


class CfgPatches
{
     class firstCar
     {
         units[] = {firstCar};
         weapons[] = {};
         requiredVersion = 1.0;
     };

};

class CfgVehicles
{

     class All {};
     class AllVehicles: All {};
     class Land: AllVehicles {};
     class LandVehicle: Land {};
     class Car: LandVehicle {};
     class Jeep: Car {};

     class firstcar: Jeep
     {                               
                displayName="My First Car";     // Displayname in editor
      model= \firstcar\firstcar;   // our p3d model path
                 
      side=3;         // Its on the civilian side
      crew="Civilian2";   // The default driver are civilians
      maxSpeed=300;      // Max speed
                transportSoldier=0;     // Right now just driver, no cargo                                                                                   
      };
}

  Its supposed to go into Civilian cars
Title: Re: config.cpp for model
Post by: Planck on 30 Jun 2006, 12:29:38
Try adding:

vehicleClass="Car";

into your cfgVehicles definition of firstCar


Planck
Title: Re: config.cpp for model
Post by: oyman on 30 Jun 2006, 16:35:52
Try this
Code: [Select]
class CfgModels
{
   class default {};
   class Vehicle: default {};
   class Car: Vehicle {};
   class Jeep: Car {};
   class firstCar: Jeep {};
};


class CfgPatches
{
     class firstCar
     {
         units[] = {firstCar};
         weapons[] = {};
         requiredVersion = 1.0;
     };
 };

class CfgVehicles
{
     class All {};
     class AllVehicles: All {};
     class Land: AllVehicles {};
     class LandVehicle: Land {};
     class Car: LandVehicle {};
     class Jeep: Car {};
     class firstcar: Jeep
     {                               
               displayName="My First Car";     // Displayname in editor
               model= \firstcar\firstcar;   // our p3d model path
               side=3;         // Its on the civilian side
               crew="Civilian2";   // The default driver are civilians
                maxSpeed=300;      // Max speed
                transportSoldier=0;     // Right now just driver, no cargo                                                                                   
      };
};
};
Title: Re: config.cpp for model
Post by: M1A1MG on 01 Jul 2006, 05:55:04
Got it thanks for the input.... I guess I have to save with .pbo at the end when I'm compressing or it wont read it
Title: Re: config.cpp for model
Post by: Messiah on 17 Jul 2006, 00:39:04
some pbo creators require you to add the .pbo on the end... if i recall correctly, makepbo is one of them