Jump to content
Sign in to follow this  
addicted

turret config

Recommended Posts

Hello

I need to add new weapon for vehicles in addon. I can't figure out what I done wrong. In this example Im trying to add to Hunte GMG AA launcher from Cheetah. How should look my config?

class CfgVehicles 
{


class B_MRAP_01_gmg_F;


class B_MRAP_01_aar_F: B_MRAP_01_gmg_F
     {

	vehicleClass = "Car";
	displayName = "Hunter AAR";
	side = 1;
	faction = "BLU_F";
	crew = "B_Soldier_F";

	class Turrets: Turrets 
	{
		class MainTurret: MainTurret 
		{
			weapons[]={missiles_titan};
			magazines[]={4Rnd_Titan_long_missiles};
		};	
	};

};

};

Still when I'm trying to start arma I get message "Undefined base class 'Turret' and arma wan't start.

I know that I can add and remove via script but my goal is to make it via addon. Guys, please help me.

Regards

Share this post


Link to post
Share on other sites

You're missing two base classes; Turrets and MainTurret.

class Turrets;		
class Turrets: Turrets
{
class MainTurret;
};

You have to reference the base classes like you did with

class B_MRAP_01_gmg_F;

Share this post


Link to post
Share on other sites

Thanks for help. My friend helped me to figure out what I missed. Generally it works like this - I needed to write all path to change classess. Path I needed you can see in complete config for vehicles. I looked at the complete config (from oryginal ARMA 3) at this site https://dev.withsix.com/projects/cmb/repository/revisions/master/changes/configs/A3/unformatted/allInOne.cpp

and here is complete config for my problem

class CfgVehicles 
{
       class LandVehicle;
       class Car: LandVehicle
       {
               class NewTurret;
       };
       class Car_F: Car
       {
               class AnimationSources;
               class Turrets
               {
                       class MainTurret: NewTurret{};
               };
       };
       class MRAP_01_base_F: Car_F
       {

       };


       class MRAP_01_gmg_base_F: MRAP_01_base_F
       {
               class Turrets: Turrets
               {
                       class MainTurret: MainTurret
                       {
                       };
               };
       };

       class B_MRAP_01_gmg_F: MRAP_01_gmg_base_F
       {
       };


class B_MRAP_01_aar_F_ZYG: B_MRAP_01_gmg_F
{

	vehicleClass = "Car";
	displayName = "Hunter AAR";
	side = 1;
	faction = "BLU_F";
	crew = "B_Soldier_F";

	class Turrets: Turrets 
	{
		class MainTurret: MainTurret 
		{
			weapons[]={missiles_titan};
			magazines[]={4Rnd_Titan_long_missiles};
		};	
	};
};	
};

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×