fnc_deployCCPLocal.sqf 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /*
  2. * Author: M3ales
  3. *
  4. * Adds the ace interaction options to the local machine, exits if its a dedicated serverCommand
  5. *
  6. * Arguments:
  7. * CCP Building
  8. * Return Value:
  9. * None
  10. *
  11. * Example:
  12. * [cursorTarget] call rd501_fnc_deployCCPLocal
  13. *
  14. * Public: No
  15. */
  16. params["_ccp"];
  17. if(isDedicated) exitWith {};
  18. _action = ["rd501_medical_ccp_bandageAll", "Bandage All Patients", "", {
  19. params ["_target", "_player", "_params"];
  20. [_player, _target, 20] call rd501_fnc_bandageAllNearbyCCP;
  21. }, {_this call rd501_fnc_canBandageNearbyCCP}, {[]}] call ace_interact_menu_fnc_createAction;
  22. [_ccp, 0, ["ACE_MainActions"], _action] call ace_interact_menu_fnc_addActionToObject;
  23. _action = ["rd501_medical_ccp_stitchAll", "Stitch All Patients", "", {
  24. params ["_target", "_player", "_params"];
  25. [_player, _target, 20] call rd501_fnc_stitchAllWoundsNearbyCCP;
  26. }, {_this call rd501_fnc_canStitchNearbyCCP}, {[]}] call ace_interact_menu_fnc_createAction;
  27. [_ccp, 0, ["ACE_MainActions"], _action] call ace_interact_menu_fnc_addActionToObject;
  28. _action = ["rd501_medical_ccp_packup", "Pack", "", {}, {true}, {[]}] call ace_interact_menu_fnc_createAction;
  29. [_ccp, 0, ["ACE_MainActions"], _action] call ace_interact_menu_fnc_addActionToObject;
  30. _action = ["rd501_medical_ccp_packupIntoVehicle", "Pack into Vehicle", "", {
  31. params ["_target", "_player", "_params"];
  32. [_target] call rd501_fnc_packupCCP;
  33. }, {true}, {[]}] call ace_interact_menu_fnc_createAction;
  34. [_ccp, 0, ["ACE_MainActions","rd501_medical_ccp_packup"], _action] call ace_interact_menu_fnc_addActionToObject;