AmmoLevelLow
Check if ammunition level is low
Usage: Used in 7 task(s)
Lua Implementation
-- Ammo Level Low
function evaluate(params)
local weaponSystem = this:getSystem(params.weapon_system or "Gun")
if weaponSystem then
local ammo = weaponSystem:getAmmunitionCount()
local maxAmmo = weaponSystem:getMaxAmmunition()
local lowThreshold = params.low_threshold or 0.25
return (ammo / maxAmmo) <= lowThreshold
end
return false
end
Tasks Using This Predicate (7)
Transportation Hub Destruction
Strategic Bombing (AIR DOMAIN)
Supply Line Interdiction
Deep Strike/Interdiction (AIR DOMAIN)
Railway Yard Destruction
Deep Strike/Interdiction (AIR DOMAIN)
Forward Arming and Refueling Point (FARP) Targeting
Airfield Attack (AIR DOMAIN)
Forward Resupply Operations
Logistics and Sustainment (LAND DOMAIN)
Supply Route Security
Logistics and Sustainment (LAND DOMAIN)
Interdiction Fires
Artillery and Fires Operations (LAND DOMAIN)