Hallo,
ich habe für mein Vio Extended Script versucht ein eigenes Krankenhaus Bild zu machen. Habe alles eingetragen doch es will einfach nicht erscheinen. Ich schicke mal die Datei als Quellcode(deathbar_client.lua). Hoffentlich wisst ihr was ich machen muss um es zu verbessern:
Lua
function showProgressBar_func ( time )
if gWindow["reviveProgress"] then
guiSetVisible ( gWindow["reviveProgress"], true )
else
gWindow["reviveProgress"] = guiCreateWindow( 0.33, 0.34, 0.35, 0.31,"Krankenhaus Springfield",false)
guiSetAlpha(gWindow["reviveProgress"],1)
gImage["death"] = guiCreateStaticImage(0.37, 0.38, 0.29, 0.17,,"images\header_night.png",true,gWindow["reviveProgress"])
guiSetAlpha(gImage["death"],1)
gProgress["progressDeathtime"] = guiCreateProgressBar(0.12, 0.85, 0.77, 0.12,true,gWindow["reviveProgress"])
guiSetAlpha(gProgress["progressDeathtime"],1)
guiProgressBarSetProgress(gProgress["progressDeathtime"],0)
gLabel["deathbarText2"] = guiCreateLabel(0.39, 0.78, 0.26, 0.08,"Behandlungsfortschritt:",true,gWindow["reviveProgress"])
guiSetAlpha(gLabel["deathbarText2"],1)
guiLabelSetColor(gLabel["deathbarText2"],125,125,200)
guiLabelSetVerticalAlign(gLabel["deathbarText2"],"top")
guiLabelSetHorizontalAlign(gLabel["deathbarText2"],"left",false)
guiSetFont(gLabel["deathbarText2"],"default-bold-small")
end
--setTimer ( updateDeathBar_func, time*10, 100 )
--setTimer ( hideUpdateBar, time*1000, 1 )
end
addEvent ( "showProgressBar", true )
addEventHandler ( "showProgressBar", getRootElement(), showProgressBar_func )
function updateDeathBar_func ( new )
local newBarSize = new
guiProgressBarSetProgress(gProgress["progressDeathtime"],newBarSize)
if newBarSize >= 100 then
hideUpdateBar ()
end
end
addEvent ( "updateDeathBar", true )
addEventHandler ( "updateDeathBar", getRootElement(), updateDeathBar_func )
function hideUpdateBar ()
guiSetVisible ( gWindow["reviveProgress"], false )
end
Alles anzeigen
Danke im Vorraus.
MfG Tayler.