mirror of
https://github.com/valmojr/armatak.git
synced 2026-06-13 15:23:28 +00:00
added stop tcp socket function to check gvars and sto the socket
This commit is contained in:
10
addons/main/functions/api/fn_stop_tcp_socket.sqf
Normal file
10
addons/main/functions/api/fn_stop_tcp_socket.sqf
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
_armatak_tcp_socket_is_running = missionNamespace getVariable "_armatak_tcp_socket_is_running";
|
||||||
|
|
||||||
|
if (_armatak_tcp_socket_is_running) then {
|
||||||
|
missionNamespace setVariable ["_armatak_tcp_socket_is_running", false];
|
||||||
|
|
||||||
|
"armatak" callExtension ["tcp_socket:stop", []];
|
||||||
|
} else {
|
||||||
|
_warning = format ["<t color='#FF0021'>ARMATAK</t><br/> %1", "There is no TCP Socket running to be stopped"];
|
||||||
|
[[_warning, 1.5]] call CBA_fnc_notify;
|
||||||
|
};
|
||||||
Reference in New Issue
Block a user