Jump to content
Sign in to follow this  
brigada_spanish

Random armed civilians uniforms

Recommended Posts

How I can put random armed civilians uniforms in config.cpp? so that every time you put an armed civilian on the map is dressed differently.

I tried this way but does not work.

config.cpp

class C_man_polo_5_F_euro;
class delincuente_2 : C_man_polo_5_F_euro {
	_generalMacro = "C_man_polo_5_F_euro";
	scope = 2;
	side = 0;
	faction = "delincuentes_Brigada_Esp";
	vehicleClass = "delincuentes_Brigada_Esp_units";
	identityTypes[] = {"Language_EN_EP1", "Head_NATO"};
	faceType = "Man_A3";
	genericNames = "NATOMen";
	displayName = "Delincuente 2";
	icon = "iconMan";
	author = "Brigada_Esp";
	camouflage = 2.0;
	sensitivity = 1.0;
	nakedUniform = "U_C_Poloshirt_salmon";
	hiddenSelections[] = {"camo"};
	hiddenSelectionsTextures[] = {"a3\characters_f\Civil\Data\c_poloshirt_1_co.paa"};
	backpack = "";
	items[] = {"FirstAidKit", "FirstAidKit", "FirstAidKit"};
	respawnitems[] = {"FirstAidKit", "FirstAidKit", "FirstAidKit"};
	weapons[] = {"hgun_rook40_f"};
	respawnweapons[] = {"hgun_rook40_f"};
	magazines[] = {"16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag"};
	respawnmagazines[] = {"16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag"};
	linkeditems[] = {"ItemMap", "ItemWatch"};
	respawnLinkedItems[] = {"ItemMap", "ItemWatch"};
	class EventHandlers {init = "<handle = [_this select 0] execVM ""\mi_mod\script\random_uniform.sqf""";};
};

random_uniform.sqf

private ["_rnd1"];
_rnd1 =_this select 0; 
_rnd1 = floor random 6;
_this setObjectTextureGlobal [0, ["\a3\characters_f\Civil\Data\c_poloshirt_1_co.paa", 
"\a3\characters_f\Civil\Data\c_poloshirt_2_co.paa", 
"\a3\characters_f\Civil\Data\c_poloshirt_3_co.paa", 
"\a3\characters_f\Civil\Data\c_poloshirt_4_co.paa", 
"\a3\characters_f\Civil\Data\c_poloshirt_5_co.paa",
"\a3\characters_f\Civil\Data\c_poloshirt_6_co.paa"] select _rnd1];

Share this post


Link to post
Share on other sites

If you can wait a sec I can dig up my adaptation of the random hat script for civilians that does pretty much what you want it to do

this is for random uniforms, helmets and vests + adds a the ACP at random to the unit

/*
File: randomize_equipment.sqf
Author: pettka, modified for a different purpose by "ante"

Description:
Randomizes a headgear form _headgear array and puts it to civilian's headgear slot upon startup of mission.
_rnd1 is used to have some civilians without any headgear
_rnd2 is used to determine particular headgear from array


Parameter(s):
None

Returns:
Nothing
*/

_uniform = ["U_B_CombatUniform_mcam", "U_B_CombatUniform_sgg_vest", "U_B_CombatUniform_mcam_worn", "U_BG_Guerilla1_1", "U_BG_Guerilla2_1", "U_BG_Guerilla2_2",
		 "U_BG_Guerilla3_1", "U_BG_leader", "U_I_CombatUniform_shortsleeve", "U_I_CombatUniform", "U_I_OfficerUniform"];
_headgear = ["H_MilCap_dgtl", "H_Shemag_khk", "H_Beret_blk", "H_Booniehat_dgtl", "H_Booniehat_mcamo", "H_HelmetB",
		 "H_HelmetB_paint", "H_HelmetIA", "H_HelmetIA_net", "H_HelmetSpecB_paint2", "H_HelmetCrew_I"];
_vest = ["V_TacVestCamo_khk", "V_TacVestIR_blk", "V_TacVestIR_blk", "V_Rangemaster_belt", "V_BandollierB_blk", "V_BandollierB_oli",
	 "V_BandollierB_rgr", "V_Chestrig_blk", "V_HarnessO_brn", "V_Rangemaster_belt", "V_TacVest_blk"];
