Skip to content

Instantly share code, notes, and snippets.

moveToGroupMarker = {
if (typeName _this != "OBJECT") then {
_this = player
};
_pos = getMarkerPos format["#RESPAWN#%1",group _this]; //get respawn marker position
if (_pos isEqualTo [0,0,0]) exitWith {}; //if pos == [0,0,0] no marker exists, exit
_this setVehiclePosition [_pos,[],5]; //set player position to within 5 meter radius at marker pos
_this setDir random 360; //set ranom player direction
};