OFPEC Forum

Addons & Mods Depot => ArmA - Configs & Scripting => Topic started by: Dowly on 09 Dec 2008, 20:17:55

Title: Need very quick help re: Config.cpp
Post by: Dowly on 09 Dec 2008, 20:17:55
Hello all! Long time not been here.  :cool2:

Anywho, I started playing ArmA again after some time, managed to set-up an squad with my online friends. Now, I'd like to make some nice screenshots in the editor, you know, kind of "promo" shots for our squad. But I have a problem I cant figure out.

I need to have custom faces for the soldiers in the screenshots (The ones, my squad buddies use). Anyway, I take I need to make the faces as an addon? Ookie, well I tried that, but I'm having troubles with the config.cpp, I really cant figure out what to write in it to make the addon work.  :(

Is there any kind soul who has the knowledge on making a config.cpp for a face addon and would be willing to write the file for me?

Here's the details:

Addon name: SSCFaces

And the soldier names/classes and the pic files are:

Dowly / Dowly.jpg

Hunter / Hunter.jpg

Neon / Neon.jpg

Fincuan / Fincuan.jpg

Thanks in advance for anyone who can help me with this one!  :clap:
Title: Re: Need very quick help re: Config.cpp
Post by: bedges on 09 Dec 2008, 20:34:02
A quick search (http://www.ofpec.com/ed_depot/index.php?action=details&id=303) of the Editors Depot would reveal the answer...

Search is your friend, folks. Good search. Nice search.
Title: Re: Need very quick help re: Config.cpp
Post by: Dowly on 09 Dec 2008, 20:56:51
Aye, I found that, did that and it said "SSCFaces addon requires version 1.91", something left from OFP me thinks. I'm a real noob on this, I've never done a single addon for OFP nor ArmA, and the little scripting I've done when making missions have been very easy and simple stuff. That's why I'm asking someone to do it for me.  ::)
Title: Re: Need very quick help re: Config.cpp
Post by: Planck on 09 Dec 2008, 21:38:19
All other things being equal, you merely have to change the relevant line to suit.

requiredVersion = 1.91; ...This being the required version for OFP.

requiredVersion = 1.14; ... This being the required version for the latest ArmA.


Planck
Title: Re: Need very quick help re: Config.cpp
Post by: Dowly on 09 Dec 2008, 21:57:29
Dang, I'm really not getting any further here.

Let me just tell what I've done, prolly be easier for you guys to spot what I've done wrong.

I have a folder called 'SSCFaces', inside the folder I have 4 .jpgs, all 512x512 and roughly 40-50kb in size. Then I have the Config.ccp, which looks like this:

Quote
class CfgPatches

{
           class SSCFaces

           {
                        units[] = {};
                        weapons[] = {};
               requiredVersion = 1.14;                   
                       
            };

};


class CfgFaces

{
           class Hunter

           {
                        name=" Hunter ";
                        texture="\SSCFaces\Hunter.jpg";
                        east=1;
                        west=1;

            };





           class Dowly

           {
                        name=" Dowly ";
                        texture="\SSCFaces\Dowly.jpg";
                        east=1;
                        west=1;

            };




           class Fincuan

           {
                        name=" Fincuan ";
                        texture="\SSCFaces\Fincuan.jpg";
                        east=1;
                        west=1;

            };




           class Neon

           {
                        name=" Neon ";
                        texture="\SSCFaces\Neon.jpg";
                        east=1;
                        west=1;

            };

};

When I pack it with the BinPBO Personal Edition, I get no errors whatsoever. Yet, when I go in-game, and try the setface command, it doesnt work.  :dry:
Title: Re: Need very quick help re: Config.cpp
Post by: bedges on 09 Dec 2008, 22:09:55
Silly question, but have you installed the pbo in the addons folder? Is the config called config.cpp (not .ccp)?

The only other thing to check is the extra spaces in the face names, i.e.

Code: [Select]
name=" Hunter ";
I would make that

Code: [Select]
name="Hunter";
Other than that, not sure what the issue might be...  :dunno:
Title: Re: Need very quick help re: Config.cpp
Post by: Dowly on 09 Dec 2008, 22:20:01
Fixed all those, still nothing.  :(

Oh well, nevermind. It's not the end of the world. I go see if I could find a face addon and unpack that to get some more clues of what's the problem.

Thanks anyway guys!  :clap:
Title: Re: Need very quick help re: Config.cpp
Post by: Planck on 09 Dec 2008, 22:41:09
Ok, I made a new config for you, maybe this one will work ... :scratch:

Code: [Select]
class CfgPatches
{
  class SSCFaces
  {
    units[] = {};
    weapons[] = {};
    requiredVersion = 1.14;
    requiredAddons[] = {"CACharacters"};
  };
};

class CfgFaces
{
  class SSCFaces
  {
    class Hunter
    {
      name="Hunter";
      texture="\SSCFaces\Hunter.jpg";
      east=1;
      west=1;
    };

    class Dowly
    {
      name="Dowly";
      texture="\SSCFaces\Dowly.jpg";
      east=1;
      west=1;
    };

    class Fincuan
    {
      name="Fincuan";
      texture="\SSCFaces\Fincuan.jpg";
      east=1;
      west=1;
    };

    class Neon
    {
      name="Neon";
      texture="\SSCFaces\Neon.jpg";
      east=1;
      west=1;
   };
  };
};


Planck
Title: Re: Need very quick help re: Config.cpp
Post by: Dowly on 09 Dec 2008, 22:53:40
No  :( Still nothing. I'm starting to think there's something else to this than the .cpp file.

A silly question, do I need to make it .bin?
Title: Re: Need very quick help re: Config.cpp
Post by: Planck on 09 Dec 2008, 22:58:46
When you pack this all with BinPBO, Binarize should convert it from config.cpp into a config.bin.

Check the Binarize log file and see if it lists any errors.

Failing all, attach here a copy of the resulting PBO


Planck
Title: Re: Need very quick help re: Config.cpp
Post by: Dowly on 09 Dec 2008, 23:14:30
Yeh, I had binarize checked. There was no log in the temp folder, so I quess there was no errors?

Anyway, here's the .pbo:
http://www.mediafire.com/download.php?yjzwvzzjo2a
Title: Re: Need very quick help re: Config.cpp
Post by: Planck on 10 Dec 2008, 00:01:29
Yes, well, your PBO is perfect except it only contains the config.bin.

The pictures are not there, maybe it requires the pictures to be in .paa format.
Easy enough to convert using Texview.

Planck
Title: Re: Need very quick help re: Config.cpp
Post by: Dowly on 10 Dec 2008, 15:27:55
*Sigh*

Converted them to .paa and changed the necessary things from config.cpp. No luck. Also, got the .jpg's now to appear in the pbo. No luck with them either.  :no:
Title: Re: Need very quick help re: Config.cpp
Post by: Planck on 12 Dec 2008, 16:17:55
The textures are definitely 2^ compliant?

Put up your lates pBO and I will look at it again.


Planck
Title: Re: Need very quick help re: Config.cpp
Post by: Dowly on 13 Dec 2008, 20:41:42
Ok, here's the Pbo as well as the folder I made the addon of. If you want and have the will, you can try making the addon from the folder.
http://www.mediafire.com/download.php?ittmxt4bhjy
Title: Re: Need very quick help re: Config.cpp
Post by: Planck on 14 Dec 2008, 01:51:43
Ok, I have tried this every which way I can think of but to no avail.

Trying with one face only "Hunter"
Everything I try I get the same RPT error message:

SetFace error: class CfgFaces.man.Hunter not found ... which means it is looking for the "Hunter" face under class man ... under class cfgFaces ........... sooooo .....

I rewrote the config, classing all the faces under class man under class cfgFaces even though I know this will overwrite the original cfgFaces for ArmA, I was curious to see if it would work.

No such luck, even though all the faces are now under class man under class cfgFaces I still get the error message:

SetFace error: class CfgFaces.man.Hunter not found

Strange, this all worked well enough under OFP.   :dunno:


Planck