_headCount = count _headgear;
_uniformCount = count _uniform;
_vestCount = count _vest;

if (isServer) then {
BIS_randomSeed1 = [];
BIS_randomSeed2 = [];
_rnd1 = floor random _uniformCount;	
_this setVariable ["BIS_randomSeed1", _rnd1, TRUE];
_rnd2 = floor random _headCount;
_this setVariable ["BIS_randomSeed2", _rnd2, TRUE];
};

waitUntil {!(isNil {_this getVariable "BIS_randomSeed1"})};
waitUntil {!(isNil {_this getVariable "BIS_randomSeed2"})};
_randomSeed1 = _this getVariable "BIS_randomSeed1";
_randomSeed2 = _this getVariable "BIS_randomSeed2";

_magazines = magazines _this;
_items = items _this; // Medkits, ToolKits etc.
_assitems = assignedItems _this; // NVG's, GPS etc.

if (true) then {
Removeuniform _this;
Removeheadgear _this;
Removevest _this;
_this adduniform (_uniform select _randomSeed1);
_this addheadgear (_headgear select _randomSeed2);
_this addvest (_vest select (((_randomSeed1 + _randomSeed2) % (_vestCount - 1)) * (floor random _vestCount) % (_vestCount + 1 )));
};

{_this addItem _x} forEach _items;
{_this addMagazine _x} forEach _magazines;
{_this addItem _x} forEach _assitems;
{_this assignItem _x} forEach _assitems;

if (0.5 > _randomSeed1 / _headCount) then {
_this addmagazine ("9Rnd_45ACP_Mag");
_this addweapon ("hgun_ACPC2_F");
_this addmagazine ("9Rnd_45ACP_Mag");
_this addmagazine ("9Rnd_45ACP_Mag");
_this addmagazine ("9Rnd_45ACP_Mag");
};

Here's a crude random weapons version of this

/*
File: randomize_equipment.sqf
Author: pettka, modified for a different purpose by "ante"

Description:
Randomizes a headgear form _headgear array and puts it to civilian's headgear slot upon startup of mission.
_rnd1 is used to have some civilians without any headgear
_rnd2 is used to determine particular headgear from array


Parameter(s):
None

Returns:
Nothing
*/
_magazines = magazines _this;
_items = items _this; // Medkits, ToolKits etc.
_assitems = assignedItems _this; // NVG's, GPS etc.

_weaponlist = ["arifle_mx_f", "arifle_Katiba_F", "arifle_MXC_F", "arifle_Katiba_C_F",  "srifle_DMR_01_F", "arifle_MXM_F", "arifle_SDAR_F", "arifle_TRG20_F",
		 "arifle_TRG21_F", "LMG_Zafir_F", "SMG_02_F", "hgun_PDW2000_snds_F", "arifle_Mk20C_plain_F", "arifle_Mk20_F"];
_headCount = count _weaponlist;

if (isServer) then {
BIS_randomSeed1 = [];
BIS_randomSeed2 = [];
_rnd1 = floor random 3;	
_this setVariable ["BIS_randomSeed1", _rnd1, TRUE];
_rnd2 = floor random _headCount;
_this setVariable ["BIS_randomSeed2", _rnd2, TRUE];
};

waitUntil {!(isNil {_this getVariable "BIS_randomSeed1"})};
waitUntil {!(isNil {_this getVariable "BIS_randomSeed2"})};
_randomSeed1 = _this getVariable "BIS_randomSeed1";
_randomSeed2 = _this getVariable "BIS_randomSeed2";

_getweapon = (_weaponlist select _randomSeed2);

/* loaded magazine */
switch (_getweapon) do {
   case "arifle_mx_f": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXC_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_C_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXM_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "srifle_DMR_01_F": {_this addmagazine "10Rnd_762x51_Mag"};
   case "arifle_SDAR_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG21_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "LMG_Zafir_F": {_this addmagazine "150Rnd_762x51_Box"};
   case "SMG_02_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "hgun_PDW2000_snds_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "arifle_Mk20C_plain_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_Mk20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
};

if (_randomSeed1 < 6) then {
_this addweapon (_getweapon);
_this addmagazine ("9Rnd_45ACP_Mag");
_this addweapon ("hgun_ACPC2_F");
};

