mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
fix: timeout could cause being stuck with attached item
This commit is contained in:
parent
11bb1a050a
commit
84dbeb19d1
@ -11,6 +11,14 @@ _timeOut = _this select 0 select 2;
|
||||
if (time > _timeOut) exitWith {
|
||||
[_this select 1] call CBA_fnc_removePerFrameHandler;
|
||||
|
||||
// drop if in timeout
|
||||
private "_draggedObject";
|
||||
_draggedObject = _unit getVariable [QGVAR(draggedObject), objNull];
|
||||
|
||||
if (!isNull _draggedObject) exitWith {
|
||||
[_unit, _draggedObject] call FUNC(dropObject);
|
||||
};
|
||||
|
||||
// re-enable everything
|
||||
_unit setVariable [QGVAR(isDragging), false, true];
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user