2015-01-11 16:42:31 +00:00
|
|
|
/*
|
|
|
|
Name: AGM_SwitchUnits_fnc_switchBack
|
|
|
|
|
|
|
|
Author(s):
|
|
|
|
bux578
|
|
|
|
|
|
|
|
Description:
|
|
|
|
Switches back to the original player unit
|
|
|
|
This method needs to be "spawn"ed
|
|
|
|
|
|
|
|
Parameters:
|
|
|
|
0: OBJECT - original player unit
|
|
|
|
1: OBJECT - respawned unit
|
|
|
|
|
|
|
|
Returns:
|
|
|
|
VOID
|
|
|
|
*/
|
|
|
|
|
2015-01-12 14:47:22 +00:00
|
|
|
#include "script_component.hpp"
|
|
|
|
|
2015-01-11 16:42:31 +00:00
|
|
|
private ["_originalPlayerUnit", "_currentUnit"];
|
|
|
|
_originalPlayerUnit = _this select 0;
|
|
|
|
_currentUnit = _this select 1;
|
|
|
|
|
2015-01-12 14:47:22 +00:00
|
|
|
[_originalPlayerUnit] joinSilent GVAR(OriginalGroup);
|
2015-01-11 16:42:31 +00:00
|
|
|
|
|
|
|
waitUntil {local _originalPlayerUnit};
|
|
|
|
|
|
|
|
selectPlayer _originalPlayerUnit;
|
|
|
|
|
|
|
|
deleteVehicle _currentUnit;
|