/* magazine 1 */
switch (_getweapon) do {
   case "arifle_mx_f": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXC_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_C_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXM_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "srifle_DMR_01_F": {_this addmagazine "10Rnd_762x51_Mag"};
   case "arifle_SDAR_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG21_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "LMG_Zafir_F": {_this addmagazine "150Rnd_762x51_Box"};
   case "SMG_02_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "hgun_PDW2000_snds_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "arifle_Mk20C_plain_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_Mk20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
};

/* magazine 2 */
switch (_getweapon) do {
   case "arifle_mx_f": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXC_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_C_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXM_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "srifle_DMR_01_F": {_this addmagazine "10Rnd_762x51_Mag"};
   case "arifle_SDAR_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG21_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "LMG_Zafir_F": {_this addmagazine "150Rnd_762x51_Box"};
   case "SMG_02_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "hgun_PDW2000_snds_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "arifle_Mk20C_plain_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_Mk20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
};

/* magazine 3 */
switch (_getweapon) do {
   case "arifle_mx_f": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXC_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_C_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXM_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "srifle_DMR_01_F": {_this addmagazine "10Rnd_762x51_Mag"};
   case "arifle_SDAR_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG21_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "LMG_Zafir_F": {_this addmagazine "150Rnd_762x51_Box"};
   case "SMG_02_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "hgun_PDW2000_snds_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "arifle_Mk20C_plain_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_Mk20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
};

/* magazine 4 */
switch (_getweapon) do {
   case "arifle_mx_f": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXC_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_C_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXM_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "srifle_DMR_01_F": {_this addmagazine "10Rnd_762x51_Mag"};
   case "arifle_SDAR_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG21_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "LMG_Zafir_F": {_this addmagazine "150Rnd_762x51_Box"};
   case "SMG_02_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "hgun_PDW2000_snds_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "arifle_Mk20C_plain_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_Mk20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
};

/* magazine 5 */
switch (_getweapon) do {
   case "arifle_mx_f": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXC_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "arifle_Katiba_C_F": {_this addmagazine "30Rnd_65x39_caseless_green"};
   case "arifle_MXM_F": {_this addmagazine "30Rnd_65x39_caseless_mag"};
   case "srifle_DMR_01_F": {_this addmagazine "10Rnd_762x51_Mag"};
   case "arifle_SDAR_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_TRG21_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "LMG_Zafir_F": {_this addmagazine "150Rnd_762x51_Box"};
   case "SMG_02_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "hgun_PDW2000_snds_F": {_this addmagazine "30Rnd_9x21_Mag"};
   case "arifle_Mk20C_plain_F": {_this addmagazine "30Rnd_556x45_Stanag"};
   case "arifle_Mk20_F": {_this addmagazine "30Rnd_556x45_Stanag"};
};

How to add it to a unit:

		class EventHandlers : EventHandlers {
		init = "(_this select 0) execVM ""\characters_a_pmc\randomize_equipment.sqf"";(_this select 0) execVM ""\characters_a_pmc\randomize_weapons.sqf""";
	}; 

EDIT 14-05-05 21:45; the script that randomize uniforms, caps and vest doesn't really randomize the vests, look at the whole script and modify it after your desire as I got no scripting skills.

Edited by ante185
More info

Share this post


Link to post
Share on other sites

Thanks ante185 for your reply has been very helpful.

Now interestingly I get this error (No entry 'config.bin/cfgVehicles/EventHandlers.scope')

I have reviewed all the scopes of soldiers and vehicles, and the numbering is correct.

Any idea to solve this?

