From d52574a3ce0d0f4d71f9ded37e36f7c56e64c0a9 Mon Sep 17 00:00:00 2001 From: MrNewb <47620135+MrNewb@users.noreply.github.com> Date: Thu, 10 Apr 2025 07:04:46 -0400 Subject: [PATCH] jpr seems to be qb only so updating this for image pathing --- modules/inventory/jpr-inventory/client.lua | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/modules/inventory/jpr-inventory/client.lua b/modules/inventory/jpr-inventory/client.lua index 42f6c98..7f1afdd 100644 --- a/modules/inventory/jpr-inventory/client.lua +++ b/modules/inventory/jpr-inventory/client.lua @@ -24,3 +24,17 @@ Inventory.GetImagePath = function(item) local imagePath = file and string.format("nui://jpr-inventory/html/images/%s.png", item) return imagePath or "https://avatars.githubusercontent.com/u/47620135" end + +Inventory.GetItemInfo = function(item) + local itemData = Framework.Shared.Items[item] + if not itemData then return {} end + local repackedTable = { + name = itemData.name, + label = itemData.label, + stack = itemData.unique, + weight = itemData.weight, + description = itemData.description, + image = Inventory.GetImagePath(itemData.name) + } + return repackedTable +end \ No newline at end of file