Forum Jump :

Author Message


Posts: 1
Rank:


Level: Member

Country: at
Location: Vienna
Occupation:
Age:
In-game name: Blue

 
#1 Posted at 2013-03-22 12:06        
     
Hello,

I'm new to this forum and I wanna ask my first question.
I want to spawn an empty OPFOR unit.
A unit without any weapon, magazine or item.

If i write clearWeaponCargo this; into the initialization field
of my OPFOR unit nothing happens. The same to
clearItemCargo this; .

What did i do wrong?
Or how can i get the result i want ?

I googled but i only found clearWeaponCargo and clearItemCargo :/

thanks,
CSM. Blue


Author Message


Posts: 11
Rank:


Level: Member

Country: us
Location: PA
Occupation:
Age: 59
In-game name: Scotty

 
#2 Posted at 2013-07-01 04:24        
     
put all you want to in the init field of the unit
/////////////////////////////////////////////////////
this unassignItem "NVGoggles";
this removeItems "NVGoggles";
this unassignItem "ItemGPS";
this removeItems "ItemGPS";
removeallweapons this;
removeBackpack this;
removeheadgear this;
removeuniform this;
removevest this;

//////use what u need////////////

this addHeadgear "";
this addUniform "";
this addWeapon "Binocular";
this addItem "FirstAidKit";
this addMagazine "HandGrenade";
this addVest "V_TacVest_oli";
this addBackpack "B_FieldPack_blk";
{this addMagazine "30Rnd_65x39_caseless_green"} forEach [1,2,3,4,5,6,7,8,9,10,11,12];
{this addMagazine "HandGrenade"} forEach [1,2,3,4];
this addWeapon "arifle_Khaybar_F";


Advertisement


Author Message


Posts: 11
Rank:


Level: Member

Country: us
Location: PA
Occupation:
Age: 59
In-game name: Scotty

 
#3 Posted at 2019-11-16 19:12        
     
my new way

comment "by Scotty WEST Medic";
player SetDamage 0;
removeAllWeapons player;
removeAllItems player;
removeAllAssignedItems player;
removeUniform player;
removeVest player;
removeBackpack player;
removeHeadgear player;
removeGoggles player;
player forceAddUniform "U_B_CombatUniform_mcam";
for "_i" from 1 to 5 do {player addItemToUniform "FirstAidKit";};
player addVest "V_BandollierB_khk";
for "_i" from 1 to 8 do {player addItemToVest "30Rnd_65x39_caseless_mag_Tracer";};
player addBackpack "B_Carryall_mcamo";
player addItemToBackpack "NVGoggles";
player addItemToBackpack "optic_Hamr";
player addItemToBackpack "acc_flashlight";
player addItemToBackpack "Medikit";
for "_i" from 1 to 5 do {player addItemToBackpack "FirstAidKit";};
for "_i" from 1 to 10 do {player addItemToBackpack "30Rnd_65x39_caseless_mag_Tracer";};
for "_i" from 1 to 6 do {player addItemToBackpack "HandGrenade";};
for "_i" from 1 to 2 do {player addItemToBackpack "SmokeShell";};
player addHeadgear "H_Booniehat_mcamo";
player addWeapon "arifle_MXM_Black_F";
player addWeapon "Binocular";
player linkItem "ItemMap";
player linkItem "ItemCompass";
player linkItem "ItemWatch";
player linkItem "ItemRadio";
player linkItem "ItemGPS";
player selectWeapon "arifle_MXM_Black_F";

Added 1 minute later:

in the onPlayerRespawn.sqf