class cfgVehicles {

class [color="#FF0000"]EventHandlers[/color];

class C_man_1;
class delincuente_2 : C_man_1 {
	_generalMacro = "C_man_1";
	[color="#FF0000"]scope[/color] = 2;
	side = 0;
	faction = "delincuentes_Brigada_Esp";
	vehicleClass = "delincuentes_Brigada_Esp_units";
	identityTypes[] = {"Language_EN_EP1", "Head_NATO"};
	faceType = "Man_A3";
	genericNames = "NATOMen";
	displayName = "Delincuente 2";
	icon = "iconMan";
	author = "Brigada_Esp";
	camouflage = 2.0;
	sensitivity = 1.0;
	nakedUniform = "U_C_Poloshirt_salmon";
	hiddenSelections[] = {"camo"};
	hiddenSelectionsTextures[] = {"a3\characters_f\Civil\Data\c_poloshirt_1_co.paa"};
	backpack = "";
	items[] = {"FirstAidKit", "FirstAidKit", "FirstAidKit"};
	respawnitems[] = {"FirstAidKit", "FirstAidKit", "FirstAidKit"};
	weapons[] = {"hgun_rook40_f"};
	respawnweapons[] = {"hgun_rook40_f"};
	magazines[] = {"16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag"};
	respawnmagazines[] = {"16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag", "16Rnd_9x21_Mag"};
	linkeditems[] = {"ItemMap", "ItemWatch"};
	respawnLinkedItems[] = {"ItemMap", "ItemWatch"};

class [color="#FF0000"]EventHandlers: EventHandlers[/color] {init = "(_this select 0) execVM ""\mi_mod\script\randomize_civ.sqf""";};
};
};

Share this post


Link to post
Share on other sites

class EventHandlers: EventHandlers {init = "(_this select 0) execVM ""\mi_mod\script\randomize_civ.sqf""";};

};

it looks like there's one too many " { }; "

That might be the problem, otherwise here's a config entry that you can look at

class rebel_F : Rebels {
	identityTypes[] = {"Head_Greek", "G_CIVIL_male"};
	faceType = "Man_A3";
	faction = rebel_blue;
	genericNames = "GreekMen";
	vehicleClass = "Men";
	scope = public;
	displayName = ALF Rebel (Unarmed);
	portrait = "\A3\characters_f\data\ui\portrait_comBarHead_civ_man_ca.paa";
	model = "\A3\Characters_F\Civil\c_poloshirt";
	modelSides[] = {3};
	nakedUniform = "U_NikosBody";
	uniformClass = "U_B_CombatUniform_mcam_worn";
	weapons[] = {"Throw", "Put"};
	respawnWeapons[] = {"Throw", "Put"};
	magazines[] = {"HandGrenade", "HandGrenade"};
	respawnMagazines[] = {"HandGrenade", "HandGrenade"};
	linkedItems[] = {"V_BandollierB_blk", "H_Booniehat_dgtl", "ItemMap", "ItemCompass", "ItemWatch", "ItemRadio"};
	respawnLinkedItems[] = {"V_BandollierB_blk", "H_Booniehat_dgtl", "ItemMap", "ItemCompass", "ItemWatch", "ItemRadio"};

	class EventHandlers : EventHandlers {
		init = "(_this select 0) execVM ""\characters_a_rebels\randomize_equipment.sqf""";
	};
	class Wounds {
		tex[] = {};
		mat[] = {"A3\Characters_F\Civil\Data\c_cloth1.rvmat", "A3\Characters_F\Civil\Data\c_cloth1_injury.rvmat", "A3\Characters_F\Civil\Data\c_cloth1_injury.rvmat", "A3\Characters_F\Civil\Data\c_cloth2.rvmat", "A3\Characters_F\Civil\Data\c_cloth2_injury.rvmat", "A3\Characters_F\Civil\Data\c_cloth2_injury.rvmat", "A3\Characters_F\Civil\Data\c_cloth3.rvmat", "A3\Characters_F\Civil\Data\c_cloth3_injury.rvmat", "A3\Characters_F\Civil\Data\c_cloth3_injury.rvmat", "A3\Characters_F\Civil\Data\c_cloth4.rvmat", "A3\Characters_F\Civil\Data\c_cloth4_injury.rvmat", "A3\Characters_F\Civil\Data\c_cloth4_injury.rvmat", "A3\characters_f\civil\data\c_poloshirt.rvmat", "A3\Characters_F\Civil\Data\c_poloshirt_injury.rvmat", "A3\Characters_F\Civil\Data\c_poloshirt_injury.rvmat", "A3\characters_f\common\data\coveralls.rvmat", "A3\Characters_F\Common\Data\coveralls_injury.rvmat", "A3\Characters_F\Common\Data\coveralls_injury.rvmat", "A3\Characters_F\Civil\Data\hunter.rvmat", "A3\Characters_F\Civil\Data\hunter_injury.rvmat", "A3\Characters_F\Civil\Data\hunter_injury.rvmat", "A3\Characters_F\Civil\Data\c_poloshirtpants.rvmat", "A3\Characters_F\Civil\Data\c_poloshirtpants_injury.rvmat", "A3\Characters_F\Civil\Data\c_poloshirtpants_injury.rvmat", "A3\Characters_F\Civil\Data\priest.rvmat", "A3\Characters_F\Civil\Data\priest_injury.rvmat", "A3\Characters_F\Civil\Data\priest_injury.rvmat", "A3\Characters_F\Heads\Data\hl_white_bald_muscular.rvmat", "A3\Characters_F\Heads\Data\hl_white_bald_muscular_injury.rvmat", "A3\Characters_F\Heads\Data\hl_white_bald_muscular_injury.rvmat", "A3\Characters_F\Heads\Data\hl_black_bald_muscular.rvmat", "A3\Characters_F\Heads\Data\hl_black_bald_muscular_injury.rvmat", "A3\Characters_F\Heads\Data\hl_black_bald_muscular_injury.rvmat", "A3\Characters_F\Heads\Data\hl_white_hairy_muscular.rvmat", "A3\Characters_F\Heads\Data\hl_white_hairy_muscular_injury.rvmat", "A3\Characters_F\Heads\Data\hl_white_hairy_muscular_injury.rvmat", "A3\Characters_F\Heads\Data\hl_white_old.rvmat", "A3\Characters_F\Heads\Data\hl_white_old_injury.rvmat", "A3\Characters_F\Heads\Data\hl_white_old_injury.rvmat", "A3\Characters_F\Heads\Data\hl_asian_bald_muscular.rvmat", "A3\Characters_F\Heads\Data\hl_asian_bald_muscular_injury.rvmat", "A3\Characters_F\Heads\Data\hl_asian_bald_muscular_injury.rvmat"};
	};
};

