Advertisement
sonixapache

Task creation example

Mar 24th, 2014
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.08 KB | None | 0 0
  1. //task creation example (stolen from goulash)
  2.  
  3. _name = "tINTERNALTASKNAME";
  4. _desc = "LONG DESCRIPTION OF WHAT NEEDS TO HAPPEN, YOU SEE THIS IN THE TASKS MENU";
  5. _title = "SHORT DESCRIPTION -- NAME OF HEADER";
  6. _marker = "THIS IS WHAT THE PLAYER SEES ON THEIR HUD AT THE MARKER LOCATION"; //You can leave this blank
  7. _target = getMarkerPos "INSERT MARKER NAME HERE"; //pretty sure you can leave this blank too, if you don't want a target
  8. _taskParams = [true, _name, [_desc, _title, _marker], _target, "TASKSTATE"]; //CREATED, ASSIGNED, CANCELLED, FAILED, SUCCEEDED
  9.  
  10. _taskParams call BIS_fnc_taskCreate;
  11.  
  12.  
  13.  
  14.  
  15. To update a task (Success, fail, cancelled);
  16.  
  17. ["tINTERNALTASKNAME", "TASKSTATE"] call BIS_fnc_taskSetState;
  18.  
  19.  
  20. _name = "tINTERNALTASKNAME";
  21. _desc = "LONG DESCRIPTION OF WHAT NEEDS TO HAPPEN, YOU SEE THIS IN THE TASKS MENU";
  22. _title = "SHORT DESCRIPTION -- NAME OF HEADER";
  23. _marker = "THIS IS WHAT THE PLAYER SEES ON THEIR HUD AT THE MARKER LOCATION"; //You can leave this blank
  24. _taskParams = [_name,[_desc, _title, _marker]];
  25.  
  26. _taskParams call bis_fnc_setTaskDescription;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement