Imorrible Posted August 24, 2019 Share Posted August 24, 2019 Gostaria de saber, como eu faço pra usar o script de fome, sede e sono de uma pessoa, com o HUD de outra pessoa que tem um script diferente. E como eu faço pra quando eu abrir a tela de compra de armas, não aparecer o HUD padrão. Obrigado desde já. Link to comment
vanessa Posted January 17, 2020 Share Posted January 17, 2020 AMIGO ESSE E O SCRIPT DA MINHA HUD QUE TO CRIANDO SEGUINTE QUANDO VOCE QUISER ADICIONAR FOME SEDE E SONO NA SUA BASTA VC DA UMA OLHADA NOS SCRIPTS DE OUTRA PESSOA E IR MONTANDO NO SEU BOM NESSE AI TODAS AS BARRAS AINDA NAO FIZ MAIS O RESTANTE DA HUD VC PODE TA PEGANDO E REFAZENDO NA SUA addEventHandler("onClientRender", root, function() local dinheiro1 = ("%008d"):format(getPlayerMoney(getLocalPlayer())) local bank = getElementData(localPlayer, "Bank:Caixa") or "0" local Procurado = getPlayerWantedLevel(localPlayer) local Emp = jobPolice or (getElementData(getLocalPlayer(), "Emprego") or "Desempregado") local showammo1 = getPedAmmoInClip (localPlayer,getPedWeaponSlot(localPlayer)) local showammo2 = getPedTotalAmmo(localPlayer)-getPedAmmoInClip(localPlayer) local showammo3 = getPedTotalAmmo(getLocalPlayer()) local arma = getWeaponNameFromID ( weapon ) local clip = getPedAmmoInClip (getLocalPlayer()) local weapon = getPedWeapon ( getLocalPlayer() ) local arma = getWeaponNameFromID ( weapon ) local ID = getElementData(localPlayer, "ID") or " N/A" -- local level = getElementData(localPlayer, "Level") or "0" dxDrawImage(1009, 38, 422, 210, ":HUD/images/fundo.png", 0, 0, 0, tocolor(3, 224, 251, 255), false) dxDrawImage(1159, 48, 111, 20, ":HUD/images/Vida.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1159, 78, 114, 21, ":HUD/images/Colete.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1159, 119, 116, 21, ":HUD/images/Fome.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1159, 150, 116, 21, ":HUD/images/Fome.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1159, 181, 116, 21, ":HUD/images/Fome.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawText("fome %", 1191, 48, 1251, 80, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawText("colete%", 1191, 83, 1251, 115, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawImage(1256, 20, 100, 109, ":HUD/images/logocat.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawText("fome%", 1196, 124, 1256, 156, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawText("sede%", 1196, 146, 1256, 178, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawText("sono%", 1196, 181, 1256, 213, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawText(ID, 1305, 223, 1360, 259, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawImage(1035, 133, 100, 97, ":HUD/icons/0.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawText("Arma: "..arma.. " || Pente: " ..tostring (showammo1).." / "..tostring (showammo2), 1025, 258, 1132, 276, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawText(dinheiro1, 1015, 48, 1091, 73, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawText(""..bank, 1015, 83, 1112, 129, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawText(Emp, 1219, 253, 1332, 287, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawImage(1122, 48, 29, 25, ":HUD/images/logodinheiro.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1122, 75, 29, 24, ":HUD/images/logobanco.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1275, 115, 29, 25, ":HUD/images/comida.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1280, 145, 24, 26, ":HUD/images/bebida.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawImage(1278, 179, 27, 24, ":HUD/images/sono.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) dxDrawText(""..Procurado, 1009, 9, 1090, 38, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false) dxDrawImage(1009, 24, 22, 14, ":HUD/images/procurado.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) function theFormat() local realtime = getRealTime() return string.format("%02d:%02d:%02d", realtime.hour, realtime.minute, realtime.second) end function chatbox() local cTime = theFormat() dxDrawText ( "Hora: "..cTime.."", 1160, 220, 1275, 238, tocolor ( 255, 255, 255, 255 ), 0.55, "bankgothic" ) end addEventHandler("onClientRender", root, chatbox) local hudTable = { "ammo", "armour", "clock", "health", "money", "weapon", "wanted", "area_name", "vehicle_name", "breath", "clock" } addEventHandler("onClientResourceStart", resourceRoot, function() for id, hudComponents in ipairs(hudTable) do setPlayerHudComponentVisible(hudComponents, false) end end ) addEventHandler("onClientResourceStop", resourceRoot, function() for id, hudComponents in ipairs(hudTable) do setPlayerHudComponentVisible(hudComponents, true) end end ) end ) Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now