mirror of
https://github.com/jimathy/jim_bridge.git
synced 2026-08-17 05:56:02 +01:00
move old/new qbcore info fixes
This commit is contained in:
21
wrapper.lua
21
wrapper.lua
@@ -1083,12 +1083,21 @@ function getPlayer(source) local Player = {}
|
|||||||
bank = info.Functions.GetMoney("bank"),
|
bank = info.Functions.GetMoney("bank"),
|
||||||
}
|
}
|
||||||
elseif GetResourceState(QBExport):find("start") and not GetResourceState(QBXExport):find("start") then
|
elseif GetResourceState(QBExport):find("start") and not GetResourceState(QBXExport):find("start") then
|
||||||
local info = exports[QBExport]:GetPlayer(src)
|
if Core.Functions.GetPlayer ~= nil then -- support older qb-core functions
|
||||||
Player = {
|
local info = Core.Functions.GetPlayer(src).PlayerData
|
||||||
name = info.PlayerData.charinfo.firstname.." "..info.PlayerData.charinfo.lastname,
|
Player = {
|
||||||
cash = info.PlayerData.money["cash"],
|
name = info.charinfo.firstname.." "..info.charinfo.lastname,
|
||||||
bank = info.PlayerData.money["bank"],
|
cash = info.money["cash"],
|
||||||
}
|
bank = info.money["bank"],
|
||||||
|
}
|
||||||
|
else
|
||||||
|
local info = exports[QBExport]:GetPlayer(src).PlayerData
|
||||||
|
Player = {
|
||||||
|
name = info.charinfo.firstname.." "..info.charinfo.lastname,
|
||||||
|
cash = info.money["cash"],
|
||||||
|
bank = info.money["bank"],
|
||||||
|
}
|
||||||
|
end
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
if GetResourceState(ESXExport):find("start") and ESX ~= nil then
|
if GetResourceState(ESXExport):find("start") and ESX ~= nil then
|
||||||
|
|||||||
Reference in New Issue
Block a user