Here are the scripts:-
The label doesn't shows the rank and deliveries.
Server:-
function bindRankInfo(player)
local accountPlayer = getPlayerAccount(player)
local rank = getAccountData(accountPlayer, "Rank")
if (rank) then
else
setAccountData(accountPlayer, "Rank", "Novice")
end
local deliveries = getAccountData(accountPlayer, "deliveries")
if (deliveries) then
else
setAccountData(accountPlayer, "deliveries", "0")
end
local team = getPlayerTeam(player)
local teamName = getTeamName(team)
if ( teamName == "Freight") then
triggerClientEvent("rankShow", player, deliveries, rank)
end
end
function binding()
bindKey(source,"F5", "up", bindRankInfo)
end
addEventHandler("onPlayerJoin", getRootElement(), binding)
Client :-
function jobRankInfo(arg1, arg2)
guiSetVisible(GUIEditor.window[2], not guiGetVisible(GUIEditor.window[2]))
guiSetText(GUIEditor.label[1], "Your Current Deliveries are :-"..arg1.." You Rank:-"..arg2)
guiSetInputEnabled(not guiGetInputEnabled)
showCursor ( not isCursorShowing ())
end
addEvent("rankShow", true)
addEventHandler("rankShow", getRootElement(), jobRankInfo)