storageRemove
exports['RiP-Weed']:storageRemove(farmId, itemName, itemAmount, itemType, cb)
This function removes an item from a farm's storage
Arguments
Name | Type | Optional | Explenation |
---|---|---|---|
farmId | Integer | No | Farm id |
itemName | String | No | Item name |
itemAmount | Integer | No | Item amount |
itemType | String | No | Item type (seed , bud , equip , craft ) |
cb | Function | Yes | Callback function |
Returned Table
Returns loadStorage()
or false
on error
Example
exports['RiP-Weed']:storageRemove(1, 'purple_queen', 9, 'seed', function(callback)
if callback then
-- update database storage
print("storage item successfully removed")
end
end)