Home   Help Search Login Register  

Author Topic: Problems with CfgModels!!  (Read 1600 times)

0 Members and 1 Guest are viewing this topic.

Serial Killer

  • Guest
Problems with CfgModels!!
« on: 16 Jun 2005, 20:14:06 »
I'm trying to make random faces for units, so I writed this on my addon's config.

Quote
class CfgModels
{
class Default
{
sections[] = {};
sectionsInherit="";
};

class Head: Default
{
sections[] =
{
"osobnost",
"brejle"
};
};
class rkap1: Default
{
sections[] =
{
"head injury","body injury",
"l arm injury","r arm injury","p arm injury",
"l leg injury","r leg injury","p leg injury",
"medic",
"hlava",
"krk",
"zasleh"
};
sectionsInherit=Head;
};
};


Ok, it works fine. But here's the problem:


When I'm trying to add there one more unit (rkap2), I cant see those units in editor anymore. :o

Here's the edited config with that other unit:

Quote
class CfgModels
{
class Default
{
sections[] = {};
sectionsInherit="";
};

class Head: Default
{
sections[] =
{
"osobnost",
"brejle"
};
};
class rkap1: Default
class rkap2: Default
{
sections[] =
{
"head injury","body injury",
"l arm injury","r arm injury","p arm injury",
"l leg injury","r leg injury","p leg injury",
"medic",
"hlava",
"krk",
"zasleh"
};
sectionsInherit=Head;
};
};

Help me! :(

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Problems with CfgModels!!
« Reply #1 on: 16 Jun 2005, 20:43:51 »
Try:

Code: [Select]
class CfgModels
{
   class Default
   {
      sections[] = {};
      sectionsInherit="";
   };

   class Head: Default
   {
      sections[] = {"osobnost","brejle"};
   };

   class rkap1: Default
   {
      sections[] ={"head injury","body injury","l arm injury","r arm injury","p arm injury","l leg injury","r leg injury","p leg injury","medic","hlava","krk","zasleh"};
      sectionsInherit=Head;
   };

   class rkap2: rkap1 {};
};


Planck
« Last Edit: 16 Jun 2005, 21:12:36 by Planck »
I know a little about a lot, and a lot about a little.

Serial Killer

  • Guest
Re:Problems with CfgModels!!
« Reply #2 on: 16 Jun 2005, 20:59:21 »
Now that one what worked already wont work, and that one what didn't work works now. What the f*ck? :o ::)

Here's thw hole config if it helps:

Quote
// 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 rkap
   {
      units[] = {rkap1,rkap2};
      weapons[] = {};
      requiredVersion = 1.01;
              sections[]={"head injury","body injury","l arm injury","r arm injury","p arm injury","l leg injury","r leg injury","p leg injury","medic","hlava","krk","zasleh","prot","transglass"};
              ectionsInherit="Head";   
};   
};


class CfgModels
{
   class Default
   {
      sections[] = {};
      sectionsInherit="";
   };

   class Head: Default
   {
      sections[] = {"osobnost","brejle"};
   };

   class rkap1: Default {};

   class rkap2: rkap1
   {
      sections[] ={"head injury","body injury","l arm injury","r arm injury","p arm injury","l leg injury","r leg injury","p leg injury","medic","hlava","krk","zasleh"};
      sectionsInherit=Head;
};
};

class CfgVehicles
{
   class All{};
   class AllVehicles : All{};
   class Land : AllVehicles{};
   class Man : Land{};
   class Soldier : Man{};
   class SoldierWB : Soldier{};
   class rkap1 : SoldierWB{
   displayName="Squad RK soldier (Green)";
               model="\rkap\mod\rkap1";
      weapons[]={"M16","Binocular","NVgoggles","Throw","Put"};
      magazines[]={"M16","M16","M16","M16","HandGrenade","HandGrenade","HandGrenade","HandGrenade","HandGrenade","HandGrenade"};
   };
   class rkap2 : rkap1{
   displayName="Squad RK soldier (Brown)";
               model="\rkap\mod\rkap2";
      weapons[]={"AK74","Binocular","NVgoggles","Throw","Put"};
      magazines[]={"AK74","AK74","AK74","AK74","HandGrenade","HandGrenade","HandGrenade","HandGrenade","HandGrenade","HandGrenade"};
   };
};

class CfgNonAIVehicles
{
   class ProxyWeapon {};
   class Proxy : ProxyWeapon {};
};

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Problems with CfgModels!!
« Reply #3 on: 16 Jun 2005, 21:14:17 »
I edited my first post, try the edited version.

However, I'm not even sure if 1.46 needs cfgPatches, or even cfgModels......don't quote me on that, like I said, I'm not sure.

btw......these are soldier models are they not?



Planck
« Last Edit: 16 Jun 2005, 21:15:08 by Planck »
I know a little about a lot, and a lot about a little.

Serial Killer

  • Guest
Re:Problems with CfgModels!!
« Reply #4 on: 16 Jun 2005, 21:21:25 »
That's right.

Hmm...

When I launch the game, it says
Quote
Config rkap\config.cpp: some input after EndOfFile

EDIT: I dunno what I did... But it seems to be working now... :o
Anyway, you helped me a lot, so thank you very much! :)
« Last Edit: 16 Jun 2005, 21:24:33 by Serial Killer »

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Problems with CfgModels!!
« Reply #5 on: 16 Jun 2005, 21:23:49 »
What do you use to write your configs?


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

Serial Killer

  • Guest
Re:Problems with CfgModels!!
« Reply #6 on: 16 Jun 2005, 21:25:21 »
It's working now, as I wrote on my last post ;)