I don't really know how to script (And how to properly make configs) but i'll try to help as best as I can!

Share this post


Link to post
Share on other sites

Thank you very much for your interest ante185.

Parentheses are correct.

Despite the error (No entry 'config.bin/cfgVehicles/EventHandlers.scope'), the uniform civil works well.

I think the problem comes from the top of cfgVehicles

class cfgVehicles {
class [color="#FF0000"]EventHandlers;[/color]

or the beginning of class C_man_1;

class [color="#FF0000"]C_man_1[/color];
class delincuente_2 : [color="#FF0000"]C_man_1[/color] {

Share this post


Link to post
Share on other sites

I am going to take a pot shot and guess that you need to have the "class EventHandlers;" inside of a units class.

so something in the style of

class C_man_1;
class delincuente_2_BASE : C_man_1 
{
class EventHandlers;
}
class delincuente_2 : C_man_1 
{
class EventHandlers;
}

Or you'll just have to remove the external reference to "class EventHandlers;" that you have right under the cfgVehicles as the script appears to run fine which would indicate that there's already "class EventHandlers;" in C_man_1

And I just realised, there is a "class EventHandlers;" entry in C_man_1 or one of its parents which means that in

class cfgVehicles {
class EventHandlers;

class EventHandlers; <-- has to go, I think, maybe.

Share this post


Link to post
Share on other sites

Ante185 thanks, I appreciate your help.

I think that was the problem, now if works perfectly.

Regards.

Brigada_Spanish

Share this post


Link to post
Share on other sites

The above method works well for different models (just tried it in mine). I'd like to use a similar method to randomize the "camo" selections in my custom uniform: I have selections in my model "camo_shirt", "camo_vest", "camo_pants", and "camo_socks" in my uniform model. I haven't used hiddenSelectionsTextures before so I could use a hand with writing the line hiddenSelectionsTextures[] = {"ART\ART_Character\Data\Full_co.paa"}; How do I have a variation of the above randomizer assign different texture for the shirt, the pants, etc (not changing models).

Share this post


Link to post
Share on other sites

If you know how to change the hiddenselectionstexture then it should be no problem as you should be able to just replace adduniform with what ever that command might be, an frankly I got no idea!

Share this post


Link to post
Share on other sites

Solved by adding this: modelsides[] = {3,2,1,0}

Example:

class cfgVehicles {
class Cman1;
class Civilian_F : Cman1 {
	class EventHandlers; 
	[color="#0000FF"]modelsides[] = {3,2,1,0};[/color]
};
....
};

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  

×