0% found this document useful (0 votes)
2 views10 pages

message

The document contains code for a user interface in a gaming environment, specifically for displaying player stats such as stamina, hunger, drink, stress, armor, and health. It utilizes the DGS (Dynamic GUI System) to create various graphical elements that represent these stats visually on the screen. The rendering function updates these elements based on the player's current status and conditions.

Uploaded by

tubecypher1400
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views10 pages

message

The document contains code for a user interface in a gaming environment, specifically for displaying player stats such as stamina, hunger, drink, stress, armor, and health. It utilizes the DGS (Dynamic GUI System) to create various graphical elements that represent these stats visually on the screen. The rendering function updates these elements based on the player's current status and conditions.

Uploaded by

tubecypher1400
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 10

player_stamina = getElementData(localPlayer, "stamina") or 100

player_hunger = getElementData(localPlayer, "hunger") or 50


player_drink = getElementData(localPlayer, "sede") or 100
player_stress = getElementData(localPlayer, "stress") or 50
player_armor = getPedArmor(localPlayer)
player_hp = getElementHealth(localPlayer)
rankplayerjf = "#0"
DGS = exports.dgs
rndRect_stress = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
image_stress = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10,
guiGetScreenSize() - 53, 120, 38, rndRect_stress, false)
rndRect_stress2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(0, 161, 255, 215))
image_stress2 = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10 -
player_stress / 100 * 120, guiGetScreenSize() - 53, player_stress / 100 * 120, 38,
rndRect_stress2, false)
rndRect2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
image2 = DGS:dgsCreateImage(guiGetScreenSize() - 170, guiGetScreenSize() - 53, 160,
38, rndRect2, false)
rndRect3 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
image3 = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10 - 20,
guiGetScreenSize() - 53, 10, 38, rndRect3, false)
image4 = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10 - 30,
guiGetScreenSize() - 43, 10, 28, rndRect3, false)
image5 = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10 - 40,
guiGetScreenSize() - 33, 10, 18, rndRect3, false)
rndRect_stamina = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_stamina2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(53, 255, 188, 255))
image_stamina = DGS:dgsCreateImage(guiGetScreenSize() - 64, guiGetScreenSize() -
95, 54, 38, rndRect_stamina, false)
image_stamina2 = DGS:dgsCreateImage(guiGetScreenSize() - 64 + 54 - player_stamina /
100 * 54, guiGetScreenSize() - 95, player_stamina / 100 * 54, 38, rndRect_stamina2,
false)
rndRect_hunger = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_hunger2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(255, 164, 81, 255))
image_hunger = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59, guiGetScreenSize()
- 95, 54, 38, rndRect_hunger, false)
image_hunger2 = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59 + 54 -
player_hunger / 100 * 54, guiGetScreenSize() - 95, player_hunger / 100 * 54, 38,
rndRect_hunger2, false)
rndRect_drink = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_drink2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(100, 91, 255, 255))
image_drink = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59 - 59,
guiGetScreenSize() - 95, 54, 38, rndRect_drink, false)
image_drink2 = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59 - 59 + 54 -
player_drink / 100 * 54, guiGetScreenSize() - 95, player_drink / 100 * 54, 38,
rndRect_drink2, false)
rndRect_armor = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_armor2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(31, 115, 179, 255))
image_armor = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59 - 59 - 59,
guiGetScreenSize() - 95, 54, 38, rndRect_armor, false)
image_armor2 = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59 - 59 - 59 + 54 -
player_armor / 100 * 54, guiGetScreenSize() - 95, player_armor / 100 * 54, 38,
rndRect_armor2, false)
rndRect_hp = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_hp2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(55, 255, 122, 255))
image_hp = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59 - 59 - 59 - 59,
guiGetScreenSize() - 95, 54, 38, rndRect_hp, false)
image_hp2 = DGS:dgsCreateImage(guiGetScreenSize() - 64 - 59 - 59 - 59 - 59 + 54 -
player_hp / 100 * 54, guiGetScreenSize() - 95, player_hp / 100 * 54, 38,
rndRect_hp2, false)
rndRect_3 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
rndRect_4 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
rndRect_5 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
image_3 = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10 - 20,
guiGetScreenSize() - 53, 10, 38, rndRect_3, false)
image_4 = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10 - 30,
guiGetScreenSize() - 43, 10, 28, rndRect_4, false)
image_5 = DGS:dgsCreateImage(guiGetScreenSize() - 170 - 120 - 10 - 40,
guiGetScreenSize() - 33, 10, 18, rndRect_5, false)
function renderinghud()
if getElementData(localPlayer, "loggedin") and getElementData(localPlayer,
"loggedin") == 1 then
if getElementData(localPlayer, "hide_hud") ~= "0" then
dxDrawText("Gold City RP", _UPVALUE0_ - 8, 25, _UPVALUE0_ - 8, 30,
tocolor(math.sin(getTickCount() / 1200) * 255, math.sin(getTickCount() / 1200) *
255 / 30, -(math.sin(getTickCount() / 1200) * 255)), 0.7, _UPVALUE1_, "right",
"top")
if isElement(image2) then
else
rndRect_stress = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
image_stress = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10, _UPVALUE2_ -
53, 120, 38, rndRect_stress, false)
rndRect_stress2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(0, 161, 255, 215))
image_stress2 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 -
(getElementData(localPlayer, "stress") or 100) / 100 * 120, _UPVALUE2_ - 53,
(getElementData(localPlayer, "stress") or 100) / 100 * 120, 38, rndRect_stress2,
false)
rndRect2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
image2 = DGS:dgsCreateImage(_UPVALUE0_ - 170, _UPVALUE2_ - 53, 160, 38,
rndRect2, false)
rndRect3 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
image3 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 20, _UPVALUE2_ -
53, 10, 38, rndRect3, false)
image4 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 30, _UPVALUE2_ -
43, 10, 28, rndRect3, false)
image5 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 40, _UPVALUE2_ -
33, 10, 18, rndRect3, false)
rndRect_stamina = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_stamina2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(53, 255, 188, 255))
image_stamina = DGS:dgsCreateImage(_UPVALUE0_ - 64, _UPVALUE2_ - 95, 54,
38, rndRect_stamina, false)
image_stamina2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 + 54 -
(getElementData(localPlayer, "stamina") or 100) / 100 * 54, _UPVALUE2_ - 95,
(getElementData(localPlayer, "stamina") or 100) / 100 * 54, 38, rndRect_stamina2,
false)
rndRect_hunger = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_hunger2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(255, 164, 81, 255))
image_hunger = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59, _UPVALUE2_ - 95,
54, 38, rndRect_hunger, false)
image_hunger2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 + 54 -
(getElementData(localPlayer, "hunger") or 100) / 100 * 54, _UPVALUE2_ - 95,
(getElementData(localPlayer, "hunger") or 100) / 100 * 54, 38, rndRect_hunger2,
false)
rndRect_drink = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_drink2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(100, 91, 255, 255))
image_drink = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59, _UPVALUE2_ -
95, 54, 38, rndRect_drink, false)
image_drink2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 + 54 -
(getElementData(localPlayer, "sede") or 100) / 100 * 54, _UPVALUE2_ - 95,
(getElementData(localPlayer, "sede") or 100) / 100 * 54, 38, rndRect_drink2, false)
rndRect_armor = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_armor2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(31, 115, 179, 255))
image_armor = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 - 59, _UPVALUE2_
- 95, 54, 38, rndRect_armor, false)
image_armor2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 - 59 + 54 -
getPedArmor(localPlayer) / 100 * 54, _UPVALUE2_ - 95, getPedArmor(localPlayer) /
100 * 54, 38, rndRect_armor2, false)
rndRect_hp = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(70, 70, 70, 215))
rndRect_hp2 = DGS:dgsCreateRoundRect({
{15, false},
{15, false},
{15, false},
{15, false}
}, tocolor(55, 255, 122, 255))
image_hp = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 - 59 - 59,
_UPVALUE2_ - 95, 54, 38, rndRect_hp, false)
image_hp2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 - 59 - 59 + 54 -
player_hp / 100 * 54, _UPVALUE2_ - 95, player_hp / 100 * 54, 38, rndRect_hp2,
false)
rndRect_3 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
rndRect_4 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
rndRect_5 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(44, 44, 44, 255))
image_3 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 20, _UPVALUE2_ -
53, 10, 38, rndRect_3, false)
image_4 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 30, _UPVALUE2_ -
43, 10, 28, rndRect_4, false)
image_5 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 40, _UPVALUE2_ -
33, 10, 18, rndRect_5, false)
end
if isElement(image_stamina2) then
destroyElement(image_stamina2)
image_stamina2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 + 54 -
(getElementData(localPlayer, "stamina") or 100) / 100 * 54, _UPVALUE2_ - 95,
(getElementData(localPlayer, "stamina") or 100) / 100 * 54, 38, rndRect_stamina2,
false)
end
if isElement(image_hunger2) then
destroyElement(image_hunger2)
image_hunger2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 + 54 -
(getElementData(localPlayer, "hunger") or 100) / 100 * 54, _UPVALUE2_ - 95,
(getElementData(localPlayer, "hunger") or 100) / 100 * 54, 38, rndRect_hunger2,
false)
end
if isElement(image_drink2) then
destroyElement(image_drink2)
image_drink2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 + 54 -
(getElementData(localPlayer, "sede") or 100) / 100 * 54, _UPVALUE2_ - 95,
(getElementData(localPlayer, "sede") or 100) / 100 * 54, 38, rndRect_drink2, false)
end
if isElement(image_armor2) then
destroyElement(image_armor2)
image_armor2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 - 59 + 54 -
getPedArmor(localPlayer) / 100 * 54, _UPVALUE2_ - 95, getPedArmor(localPlayer) /
100 * 54, 38, rndRect_armor2, false)
end
if isElement(image_armor2) then
destroyElement(image_armor2)
image_armor2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 - 59 + 54 -
getPedArmor(localPlayer) / 100 * 54, _UPVALUE2_ - 95, getPedArmor(localPlayer) /
100 * 54, 38, rndRect_armor2, false)
end
if isElement(image_hp2) then
destroyElement(image_hp2)
player_hp2 = getElementHealth(localPlayer)
image_hp2 = DGS:dgsCreateImage(_UPVALUE0_ - 64 - 59 - 59 - 59 - 59 + 54 -
player_hp2 / 100 * 54, _UPVALUE2_ - 95, player_hp2 / 100 * 54, 38, rndRect_hp2,
false)
end
if isElement(image_stress2) then
destroyElement(image_stress2)
image_stress2 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 + 120 -
(getElementData(localPlayer, "stress") or 100) / 100 * 120, _UPVALUE2_ - 53,
(getElementData(localPlayer, "stress") or 100) / 100 * 120, 38, rndRect_stress2,
false)
end
player_ping = getPlayerPing(localPlayer)
img3_c_r = 44
img3_c_g = 44
img3_c_b = 44
img4_c_r = 44
img4_c_g = 44
img4_c_b = 44
img5_c_r = 44
img5_c_g = 44
img5_c_b = 44
if player_ping > 300 then
img5_c_r = 255
img5_c_g = 20
img5_c_b = 20
elseif 120 < player_ping then
img4_c_r = 255
img4_c_g = 255
img4_c_b = 20
img3_c_r = 255
img3_c_g = 255
img3_c_b = 20
elseif 120 > player_ping then
img3_c_r = 20
img3_c_g = 255
img3_c_b = 20
img4_c_r = 20
img4_c_g = 255
img4_c_b = 20
img5_c_r = 20
img5_c_g = 255
img5_c_b = 20
end
if isElement(image_3) then
destroyElement(image_3)
destroyElement(rndRect_3)
rndRect_3 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(img3_c_r, img3_c_g, img3_c_b, 255))
image_3 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 20, _UPVALUE2_ -
53, 10, 38, rndRect_3, false)
end
if isElement(image_4) then
destroyElement(image_4)
destroyElement(rndRect_4)
rndRect_4 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(img4_c_r, img4_c_g, img4_c_b, 255))
image_4 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 30, _UPVALUE2_ -
43, 10, 28, rndRect_4, false)
end
if isElement(image_5) then
destroyElement(image_5)
destroyElement(rndRect_5)
rndRect_5 = DGS:dgsCreateRoundRect({
{5, false},
{5, false},
{5, false},
{5, false}
}, tocolor(img5_c_r, img5_c_g, img5_c_b, 255))
image_5 = DGS:dgsCreateImage(_UPVALUE0_ - 170 - 120 - 10 - 40, _UPVALUE2_ -
33, 10, 18, rndRect_5, false)
end
dxDrawImage(_UPVALUE0_ - 40, 60, 30, 18, "imgs/card.png", 0, 0, 0,
tocolor(20, 20, 255))
dxDrawText(getPlayerName(localPlayer), _UPVALUE0_ - 48, 58, _UPVALUE0_ - 48,
58, tocolor(255, 255, 255), 0.8, _UPVALUE3_, "right", "top")
dxDrawImage(_UPVALUE0_ - 38, 85, 28, 20, "imgs/bag.png", 0, 0, 0,
tocolor(255, 20, 20))
dxDrawText("" .. getTeamName(getPlayerTeam(localPlayer)), _UPVALUE0_ - 48,
84, _UPVALUE0_ - 48, 84, tocolor(255, 255, 255), 0.8, _UPVALUE3_, "right", "top")
job = getElementData(localPlayer, "job") or 0
if job == 0 then
jobName = "Bikar"
else
jobName = exports["job-system"]:getJobTitleFromID(job)
end
dxDrawImage(_UPVALUE0_ - 38, 113, 28, 20, "imgs/bag.png", 0, 0, 0,
tocolor(255, 83, 0))
dxDrawText("" .. jobName, _UPVALUE0_ - 48, 111, _UPVALUE0_ - 48, 114,
tocolor(255, 255, 255), 0.8, _UPVALUE3_, "right", "top")
playermoney = getElementData(localPlayer, "money") or 0
playerbankmoney = getElementData(localPlayer, "bankmoney") or 0
dxDrawImage(_UPVALUE0_ - 40, 136, 32, 28, "imgs/money.png", 0, 0, 0,
tocolor(20, 255, 20))
dxDrawText(formatmoney(playermoney), _UPVALUE0_ - 48, 137, _UPVALUE0_ - 48,
142, tocolor(255, 255, 255), 0.8, _UPVALUE3_, "right", "top")
dxDrawImage(_UPVALUE0_ - 38, 166, 32, 28, "imgs/bank.png", 0, 0, 0,
tocolor(59, 255, 49))
dxDrawText(formatmoney(playerbankmoney), _UPVALUE0_ - 48, 167, _UPVALUE0_ -
48, 172, tocolor(255, 255, 255), 0.8, _UPVALUE3_, "right", "top")
dxDrawImage(_UPVALUE0_ - 38, 199, 26, 22, "imgs/user2.png", 0, 0, 0,
tocolor(255, 255, 20))
dxDrawText(getElementData(localPlayer, "playerid"), _UPVALUE0_ - 44, 197,
_UPVALUE0_ - 44, 199, tocolor(255, 255, 255), 0.8, _UPVALUE3_, "right", "top")
dxDrawImage(_UPVALUE0_ - 270, _UPVALUE2_ - 84, 17, 17, "imgs/hp.png", 0, 0,
0, tocolor(255, 255, 255, 155))
dxDrawImage(_UPVALUE0_ - 210, _UPVALUE2_ - 84, 15, 19, "imgs/armor.png", 0,
0, 0, tocolor(255, 255, 255, 155))
dxDrawImage(_UPVALUE0_ - 150, _UPVALUE2_ - 84, 17, 17, "imgs/ab.png", 0, 0,
0, tocolor(255, 255, 255, 155))
dxDrawImage(_UPVALUE0_ - 93, _UPVALUE2_ - 84, 19, 17, "imgs/ghaza.png", 0, 0,
0, tocolor(255, 255, 255, 155))
dxDrawImage(_UPVALUE0_ - 35, _UPVALUE2_ - 84, 19, 17, "imgs/stamina.png", 0,
0, 0, tocolor(255, 255, 255, 215))
dxDrawImage(_UPVALUE0_ - 220, _UPVALUE2_ - 50, 32, 32, "imgs/stress.png", 0,
0, 0, tocolor(255, 255, 255, 215))
dxDrawText(string.format(" %02d:%02d", getRealTime().hour,
getRealTime().minute), _UPVALUE0_ - 90, _UPVALUE2_ - 45, _UPVALUE0_ - 90,
_UPVALUE2_ - 45, tocolor(255, 255, 255), 0.8, _UPVALUE4_, "center", "top")
elseif isElement(image2) then
destroyElement(image_stress)
destroyElement(image_stress2)
destroyElement(image3)
destroyElement(image4)
destroyElement(image5)
destroyElement(image_stamina)
destroyElement(image_stamina2)
destroyElement(image_hunger)
destroyElement(image_hunger2)
destroyElement(image_drink)
destroyElement(image_drink2)
destroyElement(image_armor)
destroyElement(image_armor2)
destroyElement(image_hp)
destroyElement(image_hp2)
destroyElement(image_3)
destroyElement(image_4)
destroyElement(image_5)
destroyElement(image2)
end
elseif isElement(image2) then
destroyElement(image_stress)
destroyElement(image_stress2)
destroyElement(image3)
destroyElement(image4)
destroyElement(image5)
destroyElement(image_stamina)
destroyElement(image_stamina2)
destroyElement(image_hunger)
destroyElement(image_hunger2)
destroyElement(image_drink)
destroyElement(image_drink2)
destroyElement(image_armor)
destroyElement(image_armor2)
destroyElement(image_hp)
destroyElement(image_hp2)
destroyElement(image_3)
destroyElement(image_4)
destroyElement(image_5)
destroyElement(image2)
end
end
addEventHandler("onClientRender", root, renderinghud)
function formatmoney(_ARG_0_)
return string.match(_ARG_0_, "^([^%d]*%d)(%d*)(.-)$") .. string.match(_ARG_0_,
"^([^%d]*%d)(%d*)(.-)$"):reverse():gsub("(%d%d%d)", "%1,"):reverse() ..
string.match(_ARG_0_, "^([^%d]*%d)(%d*)(.-)$")
end
function dxDrawRoundedRectangle(_ARG_0_, _ARG_1_, _ARG_2_, _ARG_3_, _ARG_4_,
_ARG_5_, _ARG_6_, _ARG_7_)
dxDrawRectangle(_ARG_0_ + _ARG_4_, _ARG_1_ + _ARG_4_, _ARG_2_ - _ARG_4_ * 2,
_ARG_3_ - _ARG_4_ * 2, _ARG_5_, _ARG_6_, _ARG_7_)
dxDrawCircle(_ARG_0_ + _ARG_4_, _ARG_1_ + _ARG_4_, _ARG_4_, 180, 270, _ARG_5_,
_ARG_5_, 16, 1, _ARG_6_)
dxDrawCircle(_ARG_0_ + _ARG_4_, _ARG_1_ + _ARG_3_ - _ARG_4_, _ARG_4_, 90, 180,
_ARG_5_, _ARG_5_, 16, 1, _ARG_6_)
dxDrawCircle(_ARG_0_ + _ARG_2_ - _ARG_4_, _ARG_1_ + _ARG_3_ - _ARG_4_, _ARG_4_,
0, 90, _ARG_5_, _ARG_5_, 16, 1, _ARG_6_)
dxDrawCircle(_ARG_0_ + _ARG_2_ - _ARG_4_, _ARG_1_ + _ARG_4_, _ARG_4_, 270, 360,
_ARG_5_, _ARG_5_, 16, 1, _ARG_6_)
dxDrawRectangle(_ARG_0_, _ARG_1_ + _ARG_4_, _ARG_4_, _ARG_3_ - _ARG_4_ * 2,
_ARG_5_, _ARG_6_, _ARG_7_)
dxDrawRectangle(_ARG_0_ + _ARG_4_, _ARG_1_ + _ARG_3_ - _ARG_4_, _ARG_2_ - _ARG_4_
* 2, _ARG_4_, _ARG_5_, _ARG_6_, _ARG_7_)
dxDrawRectangle(_ARG_0_ + _ARG_2_ - _ARG_4_, _ARG_1_ + _ARG_4_, _ARG_4_, _ARG_3_
- _ARG_4_ * 2, _ARG_5_, _ARG_6_, _ARG_7_)
dxDrawRectangle(_ARG_0_ + _ARG_4_, _ARG_1_, _ARG_2_ - _ARG_4_ * 2, _ARG_4_,
_ARG_5_, _ARG_6_, _ARG_7_)
end
addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()),
function()
for _FORV_3_, _FORV_4_ in ipairs(_UPVALUE0_) do
setPlayerHudComponentVisible(_FORV_4_, false)
end
end)

You might also like