mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
More cleanup
This commit is contained in:
parent
b5205c1fd0
commit
471d33ae32
@ -3,17 +3,12 @@
|
|||||||
|
|
||||||
[QGVAR(moveCorpse), {
|
[QGVAR(moveCorpse), {
|
||||||
params ["_corpse", "_dir", "_posATL"];
|
params ["_corpse", "_dir", "_posATL"];
|
||||||
_posATL params ["_xPos", "_yPos", "_zPos"];
|
|
||||||
|
|
||||||
if (isNull _corpse) exitWith {};
|
if (isNull _corpse) exitWith {};
|
||||||
|
|
||||||
private _currentPos = getPosATL _corpse;
|
|
||||||
|
|
||||||
// Check if the corpse is already close to the target
|
// Check if the corpse is already close to the target
|
||||||
// If so, don't teleport
|
// If so, don't teleport
|
||||||
if !(
|
if ((getPosATL _corpse) distance _posATL > 0.25) then {
|
||||||
_currentPos distance _posATL > 0.25
|
|
||||||
) then {
|
|
||||||
// Set direction before position
|
// Set direction before position
|
||||||
_corpse setDir _dir;
|
_corpse setDir _dir;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user