Jump to content
Sign in to follow this  
cotoi

Remove NVGoogles

Recommended Posts

I want to remove NV from players so I tryed <removeAllitems this;> and <this removeItem "NVGoggles";> but player stil lspawn with nvgoggles. Any ideea how to remove this item?

Share this post


Link to post
Share on other sites

Try:

this removeWeapon "NVGoggles";

Share this post


Link to post
Share on other sites

this unassignItem "NVgoggles"; this removeItem "NVgoggles";

SavageCDN's format probably won't work, NVgoggles are considered an item and must be unassigned before they're removed.

Share this post


Link to post
Share on other sites

Yeah I'm wrong..sorry not enough coffee this AM :p

Share this post


Link to post
Share on other sites
removeAllAssignedItems this;

But that would remove their map, radio, etc as well.

Also, a handy code from 2nd Ranger:

Code:
{
       if (side _x == east) then {
               _x unassignItem "NVGoggles";
               _x removeItem "NVGoggles";
       };

} foreach allunits;

You can substitute 'east' with your faction of choice, and NVGoggles with your item of choice.

Share this post


Link to post
Share on other sites

Tnx for your help. I just wanted to make a mission where bluefor crushed before the misssion and lost about all their gear and now must do it with whatever gun they can find on the enemy. For that I use this code to control the gear for all units.

/* use this in unitt's init: Null = [this,1] execVM "echipament.sqf";*/

_man = _this select 0;

_role = _this select 1;

removeAllWeapons _man;

//blue units

if (_role == 1) then {

_man unassignItem "NVGoggles";

_man removeItem "NVGoggles";

};

if (_role == 111) then {

..................................

};

//green units

if (_role == 3101) then {

_man unassignItem "NVGoggles";

_man removeItem "NVGoggles";

_man addweapon "hgun_P07_F";

_man addmagazine "16Rnd_9x21_Mag";

_man addmagazine "16Rnd_9x21_Mag";

_man addmagazine "16Rnd_9x21_Mag";

_man addWeapon "arifle_Mk20C_ACO_pointer_F";

//_man addItem "muzzle_snds_H";

_man addMagazine "30Rnd_556x45_Stanag_Tracer_red";

_man addMagazine "30Rnd_556x45_Stanag_Tracer_red";

_man addMagazine "30Rnd_556x45_Stanag_Tracer_red";

_man addMagazine "30Rnd_556x45_Stanag_Tracer_red";

_man addMagazine "30Rnd_556x45_Stanag_Tracer_red";

};

if (_role == 3102) then {

_man unassignItem "NVGoggles";

_man removeItem "NVGoggles";

_man addweapon "hgun_P07_F";

_man addmagazine "16Rnd_9x21_Mag";

_man addmagazine "16Rnd_9x21_Mag";

_man addmagazine "16Rnd_9x21_Mag";

};

if (_role == 3103) then {

......................

};

Share this post


Link to post
Share on other sites

I kept making the mistake of trying to remove the item before unassigning it.

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  

×