From 5ac49e12f8d94a264c813e1c0fbf3d0384a4a061 Mon Sep 17 00:00:00 2001 From: Valmo Trindade Date: Wed, 26 Nov 2025 20:21:09 -0300 Subject: [PATCH] customized sensor markers to dont cheat enemy info --- .../extract_data/fn_extract_sensor_data.sqf | 30 ++++++++++++------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/addons/main/functions/extract_data/fn_extract_sensor_data.sqf b/addons/main/functions/extract_data/fn_extract_sensor_data.sqf index e9f7227..5cfe46d 100644 --- a/addons/main/functions/extract_data/fn_extract_sensor_data.sqf +++ b/addons/main/functions/extract_data/fn_extract_sensor_data.sqf @@ -3,15 +3,25 @@ params["_unit"]; _target = getSensorTargets (_unit); { - _unit = _x select 0; - _position = _x select 1; - _status = _x select 2; + _unit = _x select 0; + _position = _x select 1; + _status = _x select 2; - if (isNil {_unit getVariable "armatak_current_side"}) then { - _unit setVariable ["armatak_current_side", side _unit]; - }; + if (isNil { + _unit getVariable "armatak_current_side" + }) then { + _unit setVariable ["armatak_current_side", side _unit]; + }; - if (_status != "destroyed") then { - _unit call armatak_fnc_send_enemy_cot; - }; -} forEach _target; + if (_status != "destroyed" && !(_unit in armatak_server_syncedUnits)) then { + _unit_position = _unit call armatak_client_fnc_extractClientPosition; + + _uuid = _unit call armatak_fnc_extract_uuid; + _type = _unit call armatak_fnc_extract_role; + _callsign = getText (configOf _unit >> "displayName"); + + _marker_cot = [_uuid, _type, _unit_position select 1, _unit_position select 2, _unit_position select 3, _callsign, _unit_position select 5, _unit_position select 6]; + + "armatak" callExtension ["tcp_socket:send_marker_cot", [_marker_cot]]; + }; +} forEach _target; \ No newline at end of file