Page 1 of 1
Remove NV/IR(thermal) equipment on assembled UAV's
Posted: Sun Mar 09, 2014 4:52 pm
by head
Code: Select all
player addEventHandler ["WeaponAssembled",{
_unit = _this select 0;
_wep = _this select 1;
_type = typeName _wep;
// check if a object (might not be necessary now that it think about it, but whatever.)
if(_type == "OBJECT") then
{
// Check if a UAV
if(_wep IsKindOf "UAV_01_base_F") then
{
_wep disableTIEquipment true;
};
};
}
];
Best place would be the init for this kind of thing.
Anyway will disable NV(not sure if a bug) and thermal imagining on the small uavs that comes in backpacks. (When assembled)
Re: Remove NV/IR(thermal) equipment on assembled UAV's
Posted: Sun Mar 09, 2014 4:58 pm
by head
Example for init.sqfs
Limit to one side
Change BLUFOR to desired side
(BLUFOR,OPFOR,INDEPENDENT)
Code: Select all
if(side player == BLUFOR) then
{
player addEventHandler ["WeaponAssembled",{
_unit = _this select 0;
_wep = _this select 1;
_type = typeName _wep;
// check if a object (might not be necessary now that it think about it, but whatever.)
if(_type == "OBJECT") then
{
// Check if a UAV
if(_wep IsKindOf "UAV_01_base_F") then
{
_wep disableTIEquipment true;
};
};}];
};