File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ cache = {
1919 supportedInventories = {
2020 ' ox_inventory' ,
2121 ' qb-inventory' ,
22+ ' qs-inventory' ,
2223 ' es_extended' ,
2324 ' origen_inventory' ,
2425 ' codem-inventory'
@@ -130,6 +131,12 @@ local function detectInventory(inventory)
130131 end
131132 end
132133
134+ local function detectQsInventory ()
135+ if GetResourceState (' qs-inventory' ) == ' started' then
136+ return true
137+ end
138+ end
139+
133140 local function detectESXInventory ()
134141 if GetResourceState (' es_extended' ) == ' started' then
135142 return true
@@ -160,6 +167,16 @@ local function detectInventory(inventory)
160167 it .inventory = ' qb'
161168 return qb
162169 end
170+
171+ local qs = detectQsInventory ()
172+ if qs then
173+ if it .core == ' qb-core' then
174+ it .inventory = ' qb'
175+ else
176+ it .inventory = ' esx'
177+ end
178+ return qs
179+ end
163180
164181 local esx = detectESXInventory ()
165182 if esx then
@@ -196,6 +213,16 @@ local function detectInventory(inventory)
196213 it .inventory = ' qb'
197214 return qb
198215 end
216+ elseif inventory == ' qs-inventory' then
217+ local qs = detectQsInventory ()
218+ if qs then
219+ if it .core == ' qb-core' then
220+ it .inventory = ' qb'
221+ else
222+ it .inventory = ' esx'
223+ end
224+ return qs
225+ end
199226 elseif inventory == ' es_extended' then
200227 local esx = detectESXInventory ()
201228 if esx then
You can’t perform that action at this time.
0 commit comments