Skip to content

Commit

Permalink
fix: bpt_ menu crash
Browse files Browse the repository at this point in the history
  • Loading branch information
bitpredator committed Mar 3, 2024
1 parent e859eff commit 531c379
Show file tree
Hide file tree
Showing 15 changed files with 1,756 additions and 629 deletions.
202 changes: 89 additions & 113 deletions server-data/resources/[bpt_addons]/bpt_menu/client/main.lua

Large diffs are not rendered by default.

15 changes: 1 addition & 14 deletions server-data/resources/[bpt_addons]/bpt_menu/client/utils.lua
Original file line number Diff line number Diff line change
Expand Up @@ -88,16 +88,6 @@ if Config.Framework == "esx" then
end
end

RegisterNetEvent("esx:playerLoaded", function(xPlayer)
parsePlayerData(xPlayer)

refreshMoney()

if Config.DoubleJob then
refreshMoney2()
end
end)

RegisterNetEvent("esx:setJob", function(job)
parsePlayerJob(playerData.job, job)
refreshMoney()
Expand All @@ -108,10 +98,6 @@ if Config.Framework == "esx" then
refreshMoney2()
end)

AddEventHandler("bpt_menu:menuOpening", function()
ESX.GetPlayerData()
end)

RegisterNetEvent("esx_addonaccount:setMoney", function(societyId, money)
local playerJob = GetPlayerJob()
if playerJob.isBoss and ("society_%s"):format(playerJob.id) == societyId then
Expand Down Expand Up @@ -154,5 +140,6 @@ if Config.Framework == "esx" then
Wait(100)
end
end

end)
end
Loading

0 comments on commit 531c379

Please sign in to comment.