inv diagnostics + repacked tables
This commit is contained in:
1 parent
c0662e1069
commit
485c2d3460
20 files changed
+69
-36
No files matched your search
@@ -1,3 +1,4 @@
|
||||
---@diagnostic disable: duplicate-set-field
|
||||
if GetResourceState('ps-inventory') ~= 'started' then return end
|
||||
|
||||
local sloth = exports['ps-inventory']
|
||||
@@ -57,7 +58,16 @@ end
|
||||
Inventory.GetItemBySlot = function(src, slot)
|
||||
local slotData = sloth:GetItemBySlot(src, slot)
|
||||
if not slotData then return {} end
|
||||
return {name = slotData.name, label = slotData.name, weight = slotData.weight, slot = slot, count = slotData.amount, metadata = slotData.info, stack = slotData.unique, description = slotData.description}
|
||||
return {
|
||||
name = slotData.name,
|
||||
label = slotData.name,
|
||||
weight = slotData.weight,
|
||||
slot = slot,
|
||||
count = slotData.amount,
|
||||
metadata = slotData.info,
|
||||
stack = slotData.unique,
|
||||
description = slotData.description
|
||||
}
|
||||
end
|
||||
|
||||
---comment
|
||||
|
||||
Reference in new issue
Block a user