mirror of
https://github.com/acemod/ACE3.git
synced 2025-07-25 04:42:48 +00:00
* run 'hemtt utils sqf case' * fix config as well * fix event casing * Update addons/towing/functions/fnc_attachRopePFH.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/refuel/functions/fnc_startNozzleInHandsPFH.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/rearm/functions/fnc_takeSuccess.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/rearm/functions/fnc_grabAmmo.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/medical_treatment/initSettings.inc.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/captives/functions/fnc_setSurrendered.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/captives/functions/fnc_handleZeusDisplayChanged.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/captives/functions/fnc_handlePlayerChanged.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/captives/functions/fnc_handlePlayerChanged.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/arsenal/functions/fnc_onArsenalOpen.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/arsenal/functions/fnc_onArsenalClose.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/spectator/functions/fnc_ui.sqf * Update addons/ui/XEH_clientInit.sqf * Update addons/ui/functions/fnc_setElements.sqf * Update addons/fcs/functions/fnc_getAngle.sqf * Update addons/fcs/functions/fnc_getAngle.sqf * Update addons/fcs/functions/fnc_getAngle.sqf * Update addons/captives/functions/fnc_handleZeusDisplayChanged.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/captives/functions/fnc_setHandcuffed.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/captives/functions/fnc_setHandcuffed.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/captives/functions/fnc_setSurrendered.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/common/functions/fnc_displayTextStructured.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/medical_treatment/initSettings.inc.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/medical_treatment/initSettings.inc.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Update addons/medical_treatment/initSettings.inc.sqf Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> --------- Co-authored-by: PabstMirror <pabstmirror@gmail.com> Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com>
40 lines
1.0 KiB
Plaintext
40 lines
1.0 KiB
Plaintext
#include "..\script_component.hpp"
|
|
/*
|
|
* Author: GitHawk
|
|
* Stores ammo in an ammo truck.
|
|
*
|
|
* Arguments:
|
|
* 0: Ammo Truck <OBJECT>
|
|
* 1: Unit <OBJECT>
|
|
*
|
|
* Return Value:
|
|
* None
|
|
*
|
|
* Example:
|
|
* [ammo_truck, player] call ace_rearm_fnc_storeAmmo
|
|
*
|
|
* Public: No
|
|
*/
|
|
|
|
params ["_truck", "_unit"];
|
|
|
|
private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull];
|
|
if (isNull _attachedDummy) exitWith {};
|
|
|
|
private _magazineClass = _attachedDummy getVariable [QGVAR(magazineClass), "#noVar"];
|
|
|
|
[
|
|
TIME_PROGRESSBAR(5),
|
|
[_unit, _truck, _attachedDummy],
|
|
{
|
|
params ["_args"];
|
|
_args params ["_unit", "_truck", "_attachedDummy"];
|
|
[_truck, (_attachedDummy getVariable [QGVAR(magazineClass), ""]), true] call FUNC(addMagazineToSupply);
|
|
[_unit, true, true] call FUNC(dropAmmo);
|
|
},
|
|
"",
|
|
format [localize LSTRING(StoreAmmoAction), _magazineClass call FUNC(getMagazineName), getText(configOf _truck >> "displayName")],
|
|
{true},
|
|
["isnotinside"]
|
|
] call EFUNC(common,progressBar);
|