Skip to content

Instantly share code, notes, and snippets.

@headswe
Last active July 22, 2020 22:47
Show Gist options
  • Save headswe/788503d176e6b44907aef0f5f2296e40 to your computer and use it in GitHub Desktop.
Save headswe/788503d176e6b44907aef0f5f2296e40 to your computer and use it in GitHub Desktop.
[myGroup, ["marker_1","marker_2"]] execVM "teleport.sqf";
params ['_grp', '_dests'];
_mapPos = getMarkerPos (selectRandom _dests);
{
_unit = _x;
_uPos = _mapPos;
if(_alt > 0) then {
_uPos = _mapPos vectorAdd [random 100 - random 100,random 100 - random 100,_alt + random 15 - random 15];
} else {
_uPos = _mapPos vectorAdd [random 20 - random 20,random 20 - random 20,0];
};
_unit setpos _uPos;
} forEach (units _grp);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment