ACE3/addons/overheating/functions/fnc_swapBarrel.sqf

25 lines
600 B
Plaintext
Raw Normal View History

2015-01-16 02:36:31 +00:00
/*
* Author: Commy2
*
* Make a unit start swapping it's barrel
*
* Argument:
* 0: unit
* 1: weapon
*
* Return value:
* None
*/
#include "\z\ace\addons\overheating\script_component.hpp"
2015-01-13 03:23:14 +00:00
2015-01-16 02:36:31 +00:00
EXPLODE_2_PVT(_this,_player,_weapon);
2015-01-13 03:23:14 +00:00
if (stance _player != "PRONE") then {
[_player, "amovpknlmstpsraswrfldnon", 1] call EFUNC(common,doAnimation);
2015-01-13 03:23:14 +00:00
};
_player playActionNow "GestureDismountMuzzle";
_player playAction "GestureMountMuzzle";
playSound "ACE_BarrelSwap";
[10, [_player, _weapon], QFUNC(swapBarrelCallback), localize "STR_ACE_Overheating_SwappingBarrel"] call EFUNC(common,progressBar);