diff --git a/addons/main/functions/api/fn_draw_circle.sqf b/addons/main/functions/api/fn_draw_circle.sqf index fb21c60..a119bb6 100644 --- a/addons/main/functions/api/fn_draw_circle.sqf +++ b/addons/main/functions/api/fn_draw_circle.sqf @@ -10,6 +10,7 @@ // 4: Stroke color as signed ARGB int (default: -1) // 5: Fill color as signed ARGB int (default: -1761607681) // 6: Stroke weight (default: 3) +// 7: Optional registration scope (default: "") // // Example: // [player, 300, "Mortar Risk Area"] call armatak_fnc_draw_circle; @@ -23,7 +24,8 @@ params [ ["_staleSeconds", 86400, [0]], ["_strokeColor", -1, [0]], ["_fillColor", -1761607681, [0]], - ["_strokeWeight", 3, [0]] + ["_strokeWeight", 3, [0]], + ["_scope", "", [""]] ]; [ @@ -37,5 +39,6 @@ params [ _fillColor, _strokeWeight, "", - "u-d-c-c" + "u-d-c-c", + _scope ] call armatak_fnc_draw_ellipse; diff --git a/addons/main/functions/api/fn_draw_ellipse.sqf b/addons/main/functions/api/fn_draw_ellipse.sqf index 155d8f8..c1cce8e 100644 --- a/addons/main/functions/api/fn_draw_ellipse.sqf +++ b/addons/main/functions/api/fn_draw_ellipse.sqf @@ -14,6 +14,7 @@ // 8: Stroke weight (default: 3) // 9: MilSym SIDC for tactical overlay (default: "") // 10: CoT type (default: "u-d-c-e") +// 11: Optional registration scope (default: "") // // Example: // [screenToWorld [0.5, 0.5], 250, 100, 45, "Support by Fire"] call armatak_fnc_draw_ellipse; @@ -31,7 +32,8 @@ params [ ["_fillColor", -1761607681, [0]], ["_strokeWeight", 3, [0]], ["_milsym", "", [""]], - ["_cotType", "u-d-c-e", [""]] + ["_cotType", "u-d-c-e", [""]], + ["_scope", "", [""]] ]; private _position = if (_center isEqualType objNull) then { @@ -63,3 +65,6 @@ private _payload = [ ]; "armatak" callExtension ["tcp_socket:draw:ellipse", [_payload]]; +[_scope, _uuid, _cotType, _realLocation select 0, _realLocation select 1, _realLocation select 2] call armatak_fnc_register_cot; + +_uuid diff --git a/addons/main/functions/api/fn_draw_polyline.sqf b/addons/main/functions/api/fn_draw_polyline.sqf index 903008f..2af136d 100644 --- a/addons/main/functions/api/fn_draw_polyline.sqf +++ b/addons/main/functions/api/fn_draw_polyline.sqf @@ -13,6 +13,7 @@ // 7: Stroke style (default: "solid") // 8: MilSym SIDC for tactical overlay (default: "") // 9: CoT type (default: "u-d-f") +// 10: Optional registration scope (default: "") // // Example: // [[pos player, screenToWorld [0.5, 0.5]], "Phase Line Blue"] call armatak_fnc_draw_polyline; @@ -29,7 +30,8 @@ params [ ["_strokeWeight", 3, [0]], ["_strokeStyle", "solid", [""]], ["_milsym", "", [""]], - ["_cotType", "u-d-f", [""]] + ["_cotType", "u-d-f", [""]], + ["_scope", "", [""]] ]; if ((count _points) < 2) exitWith {""}; @@ -76,3 +78,6 @@ private _payload = [ ]; "armatak" callExtension ["tcp_socket:draw:free", [_payload]]; +[_scope, _uuid, _cotType, _center select 0, _center select 1, _center select 2] call armatak_fnc_register_cot; + +_uuid diff --git a/addons/main/functions/api/fn_draw_rectangle.sqf b/addons/main/functions/api/fn_draw_rectangle.sqf index 0661b90..3610f54 100644 --- a/addons/main/functions/api/fn_draw_rectangle.sqf +++ b/addons/main/functions/api/fn_draw_rectangle.sqf @@ -13,6 +13,7 @@ // 7: Fill color as signed ARGB int (default: -1761607681) // 8: Stroke weight (default: 3) // 9: MilSym SIDC for tactical overlay (default: "") +// 10: Optional registration scope (default: "") // // Example: // [screenToWorld [0.5, 0.5], 200, 500, 30, "Engagement Area"] call armatak_fnc_draw_rectangle; @@ -29,7 +30,8 @@ params [ ["_strokeColor", -1, [0]], ["_fillColor", -1761607681, [0]], ["_strokeWeight", 3, [0]], - ["_milsym", "", [""]] + ["_milsym", "", [""]], + ["_scope", "", [""]] ]; private _centerPos = if (_center isEqualType objNull) then { @@ -87,3 +89,6 @@ private _payload = [ ]; "armatak" callExtension ["tcp_socket:draw:rectangle", [_payload]]; +[_scope, _uuid, "u-d-r", _centerReal select 0, _centerReal select 1, _centerReal select 2] call armatak_fnc_register_cot; + +_uuid diff --git a/addons/main/functions/api/fn_report_marker.sqf b/addons/main/functions/api/fn_report_marker.sqf index 1e7b2f8..eb9c146 100644 --- a/addons/main/functions/api/fn_report_marker.sqf +++ b/addons/main/functions/api/fn_report_marker.sqf @@ -11,6 +11,7 @@ // 3: Callsign (default: "Report") // 4: Remarks (default: "") // 5: Stale time in seconds (default: 3600) +// 6: Optional registration scope (default: "") // // Example: // [cursorObject, "enemy", "tank", "Enemy Tank", "Reported enemy tank"] call armatak_fnc_report_marker; @@ -25,13 +26,19 @@ params [ ["_kindOrCallsign", "infantry", [""]], ["_callsignOrRemarks", "Report", [""]], ["_remarksOrStaleSeconds", "", ["", 0]], - ["_staleSeconds", 3600, [0]] + ["_staleSeconds", 3600, [0, ""]], + ["_scope", "", [""]] ]; private _type = ""; private _callsign = _callsignOrRemarks; private _remarks = _remarksOrStaleSeconds; +if (_staleSeconds isEqualType "") then { + _scope = _staleSeconds; + _staleSeconds = 3600; +}; + if ((_affiliationOrType select [0, 2]) isEqualTo "a-") then { _type = _affiliationOrType; _callsign = _kindOrCallsign; @@ -93,3 +100,6 @@ private _payload = [ ]; "armatak" callExtension ["tcp_socket:cot:report_marker", [_payload]]; +[_scope, _uuid, _type, _realLocation select 0, _realLocation select 1, _realLocation select 2] call armatak_fnc_register_cot; + +_uuid