Skip to content

Instantly share code, notes, and snippets.

@nomisum
Created September 17, 2018 09:16
Show Gist options
  • Select an option

  • Save nomisum/c6c4fbc0d4c8f9ca03df692d0c050e5c to your computer and use it in GitHub Desktop.

Select an option

Save nomisum/c6c4fbc0d4c8f9ca03df692d0c050e5c to your computer and use it in GitHub Desktop.
ammo replenish loop
if (isServer) then {
this addEventhandler ["Fired", {
private _vehicle = _this select 0;
_vehicle setVehicleAmmo 0;
[_vehicle] spawn {
private _vehicle = _this select 0;
sleep 120;
_vehicle setVehicleAmmo 1;
{
["New Ammo delivered"] remoteExec ["hint", _x];
} forEach crew _vehicle;
};
}];
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment