Jump to content

Problema HUD


Hydra

Recommended Posts

Salut, am reusit sa-mi fac un hud simplu dar cand il pornesc nu merge.

(P.S:Sunt la inceput de scripting)

 

local screenW, screenH = guiGetScreenSize()

addEventHandler("onClientRender", root, hud)

function hudrcn ()
--------------------------------------------------
local health = getElementHealth(localPlayer)
local armour = getPedArmor(localPlayer)
local currentammo = getPedAmmoInClip(localPlayer)
local maxammo = getPedTotalAmmo(localPlayer)-(currentammo)
local oxygen = getPedOxygenLevel(localPlayer)
local money = getPlayerMoney(localPlayer)
--------------------------------------------------
setPlayerHudComponentVisible("clock",false)
setPlayerHudComponentVisible("armour",false)
setPlayerHudComponentVisible("breath",false)
setPlayerHudComponentVisible("health",false)
setPlayerHudComponentVisible("money",false)
setPlayerHudComponentVisible("wanted",false)
setPlayerHudComponentVisible("weapon",false)
setPlayerHudComponentVisible("ammo",false)
----------------------------------------------------
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.0889, screenW * 0.9769, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.0889, screenW * 0.9769, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.0511, screenW * 0.1144, screenH * 0.0378, tocolor(31, 30, 31, 170), false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.0889, screenW * 0.9769, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.0889, screenW * 0.9769, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.0511, screenW * 0.1144, screenH * 0.0378, tocolor(201, 0, 0, 255), false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) - 1, (screenH * 0.0622) - 1, (screenW * 1.1019) - 1, (screenH * 0.1522) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) + 1, (screenH * 0.0622) - 1, (screenW * 1.1019) + 1, (screenH * 0.1522) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) - 1, (screenH * 0.0622) + 1, (screenW * 1.1019) - 1, (screenH * 0.1522) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) + 1, (screenH * 0.0622) + 1, (screenW * 1.1019) + 1, (screenH * 0.1522) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", screenW * 0.9000, screenH * 0.0622, screenW * 1.1019, screenH * 0.1522, tocolor(255, 254, 254, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1078, screenW * 0.1144, screenH * 0.0389, tocolor(38, 39, 38, 212), false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.1089) - 1, (screenW * 0.8625) - 1, screenH * 0.1467, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.1089) - 1, (screenW * 0.8625) - 1, (screenH * 0.1089) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.1467, screenW * 0.9769, screenH * 0.1467, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.1467, screenW * 0.9769, (screenH * 0.1089) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1089, screenW * 0.1144, screenH * 0.0378, tocolor(255, 255, 255, 187), false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) - 1, (screenH * 0.1200) - 1, (screenW * 1.0263) - 1, (screenH * 0.1844) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) + 1, (screenH * 0.1200) - 1, (screenW * 1.0263) + 1, (screenH * 0.1844) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) - 1, (screenH * 0.1200) + 1, (screenW * 1.0263) - 1, (screenH * 0.1844) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) + 1, (screenH * 0.1200) + 1, (screenW * 1.0263) + 1, (screenH * 0.1844) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", screenW * 0.9000, screenH * 0.1200, screenW * 1.0263, screenH * 0.1844, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.2011, screenW * 0.9769, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.2011, screenW * 0.9769, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1633, screenW * 0.1144, screenH * 0.0378, tocolor(66, 66, 66, 224), false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.2011, screenW * 0.9769, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.2011, screenW * 0.9769, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1633, screenW * 0.1144, screenH * 0.0378, tocolor(22, 234, 226, 246), false)
if isElementinWater(localPlayer) then
------------ Oxygen --------------------------------------------------
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 - 1, 156 - 1, 1651 - 1, 196 - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 + 1, 156 - 1, 1651 + 1, 196 - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 - 1, 156 + 1, 1651 - 1, 196 + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 + 1, 156 + 1, 1651 + 1, 196 + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440, 156, 1651, 196, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
end
---------------------------------
dxDrawText("$"..money, (screenW * 0.9000) - 1, (screenH * 0.1733) - 1, (screenW * 1.0319) - 1, (screenH * 0.2178) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.9000) + 1, (screenH * 0.1733) - 1, (screenW * 1.0319) + 1, (screenH * 0.2178) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.9000) - 1, (screenH * 0.1733) + 1, (screenW * 1.0319) - 1, (screenH * 0.2178) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.9000) + 1, (screenH * 0.1733) + 1, (screenW * 1.0319) + 1, (screenH * 0.2178) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, screenW * 0.9000, screenH * 0.1733, screenW * 1.0319, screenH * 0.2178, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) - 1, (screenH * 0.2178) - 1, (screenW * 1.0000) - 1, (screenH * 0.2578) - 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) + 1, (screenH * 0.2178) - 1, (screenW * 1.0000) + 1, (screenH * 0.2578) - 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) - 1, (screenH * 0.2178) + 1, (screenW * 1.0000) - 1, (screenH * 0.2578) + 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) + 1, (screenH * 0.2178) + 1, (screenW * 1.0000) + 1, (screenH * 0.2578) + 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, screenW * 0.8469, screenH * 0.2178, screenW * 1.0000, screenH * 0.2578, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
----------------------------------
dxDrawText("Romania Chill Nation", (screenW * 0.8375) - 1, (screenH * 0.2378) - 1, (screenW * 1.0106) - 1, (screenH * 0.2644) - 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", (screenW * 0.8375) + 1, (screenH * 0.2378) - 1, (screenW * 1.0106) + 1, (screenH * 0.2644) - 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", (screenW * 0.8375) - 1, (screenH * 0.2378) + 1, (screenW * 1.0106) - 1, (screenH * 0.2644) + 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", (screenW * 0.8375) + 1, (screenH * 0.2378) + 1, (screenW * 1.0106) + 1, (screenH * 0.2644) + 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", screenW * 0.8375, screenH * 0.2378, screenW * 1.0106, screenH * 0.2644, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) - 1, (screenH * 0.2689) - 1, (screenW * 0.9769) - 1, (screenH * 0.2933) - 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) + 1, (screenH * 0.2689) - 1, (screenW * 0.9769) + 1, (screenH * 0.2933) - 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) - 1, (screenH * 0.2689) + 1, (screenW * 0.9769) - 1, (screenH * 0.2933) + 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) + 1, (screenH * 0.2689) + 1, (screenW * 0.9769) + 1, (screenH * 0.2933) + 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, screenW * 0.8756, screenH * 0.2689, screenW * 0.9769, screenH * 0.2933, tocolor(254, 254, 254, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
    end
)

