Basic fuel resource and alternative to LegacyFuel, meant for use with ox_inventory.
This is an incredibly complicated task for some people, and they often ask for exports to do it. You use the native function GetVehicleFuelLevel, or you can use a statebag.
Entity(entity).state.fuelEntity(entity).state.fuel = fuelAmount