Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 30/05/19 in Posts

  1. ســلام عليكم ورحمة الله أخبـآركم - عسساكـمء بخير موضوع اليوم عن لوحة الإهداءات ~ طـبعـا انا لا احتاج احد يجيني في التعليقات يقولي أن اللوحه تبع لسيرفر طاره ~ | gift | كلمة فتح اللوحه من اف 8 هي لتغيير الكلمة , من ملف اسمه sittingCG كل شيء عن المود موجود في هذا الرابط \ الفيديو وبالتـــوفييقء ~~ |~ الإهداءات ~| @!#DesTroyeR_,) @MrKAREEM @Mr.Falcon @DABL @KillerX @NX_CI @[AcM] - Major . @MR_Mahmoud @Ahmed Ly @MR.Mosa @N3xT @Abu-Solo @SuperX @#BrosS @iMr.WiFi..! @Mr.CnTroL @Abdul KariM و جميع أعضاء المنتدى
    1 point
  2. use this on serverside addEventHandler("onResourceStart",resourceRoot, function () for _, player in ipairs (getElementsByType("player")) do bindKey(player,"lshift", "down", function() if not isPedInVehicle(player) then return end local vehicle = getPedOccupiedVehicle(player) local accName = getAccountName ( getPlayerAccount ( player ) ) if vehicle and getVehicleController(vehicle) == player and isObjectInACLGroup("user."..accName, aclGetGroup ( "Admin" )) then local vehType = getVehicleType(vehicle) if vehType == "Plane" or vehType == "Helicopter" then return end local sx, sy, sz = getElementVelocity(vehicle) setElementVelocity(vehicle, sx, sy, sz + 0.33) end end ); end end );
    1 point
  3. Putz... ele n tava usando /ped
    1 point
  4. Testei aqui também e funcionou. Verifique se vc está na dimensão 0, perto de onde o Ped é criado (Groove Street) e execute o comando /ped
    1 point
  5. Mostrou algo no debug? Digite no console o comando info nome_do_resource e poste aqui o que mostra. Testei seu código e o comando /ped funcionou.
    1 point
  6. 1 point
  7. لا تحرجني لو سمحت
    1 point
  8. 1 point
  9. local screenW, screenH = guiGetScreenSize() local x, y = (screenW/1024), (screenH/768) local size = y*1.50 function drawText() local playerCoins = getElementData(getLocalPlayer(), "moneycoins") if not playerCoins then playerCoins = "0" end dxDrawRectangle(screenW * 0.6972, screenH * 0.0711, screenW * 0.1500, screenH * 0.0256, tocolor(0, 0, 0, 170), false) dxDrawText("Coin:", screenW * 0.7000, screenH * 0.0711, screenW * 0.7431, screenH * 0.0967, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "center", false, false, false, false, false) dxDrawText(playerCoins, screenW * 0.7431, screenH * 0.0711, screenW * 0.8472, screenH * 0.0967, tocolor(255, 255, 255, 255), 1.00, "default-bold", "center", "center", false, false, false, false, false) end addEventHandler("onClientRender", root, drawText) function getPlayerCoin() local data = getElementData(getLocalPlayer(), "moneycoins"); thePoints = tonumber(data); return thePoints end fileDelete("c_client.lua")
    1 point
  10. local playerCoins = tostring(getElementData(getLocalPlayer(), "moneycoins")) or tostring(0) Maybe this will do it
    1 point
  11. Now I do not get warning(s), but why show false instead of 0?
    1 point
  12. Instead of row 7, use local playerCoins = tostring(getElementData(getLocalPlayer(), "moneycoins"))
    1 point
  13. Lol, and when i join the game, the counter does not appear jut when i logged in, and got this warning @ Bad argument @ 'dxDrawText' [Expected string at argument 1, got nil] How to fix this? ..:s This is the client code: local screenW, screenH = guiGetScreenSize() local x, y = (screenW/1024), (screenH/768) local size = y*1.50 function drawText() local playerCoins = getPlayerCoin(getLocalPlayer()); -- local gPlayerCoins = string.format("%08d", playerCoins); dxDrawRectangle(screenW * 0.6972, screenH * 0.0711, screenW * 0.1500, screenH * 0.0256, tocolor(0, 0, 0, 170), false) dxDrawText("Coin:", screenW * 0.7000, screenH * 0.0711, screenW * 0.7431, screenH * 0.0967, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "center", false, false, false, false, false) dxDrawText(playerCoins, screenW * 0.7431, screenH * 0.0711, screenW * 0.8472, screenH * 0.0967, tocolor(255, 255, 255, 255), 1.00, "default-bold", "center", "center", false, false, false, false, false) end addEventHandler("onClientRender", root, drawText) function getPlayerCoin() local data = getElementData(getLocalPlayer(), "moneycoins"); thePoints = tonumber(data); return thePoints end fileDelete("c_client.lua") And yeah, #WeAreTheVR
    1 point
  14. now working the script, save my coins, thanks but i got a warning: "Bad argument @ 'getAccountData' [Expected account at argument 1, got boolean]" Why got this warning?
    1 point
  15. Try this: addEventHandler("onPlayerLogin", root, function() local acc = getPlayerAccount(source) local coin = getAccountData(acc, "coins") or 0 setElementData(source, "moneycoins", tonumber(coin)) end) addEventHandler("onPlayerQuit", root, function() local acc = getPlayerAccount(source) local coin = getElementData(source, "moneycoins") or 0 setAccountData(acc, "coins", tonumber(coin)) end) addEventHandler("onResourceStart", resourceRoot, function() for _, player in pairs(getElementsByType("player")) do local acc = getPlayerAccount(source) local coin = getAccountData(acc, "coins") if coin then setElementData(player, "moneycoins", tonumber(coin)) end end end)
    1 point
×
×
  • Create New...