Skip to content

Commit

Permalink
Merge pull request #26 from Jordan2139/master
Browse files Browse the repository at this point in the history
v.1.4.5 - Add support for core_inventory
  • Loading branch information
DawsonGodin authored Dec 11, 2023
2 parents cae4123 + 86fe547 commit 42644a0
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion sonorancms/fxmanifest.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ games {'gta5'}
author 'Sonoran Software Systems'
real_name 'Sonoran CMS FiveM Integration'
description 'Sonoran CMS to FiveM translation layer'
version '1.4.4'
version '1.4.5'
lua54 'yes'

server_scripts {'server/*.lua', 'config.lua', 'server/util/unzip.js', 'server/util/http.js', 'server/util/sonoran.js', 'server/util/utils.js', '@oxmysql/lib/MySQL.lua', 'server/util/imageHandler.js', 'server/modules/**/*_sv.js', 'server/modules/**/*_sv.lua'}
Expand Down
6 changes: 3 additions & 3 deletions sonorancms/server/pushEvents.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1370,11 +1370,11 @@ function manuallySendPayload()
end)
end
if GetResourceState('qb-core') == 'started' then
if GetResourceState('qb-inventory') ~= 'started' and GetResourceState('ox_inventory') ~= 'started' and GetResourceState('qs-inventory') ~= 'started' and GetResourceState('ps-inventory') ~= 'started' and GetResourceState('origen_inventory') ~= 'started' then
if GetResourceState('qb-inventory') ~= 'started' and GetResourceState('ox_inventory') ~= 'started' and GetResourceState('qs-inventory') ~= 'started' and GetResourceState('ps-inventory') ~= 'started' and GetResourceState('origen_inventory') ~= 'started' and GetResourceState('core_inventory') ~= 'started' then
TriggerEvent('SonoranCMS::core:writeLog', 'warn',
'Skipping payload send due to qb-inventory, qs-inventory, ps-inventory, ox_inventory and origen_inventory not being started. If you do not use the SonoranCMS Game Panel you can ignore this.')
'Skipping payload send due to qb-inventory, qs-inventory, ps-inventory, ox_inventory, origen_inventory and core_inventory not being started. If you do not use the SonoranCMS Game Panel you can ignore this.')
Config.critErrorGamestate = true
Config.gameStateError = {code = 'ERR_INVENTORY_NOT_STARTED', message = 'qb-inventory, qs-inventory, ps-inventory, ox_inventory and origen_inventory are not started.'}
Config.gameStateError = {code = 'ERR_INVENTORY_NOT_STARTED', message = 'qb-inventory, qs-inventory, ps-inventory, ox_inventory, origen_inventory and core_inventory are not started.'}
return
end
if GetResourceState('qb-garages') ~= 'started' and GetResourceState('cd_garage') ~= 'started' and GetResourceState('qs-advancedgarages') ~= 'started' and GetResourceState('jg-advancedgarages')
Expand Down
2 changes: 2 additions & 0 deletions sonorancms/server/server.lua
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ SetHttpHandler(function(req, res)
imagePath = GetResourcePath('qs-inventory') .. '/html/' .. path .. '.png'
elseif GetResourceState('origen_inventory') == 'started' then
imagePath = GetResourcePath('origen_inventory') .. '/html/' .. path .. '.png'
elseif GetResourceName('core_inventory') == 'started' then
imagePath = GetResourcePath('core_inventory') .. '/html/' .. path .. '.png'
end
if not path or not imagePath then
res.send(json.encode({
Expand Down
2 changes: 1 addition & 1 deletion sonorancms/version.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"resource": "1.4.4",
"resource": "1.4.5",
"testedFxServerVersion": "6683"
}

0 comments on commit 42644a0

Please sign in to comment.