diff options
| author | hybrid <hybrid@hybridlabs.pro> | 2026-06-11 19:38:09 +0300 |
|---|---|---|
| committer | hybrid <hybrid@hybridlabs.pro> | 2026-06-11 19:38:09 +0300 |
| commit | a3a91d4f45b22fd487ecbc954ad979be5d03efdd (patch) | |
| tree | a554ab159a347dcd6c00ca1c7c26c1ec3ac0a6bd /Client/PVFunctions/M_PLAYERS_Attack_Air.sqf | |
| download | a2wf_chernarus-main.tar.gz a2wf_chernarus-main.tar.bz2 a2wf_chernarus-main.zip | |
Diffstat (limited to 'Client/PVFunctions/M_PLAYERS_Attack_Air.sqf')
| -rw-r--r-- | Client/PVFunctions/M_PLAYERS_Attack_Air.sqf | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/Client/PVFunctions/M_PLAYERS_Attack_Air.sqf b/Client/PVFunctions/M_PLAYERS_Attack_Air.sqf new file mode 100644 index 0000000..6f14195 --- /dev/null +++ b/Client/PVFunctions/M_PLAYERS_Attack_Air.sqf @@ -0,0 +1,28 @@ +Private ['_get','_id','_label','_marker','_task'];
+
+_chopper = _this select 0;
+_label = _this select 1;
+_id = _this select 2;
+
+_get = Format["WFBE_TSK_M_%1%2",_label,_id] Call GetNamespace;
+if !(isNil '_get') exitWith {};
+
+taskHint [format [localize "str_taskNew" + "\n%1",localize 'STR_WF_M_PLAYERS_Attack_Air'], [1,1,1,1], "taskNew"];
+
+_task = player createSimpleTask [Format["TSK_M_%1%2",_label,_id]];
+[Format["WFBE_TSK_M_%1%2",_label,_id],true,true] Call SetNamespace;
+_task setSimpleTaskDescription [localize 'STR_WF_M_PLAYERS_Attack_Air_Description', localize 'STR_WF_M_PLAYERS_Attack_Air', localize 'STR_WF_M_PLAYERS_Attack_Air'];
+_task setSimpleTaskTarget [_chopper, false];
+
+//--- Wait for the result.
+waitUntil {sleep 5; !alive _chopper};
+
+_task setTaskState "Succeeded";
+taskHint [format [localize "str_taskAccomplished" + "\n%1",localize 'STR_WF_M_PLAYERS_Attack_Air'], [1,1,1,1], "taskDone"];
+
+sleep 30;
+
+[Format["WFBE_TSK_M_%1%2",_label,_id],nil,true] Call SetNamespace;
+
+//--- Remove the task & markers.
+player removeSimpleTask _task;
\ No newline at end of file |
