Windows Server 2019. And I run ESX legacy. I do run my server on a fairly large dedicated server. I’m going to do some tests and see if I can’t replicate issues others are having.
Assuming you are not using an older version of kashacters or something, identifiers are typically saved per character so for example when I save walk it saves to json like “char:123456”
I was thinking the same thing I have just been away from PC to test.
I’m assuming changing
RegisterServerEvent('wasabi_walk:loadWalk')
AddEventHandler('wasabi_walk:loadWalk', function()
local xPlayer = ESX.GetPlayerFromId(source)
local identifier = xPlayer.identifier
local rawData = LoadResourceFile(GetCurrentResourceName(), "./data.json")
local data = json.decode(rawData)
if data[identifier] ~= nil then
TriggerClientEvent('wasabi_walk:setWalk', source, data[identifier])
end
end)
to utilize KVP:
RegisterServerEvent('wasabi_walk:loadWalk')
AddEventHandler('wasabi_walk:loadWalk', function()
local xPlayer = ESX.GetPlayerFromId(source)
local identifier = xPlayer.identifier
local rawData = LoadResourceFile(GetCurrentResourceName(), "./data.json")
local data = json.decode(rawData)
for k,v in pairs(data) do
if k == identifier then
TriggerClientEvent('wasabi_walk:setWalk', source, v)
break
end
end
end)
Haven’t tested but looks like it would work.
It’s to note this is my first resource utilizing json and I spaced placing the data.json within the manifest files (oops).
If anyone above that was having issues can test the latest push and see if issues have resolved.