addEventHandler("onClientRender,root,hud)

function closehud()
setPlayerHudComponentVisible("clock",true)
setPlayerHudComponentVisible("armour",true)
setPlayerHudComponentVisible("breath",true)
setPlayerHudComponentVisible("health",true)
setPlayerHudComponentVisible("money",true)
setPlayerHudComponentVisible("wanted",true)
setPlayerHudComponentVisible("weapon",true)
setPlayerHudComponentVisible("ammo",true)

end
addEventHandler("onResrouceStop", root, closehud) 

Link to comment
 local screenW, screenH = guiGetScreenSize()


function hudrcn ()
--------------------------------------------------
local health = getElementHealth(localPlayer)
local armour = getPedArmor(localPlayer)
local currentammo = getPedAmmoInClip(localPlayer)
local maxammo = getPedTotalAmmo(localPlayer)-(currentammo)
local oxygen = getPedOxygenLevel(localPlayer)
local money = getPlayerMoney(localPlayer)
--------------------------------------------------
setPlayerHudComponentVisible("clock",false)
setPlayerHudComponentVisible("armour",false)
setPlayerHudComponentVisible("breath",false)
setPlayerHudComponentVisible("health",false)
setPlayerHudComponentVisible("money",false)
setPlayerHudComponentVisible("wanted",false)
setPlayerHudComponentVisible("weapon",false)
setPlayerHudComponentVisible("ammo",false)
----------------------------------------------------
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.0889, screenW * 0.9769, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.0889, screenW * 0.9769, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.0511, screenW * 0.1144, screenH * 0.0378, tocolor(31, 30, 31, 170), false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.0511) - 1, (screenW * 0.8625) - 1, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.0889, screenW * 0.9769, screenH * 0.0889, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.0889, screenW * 0.9769, (screenH * 0.0511) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.0511, screenW * 0.1144, screenH * 0.0378, tocolor(201, 0, 0, 255), false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) - 1, (screenH * 0.0622) - 1, (screenW * 1.1019) - 1, (screenH * 0.1522) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) + 1, (screenH * 0.0622) - 1, (screenW * 1.1019) + 1, (screenH * 0.1522) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) - 1, (screenH * 0.0622) + 1, (screenW * 1.1019) - 1, (screenH * 0.1522) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", (screenW * 0.9000) + 1, (screenH * 0.0622) + 1, (screenW * 1.1019) + 1, (screenH * 0.1522) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Health 0%",..math.floor(health).."%", screenW * 0.9000, screenH * 0.0622, screenW * 1.1019, screenH * 0.1522, tocolor(255, 254, 254, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1078, screenW * 0.1144, screenH * 0.0389, tocolor(38, 39, 38, 212), false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.1089) - 1, (screenW * 0.8625) - 1, screenH * 0.1467, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.1089) - 1, (screenW * 0.8625) - 1, (screenH * 0.1089) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.1467, screenW * 0.9769, screenH * 0.1467, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.1467, screenW * 0.9769, (screenH * 0.1089) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1089, screenW * 0.1144, screenH * 0.0378, tocolor(255, 255, 255, 187), false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) - 1, (screenH * 0.1200) - 1, (screenW * 1.0263) - 1, (screenH * 0.1844) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) + 1, (screenH * 0.1200) - 1, (screenW * 1.0263) + 1, (screenH * 0.1844) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) - 1, (screenH * 0.1200) + 1, (screenW * 1.0263) - 1, (screenH * 0.1844) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", (screenW * 0.9000) + 1, (screenH * 0.1200) + 1, (screenW * 1.0263) + 1, (screenH * 0.1844) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Armour 0%",..math.floor(armour).."%", screenW * 0.9000, screenH * 0.1200, screenW * 1.0263, screenH * 0.1844, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.2011, screenW * 0.9769, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.2011, screenW * 0.9769, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1633, screenW * 0.1144, screenH * 0.0378, tocolor(66, 66, 66, 224), false)
dxDrawLine((screenW * 0.8625) - 1, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, (screenH * 0.1633) - 1, (screenW * 0.8625) - 1, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine((screenW * 0.8625) - 1, screenH * 0.2011, screenW * 0.9769, screenH * 0.2011, tocolor(0, 0, 0, 255), 1, false)
dxDrawLine(screenW * 0.9769, screenH * 0.2011, screenW * 0.9769, (screenH * 0.1633) - 1, tocolor(0, 0, 0, 255), 1, false)
dxDrawRectangle(screenW * 0.8625, screenH * 0.1633, screenW * 0.1144, screenH * 0.0378, tocolor(22, 234, 226, 246), false)
if isElementinWater(localPlayer) then
------------ Oxygen --------------------------------------------------
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 - 1, 156 - 1, 1651 - 1, 196 - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 + 1, 156 - 1, 1651 + 1, 196 - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 - 1, 156 + 1, 1651 - 1, 196 + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440 + 1, 156 + 1, 1651 + 1, 196 + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Oxygen: "..math.floor(oxygen).."%", 1440, 156, 1651, 196, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
end
---------------------------------
dxDrawText("$"..money, (screenW * 0.9000) - 1, (screenH * 0.1733) - 1, (screenW * 1.0319) - 1, (screenH * 0.2178) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.9000) + 1, (screenH * 0.1733) - 1, (screenW * 1.0319) + 1, (screenH * 0.2178) - 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.9000) - 1, (screenH * 0.1733) + 1, (screenW * 1.0319) - 1, (screenH * 0.2178) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.9000) + 1, (screenH * 0.1733) + 1, (screenW * 1.0319) + 1, (screenH * 0.2178) + 1, tocolor(0, 0, 0, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, screenW * 0.9000, screenH * 0.1733, screenW * 1.0319, screenH * 0.2178, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) - 1, (screenH * 0.2178) - 1, (screenW * 1.0000) - 1, (screenH * 0.2578) - 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) + 1, (screenH * 0.2178) - 1, (screenW * 1.0000) + 1, (screenH * 0.2578) - 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) - 1, (screenH * 0.2178) + 1, (screenW * 1.0000) - 1, (screenH * 0.2578) + 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, (screenW * 0.8469) + 1, (screenH * 0.2178) + 1, (screenW * 1.0000) + 1, (screenH * 0.2578) + 1, tocolor(171, 0, 0, 252), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("$"..money, screenW * 0.8469, screenH * 0.2178, screenW * 1.0000, screenH * 0.2578, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "left", "top", false, false, false, false, false)
----------------------------------
dxDrawText("Romania Chill Nation", (screenW * 0.8375) - 1, (screenH * 0.2378) - 1, (screenW * 1.0106) - 1, (screenH * 0.2644) - 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", (screenW * 0.8375) + 1, (screenH * 0.2378) - 1, (screenW * 1.0106) + 1, (screenH * 0.2644) - 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", (screenW * 0.8375) - 1, (screenH * 0.2378) + 1, (screenW * 1.0106) - 1, (screenH * 0.2644) + 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", (screenW * 0.8375) + 1, (screenH * 0.2378) + 1, (screenW * 1.0106) + 1, (screenH * 0.2644) + 1, tocolor(221, 0, 0, 252), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText("Romania Chill Nation", screenW * 0.8375, screenH * 0.2378, screenW * 1.0106, screenH * 0.2644, tocolor(255, 255, 255, 255), 0.55, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) - 1, (screenH * 0.2689) - 1, (screenW * 0.9769) - 1, (screenH * 0.2933) - 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) + 1, (screenH * 0.2689) - 1, (screenW * 0.9769) + 1, (screenH * 0.2933) - 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) - 1, (screenH * 0.2689) + 1, (screenW * 0.9769) - 1, (screenH * 0.2933) + 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, (screenW * 0.8756) + 1, (screenH * 0.2689) + 1, (screenW * 0.9769) + 1, (screenH * 0.2933) + 1, tocolor(221, 0, 0, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
dxDrawText(currentammo.." | "..maxammo, screenW * 0.8756, screenH * 0.2689, screenW * 0.9769, screenH * 0.2933, tocolor(254, 254, 254, 252), 0.77, "bankgothic", "left", "top", false, false, false, false, false)
    end
)

addEventHandler( "onClientRender" ,root, hudrcn)

function closehud()
setPlayerHudComponentVisible("clock",true)
setPlayerHudComponentVisible("armour",true)
setPlayerHudComponentVisible("breath",true)
setPlayerHudComponentVisible("health",true)
setPlayerHudComponentVisible("money",true)
setPlayerHudComponentVisible("wanted",true)
setPlayerHudComponentVisible("weapon",true)
setPlayerHudComponentVisible("ammo",true)

end
addEventHandler("onResourceStop", resourceRoot, closehud)  

Eu nu as zice ca lai facut tu dar na.

  • Thanks 1
Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...