Example Code: Remove NVGs From Enemies

From Bohemia Interactive Community
Revision as of 19:30, 17 August 2019 by Lou Montana (talk | contribs) (Page creation)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Template:Stub Template:wip

2

private _enemySide = opfor;
private _enemies = allUnits select { side _x == _enemySide; };
{
	_x unlinkItem hmd _x;
} forEach _enemies;


2

private _enemySide = east;
{
	if (side _x == _enemySide) then
	{
		_x removeWeapon "NVGoggles";
	}
} forEach allUnits;