Buenas estoy haciendo un HUD, entonces quiero que cuando un usuario use drogas la god por ejemplo le suba el health a 200, pero la barra solo llega a 100 y no se como hacer que se multiplique, tengo esto como le puedo asignar el resto los otros 100 para los 200?:
local vida = getElementHealth(getLocalPlayer())
BrrVida = 207*(vida/200)
local prueba = getPedStat(getLocalPlayer(), 24)
if prueba == 100 then
outputChatBox("cierto")
end
local maxhealth = 100 + (prueba - 569)
----------------------------------------------------------------- vida ----------------------------------------------------------------------
dxDrawImage((sx/x)*1130, (sy/y)*72, (sx/x)*BrrVida, (sy/y)*25, "Fondo/vida.png", 0, 0, 0, tocolor(255, 255, 255, 255), false)
dxDrawText("Vida: "..math.ceil(vida), (sx/x)*1133, (sy/y)*75, (sx/x)*1291, (sy/y)*91, tocolor(0, 0, 0, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false)
dxDrawText("Vida: "..math.ceil(vida), (sx/x)*1135, (sy/y)*75, (sx/x)*1293, (sy/y)*91, tocolor(0, 0, 0, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false)
dxDrawText("Vida: "..math.ceil(vida), (sx/x)*1133, (sy/y)*77, (sx/x)*1291, (sy/y)*93, tocolor(0, 0, 0, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false)
dxDrawText("Vida: "..math.ceil(vida), (sx/x)*1135, (sy/y)*77, (sx/x)*1293, (sy/y)*93, tocolor(0, 0, 0, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false)
dxDrawText("Vida: "..math.ceil(vida), (sx/x)*1134, (sy/y)*76, (sx/x)*1292, (sy/y)*92, tocolor(255, 255, 255, 255), 1.00, "default-bold", "left", "top", false, false, false, false, false)