Jump to content
Sign in to follow this  
[KBS]snajdan

Modified Cars but the problem with randomize color

Recommended Posts

dear arma 3 modding community,

im new to arma 3 vehicle configs and trying to modify a few arma 3 vehicles for better fuel consumption in the way to create a new car which uses the original config + another skin than the original ones.

class CfgVehicles
{
class C_Hatchback_01_sport_F;	// External class reference
class KBS_Hatchback_polizei: KBS_Hatchback_01_sport_F
{
	vehicleClass = "KBS_Vehicles";
	displayName = "Hatchback RS Police";
	author = "original by BI; modified by snajdan";
	fuelCapacity = 3.5;
	fuelConsumptionRate = 22;
	hiddenSelectionsTextures[] = {"\KBS\Texturen\Cops\cop_hatchback.paa"};
	class EventHandlers {};
};
};

But if i spawn the vehicle it showing us for 1-2 seconds the new texture, but after that it takes a random one. How i can change that?

Share this post


Link to post
Share on other sites
dear arma 3 modding community,

im new to arma 3 vehicle configs and trying to modify a few arma 3 vehicles for better fuel consumption in the way to create a new car which uses the original config + another skin than the original ones.

class CfgVehicles
{
class C_Hatchback_01_sport_F;	// External class reference
class KBS_Hatchback_polizei: KBS_Hatchback_01_sport_F
{
	vehicleClass = "KBS_Vehicles";
	displayName = "Hatchback RS Police";
	author = "original by BI; modified by snajdan";
	fuelCapacity = 3.5;
	fuelConsumptionRate = 22;
	hiddenSelectionsTextures[] = {"\KBS\Texturen\Cops\cop_hatchback.paa"};
	class EventHandlers {};
};
};

But if i spawn the vehicle it showing us for 1-2 seconds the new texture, but after that it takes a random one. How i can change that?

It's actually rather easy, just define class eventHandlers with empty init like this:

class eventHandlers
{
init = "";
};

Hope it helps :icon_twisted:

Share this post


Link to post
Share on other sites

doesn't work for me

       class KBS_Hatchback_polizei: C_Hatchback_01_sport_F
{
	vehicleClass = "KBS_Vehicles";
	displayName = "Ford Fiesta RS WRC Polizei";
	author = "original by BI; modified by KBS";
	maxSpeed = 279;
	fuelCapacity = 3.5;
	fuelConsumptionRate = 22;
	maxOmega = 722.57;
	enginePower = 340;
	peakTorque = 400;
	idleRpm = 900;
	redRpm = 6900;
	hiddenSelectionsTextures[] = {"\KBS\Texturen\Cops\cop_hatchback.paa"};
	class eventHandlers
	{
		init = "";
	};

Share this post


Link to post
Share on other sites
doesn't work for me

Well, that's strange as this works fine for me (doesn't display any texture as I obviously don't have Your texture):

class cfgVehicles
{
class C_Hatchback_01_sport_F;
class KBS_Hatchback_polizei: C_Hatchback_01_sport_F
{
	displayName = "Ford Fiesta RS WRC Polizei";
	author = "original by BI; modified by KBS";
	maxSpeed = 279;
	fuelCapacity = 3.5;
	fuelConsumptionRate = 22;
	maxOmega = 722.57;
	enginePower = 340;
	peakTorque = 400;
	idleRpm = 900;
	redRpm = 6900;
	hiddenSelectionsTextures[] = {"\KBS\Texturen\Cops\cop_hatchback.paa"};
	class eventHandlers
	{
		init = "";
	};
};
};

I have just removed vehicleClass as I don't have it defined, but should not affect anything.

Share this post


Link to post
Share on other sites

can't get it to work...i tried yours and removed one of the \ at the hiddenSelectionsTextures

hiddenSelectionsTextures[] = {"KBS\Texturen\Cops\cop_hatchback.paa"};

instead of

hiddenSelectionsTextures[] = {"\KBS\Texturen\Cops\cop_hatchback.paa"};

nothing works....i looked in other car addons and all of them works but mine not o_O

Share this post


Link to post
Share on other sites

are you sure you have repacked your addon? Do you have by chance old unpacked files in your A3 folder? Unpacked files have priority over packed stuff.

Share this post


Link to post
Share on other sites

now i tried it over this eventhandler after i know that we can disable the randomization script


		class EventHandlers
		{
			init = "this setVariable [""BIS_enableRandomization"", false];";
		};

and its not working again....i looked in other addons and i see no mistake. My texture is in 2048x2048 and .paa.

If i place the vehicle in editor and preview the mission its not working how i said. BUT if im put again

this setVariable ["BIS_enableRandomization", false];

in the vehicle init and preview its working for Hatchback and Offroad but not for SUV......

edit 1:

Ok sometimes i hate it how BI do it

for suv its not camo or camo2 its camo 1.....now the SUV is working. BUT i cant disable it over eventhandler init to turn off Randomization.

It works only if i enter it in the init over the mission file but its no perfect solution for me


		class EventHandlers
		{
			init = "this setVariable [""BIS_enableRandomization"", false];";
		};

Is this right how i did it or is something broken?

edit 2:

yep got it working "perfectly"

class EventHandlers
	{
		init = "(_this select 0) setVariable [""BIS_enableRandomization"", false];";
	};

= key to success

Edited by wrongbottle

Share this post


Link to post
Share on other sites

I have same error like you ... but only since the 1.32 Arma update

I work a own personal addons with new car

Everythink was ok but since yesterday ( Arma 3 update 1.32)

70% of my custom car spawn and after 1 or 2 sec take a ??random?? skin from another ...

Share this post


Link to post
Share on other sites

hey Nark0t1k its me snajdan from AltisLifeRPG forum^^

got it working now, read the "edit 2". All working fine now :-)

Share this post


Link to post
Share on other sites

Unmasked :o

Look too fast this topics and don't see that was solve :$

Thanks to enlightened me :D

Have fun ;-)

Share this post


Link to post
Share on other sites

I've just tried this. It removes the random headgear and glasses but my unit still spawns with a random backpack :(

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  

×