# HG changeset patch
# User almikes@aol.com
# Date 1438086623 0
# Node ID c002f49283c661429cde978423bf49b452ad907d
# Parent 83ede97a33c6fa9fb5bf794523009c741eb44e61
Add SetAmmoDelay
diff -r 83ede97a33c6 -r c002f49283c6 LuaAPI.wiki
--- a/LuaAPI.wiki Tue Jul 28 11:44:47 2015 +0000
+++ b/LuaAPI.wiki Tue Jul 28 12:30:23 2015 +0000
@@ -343,7 +343,7 @@
=== !SpawnAmmoCrate(x, y, ammoType) ===
Spawns an ammo crate at the specified position with content of ammoType (see [AmmoTypes Ammo Types]). If `x` and `y` are set to 0, the crate will spawn on a random position (but always on land).
-Because by default settings the number of ammo in crates is zero it has to be increased to at least one with SetAmmo first, see the example:
+Because by default settings the number of ammo in crates is zero it has to be increased to at least one with `SetAmmo` first, see the example:
Example:
@@ -626,6 +626,9 @@
SetAmmo(amShotgun, 9, 0, 0, 0) -- unlimited amount of shotgun ammo for players
SetAmmo(amGrenade, 0, 0, 0, 3) -- crates should contain always three grenade
+=== !SetAmmoDelay(ammoType, delay) ===
+Changes the delay of a specified [AmmoTypes Ammo Type].
+
=== !AddAmmo(gearUid, ammoType, ammoCount) (0.9.16) ===
Adds `ammoType` to the specified gear. The amount added is determined by the arguments passed via `SetAmmo()` in the `onAmmoStoreInit()` event handler. In 0.9.16 ammo can be set directly via the optional third parameter, `ammoCount`. A value of 0 will remove the weapon, a value of 100 will give infinite ammo.