Advertisement
Guest User

Untitled

a guest
May 17th, 2018
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQF 0.41 KB | None | 0 0
  1.  
  2. // First methode
  3. private _loop = true;
  4. private _time = time + 30;
  5. while {_loop} do {
  6.     sleep 1;
  7.     if (player distance _pos > 30) exitWith {_loop = false;};
  8.     if (time >= _time) exitWith {_loop = false;};
  9.         /*Other condition and code*/
  10. };
  11.  
  12. // Second Methode
  13. private _loop = false;
  14. private _time = time + 30;
  15. waitUntil {
  16.     sleep 1;
  17.     ((player distance _pos > 30) || (time >= _time))
  18. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement