Witam trace hp a w hudzie jest dalej 100%
[lua]function RGBToHex(red, green, blue, alpha)
if((red < 0 or red > 255 or green < 0 or green > 255 or blue < 0 or blue > 255) or (alpha and (alpha < 0 or alpha > 255))) then
return nil
end
if(alpha) then
return string.format("#%.2X%.2X%.2X%.2X", red,green,blue,alpha)
else
return string.format("#%.2X%.2X%.2X", red,green,blue)
end
end
function roundedRectangle(x, y, w, h, color)
exports["blur"]:dxDrawBluredRectangle(x, y, w, h, color, false)
exports["blur"]:dxDrawBluredRectangle(x + 2, y - 1, w - 4, 1, color, false)
exports["blur"]:dxDrawBluredRectangle(x + 2, y + h, w - 4, 1, color, false)
exports["blur"]:dxDrawBluredRectangle(x - 1, y + 2, 1, h - 4, color, false)
exports["blur"]:dxDrawBluredRectangle(x + w, y + 2, 1, h - 4, color, false)
end
local screenW, screenH = guiGetScreenSize()
local sx, sy = guiGetScreenSize()
function kursorek(psx,psy,pssx,pssy,abx,aby)
if not isCursorShowing() then return end
cx,cy=getCursorPosition()
cx,cy=cx*sx,cy*sy
if cx >= psx and cx <= psx+pssx and cy >= psy and cy <= psy+pssy then
return true,cx,cy
else
return false
end
end
Witam otoz nwm jak i gdzie wstawic element date na schowanie hudu,
element data
player:logged
[lua]--[[
Skrypt: HUD
Autor: Venteer
Dla GTAO.pl
]]
function przecinek(liczba)
local format = liczba
while true do
format, k = string.gsub(format, "^(-?%d+)(%d%d%d)", '%1,%2')
if ( k==0 ) then
break
end
end
return format
end
--Dane
local sW, sH=guiGetScreenSize() -- /1920*sW /1080*sH
local font = dxCreateFont ("files/czcionka.ttf", 30)
setElementData(localPlayer, "hud", true)
--HUD
addEventHandler("onClientRender", root, function()
setPlayerHudComponentVisible("ammo", false)
setPlayerHudComponentVisible("area_name", false)
setPlayerHudComponentVisible("armour", false)
setPlayerHudComponentVisible("breath", false)
setPlayerHudComponentVisible("clock", false)
setPlayerHudComponentVisible("health", false)
setPlayerHudComponentVisible("money", false)
setPlayerHudComponentVisible("vehicle_name", false)
setPlayerHudComponentVisible("weapon", false)
setPlayerHudComponentVisible("radio", false)
setPlayerHudComponentVisible("wanted", false)
if not getElementData(localPlayer, "hud") then return end
local health = getElementHealth(localPlayer)
health ...
Witam, posiadam problem, gdy? jak si? kto? loguje na serwer, to wida? ju? hud przy logowaniu, a chc? aby to by?o zrobione tak, aby hudu nie by?o wida? podczas logowania tylko normalnie w grze (w grze go wida? normalnie tylko chodzi o to logowanie)
Tak jak w temacie. Jest taki skrypt bo przydaloby mi sie takie cos na serwer.
po wpisaniu ./yoff chowalo by sie wszystko a po wpisaniu ./yon pokazywalo