Advertisement
Guest User

Untitled

a guest
Mar 11th, 2019
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQF 0.69 KB | None | 0 0
  1. #include "..\..\script_macros.hpp"
  2. /*
  3.     File: fn_handleInv.sqf
  4.     Author: Bryan "Tonic" Boardwine
  5.  
  6.     Description:
  7.     Do I really need one?
  8. */
  9. private ["_math","_item","_num","_return","_var","_weight","_value","_diff"];
  10. _mode = [_this,0,false,[false]] call BIS_fnc_param; //true = add; false = SUB;
  11. _item = [_this,1,"",[""]] call BIS_fnc_param; //The item we are using to add or remove.
  12. _quantite = [_this,2,0,[0]] call BIS_fnc_param; //Number of items to add or remove.
  13. if (_item isEqualTo "" || _quantite isEqualTo 0) exitWith {false};
  14.  
  15. if (_mode isEqualTo true) then {
  16.     for "_i" from 0 to _quantite do {
  17.         player addItem _item;
  18.         player assignItem _item;
  19.     };
  20. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement