Witam tak jak w temacie chce zrobi? ?wiate?ko w temacie. Lecz gdy syrena jest wy??czona by ?wieci?o si? na zielno, a gdy jest w??czona na czerwono jak to zrobi? w tym skrypcie ? Za pomoc oraz
CLIENT
[lua]
x,y = guiGetScreenSize()
button = guiCreateButton(627/1440*x, 510/900*y, 209/1440*x, 123/900*y, "Uruchom Syrene", false)
guiSetProperty(button, "NormalTextColour", "FFAAAAAA")
guiSetVisible(button, false)
function drawSyrena()
dxDrawRectangle(600/1440*x, 278/900*y, 261/1440*x, 372/900*y, tocolor(0, 0, 33, 184), false)
dxDrawRectangle(590/1440*x, 265/900*y, 289/1440*x, 16/900*y, tocolor(187, 0, 0, 255), false)
dxDrawText("Syrena OSP Fort Carson", 616/1440*x, 346/900*y, 851/1440*x, 445/900*y, tocolor(255, 255, 255, 255), 3.00, "default", "center", "center", false, false, false, false, false)
end
addEvent("showGUI", true)
addEventHandler("showGUI", getRootElement(), function()
guiSetVisible(button, true)
addEventHandler("onClientRender", getRootElement(), drawSyrena)
showCursor(true, false)
end)
addEvent("hideGUI", true)
addEventHandler("hideGUI", getRootElement(), function()
guiSetVisible(button, false)
removeEventHandler("onClientRender", getRootElement(), drawSyrena)
showCursor(false)
panel=false
end)
addEventHandler("onClientGUIClick", button, function()
triggerServerEven... |