update bags

This commit is contained in:
Bunny67
2018-07-08 10:49:19 +03:00
parent 9f756d4098
commit d8539f81fe
3 changed files with 11 additions and 8 deletions
+7
View File
@@ -279,6 +279,13 @@ local bagTypes = {
}
function GetItemFamily(id)
if not id then return end
if type(id) == "table" or type(id) == "function" then return end
if type(id) == "string" then
id = match(id, "item:(%d+)")
end
local _, _, _, _, _, itemType = GetItemInfo(id)
return bagTypes[itemType]
end