I created a combo box and sent the selected data from the drop-down box to the server to learn the score of the player's money and then send and write the processor.
im not speak english im sorry Google Translate
sekmeler = guiCreateTabPanel(0, 30, 680, 490, false, pencere)
sekme1 = guiCreateTab("İstatistik", sekmeler)
playerStats = guiCreateComboBox(10, 10, 165, 175, "", false, sekme1)
for id, player in ipairs(getElementsByType("player")) do
guiComboBoxAddItem(playerStats, getPlayerName(player):gsub('#%x%x%x%x%x%x', ''))
end
puan = guiCreateLabel(225, 15, 150, 30, "1. Sıra: nil", false, sekme1)
guiSetFont(sira1, "sans")
para = guiCreateLabel(225, 45, 150, 30, "2. Sıra: nil", false, sekme1)
guiSetFont(sira2, "sans")
addEventHandler("onClientGUIClick", getRootElement(),
function()
if source == playerStats and guiComboBoxGetItemText(playerStats,guiComboBoxGetSelected(playerStats)) ~= "" then
secilenOyuncu = guiComboBoxGetItemText(playerStats,guiComboBoxGetSelected(playerStats))
triggerServerEvent("tıklandı", getLocalPlayer(), secilenOyuncu)
end
end)
function oyuncuListesiTiklandi(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9)
guiSetText(puan, arg1)
guiSetText(para, arg2)
guiSetText(kazanma, arg3)
guiSetText(olme, arg4)
guiSetText(plyZar, arg6)
guiSetText(winZar, arg7)
guiSetText(plyBet, arg8)
guiSetText(winBet, arg9)
end
addEvent("dataçek", true)
addEventHandler("dataçek", root, oyuncuListesiTiklandi)
addEvent("tıklandı",true)
addEventHandler("tıklandı",root,
function(secilenOyuncu)
current_account = getPlayerAccount(secilenOyuncu)
account = getAccountName(current_account)
puan = tonumber(getElementData(current_account, "Points") or 0)
cash = tonumber(getElementData(current_account, "Para") or 0)
win = tonumber(getAccountData(account, "kazanma") or 0)
die = tonumber(getAccountData(account, "kaybetme") or 0)
killed = tonumber(getAccountData(account, "oldurme") or 0)
tZar = tonumber(getAccountData(account, "totalZar") or 0)
wZar = tonumber(getAccountData(account, "winZar") or 0)
tBet = tonumber(getAccountData(account, "totalBet") or 0)
wBet = tonumber(getAccountData(account, "winBet") or 0)
triggerClientEvent(source,"dataçek",source,puan,cash,win,die,killed,tZar,wZar,tBet,wBet)
end)