wozzsta 16 Posted October 17, 2017 Hi guys, i am adapting a no fly zone script i found. i have a trigger with the condition of: "Any player - Present" And the on activation: { nul=["_x", "noFly1", "nf1"] execVM "airDamage.sqf" } forEach thisList; this calls this script: params ["_x", "_noFly", "_oaMarker"]; switch _noFly do { case "noFly1" : { private ["_playersinOA"]; _playersinOA = _oaMarker call fnc_playersinOA; ["<t color='#ff0000' size = '0.8'>Warning! You are in a no fly zone!<br />Turn back now!</t>",-1,-1,6,1,0,789] remoteExec ["BIS_fnc_dynamicText",_playersinOA,false]; sleep 5; _unit = _this select 0; _veh = vehicle _unit; _pos = getPos _unit; if ( _veh isKindOf "Air" && (_pos select 2) > 5 ) then { if (local _unit) then { _veh setDamage 1; }; }; }; }; but when it gets to the _unit, _veh and _pos variables it breaks: 15:16:57 Error in expression <leep 5; _unit = _this select 0; _veh = vehicle _unit; _pos = getPos _unit; if > 15:16:57 Error position: <vehicle _unit; _pos = getPos _unit; if > 15:16:57 Error vehicle: Type String, expected Object any ideas what i can do to fix it? im lost? Thanks. Share this post Link to post Share on other sites
pierremgi 4739 Posted October 17, 2017 { [_x, "noFly1", "nf1"] execVM "airDamage.sqf" } forEach thisList Share this post Link to post Share on other sites