Hey, ich habe gerade ein Gui für einen Fahrradverleih gebastelt.
Nur wenn ich jetzt durch das Pickup gehe, funktioniert nur "showCursor"
Weiß jemand woran es liegen kann ?
function fensterAuf ()
guiSetVisible ( fahrradverleihGui, true )
showCursor ( true )
end
addEventHandler ("onClientPickupHit", noobspawnPickup, fensterAuf)
addEventHandler ("onClientPickupHit", bhfPickup, fensterAuf)
Und das GUI:
local sx, sy = guiGetScreenSize()
local mx, my = 1280, 1024
local x,y = (sx/mx), (sy/my)
addEventHandler("onClientResourceStart", resourceRoot,
function()
fahrradverleihGui = guiCreateWindow(538*x, 407*y, 203*x, 241*y, "Fahrradverleih", true)
guiWindowSetMovable(fahrradverleihGui, false)
guiWindowSetSizable(fahrradverleihGui, false)
closeButton = guiCreateButton(46*x, 208*y, 110*x, 23*y, "Fenster Schließen", true, fahrradverleihGui)
guiSetFont(closeButton, "default-bold-small")
guiSetProperty(closeButton, "NormalTextColour", "FFFF0000")
ausleihButton = guiCreateButton(14*x, 175*y, 179*x, 23*y, "Fahrrad ausleihen", true, fahrradverleihGui)
guiSetFont(ausleihButton, "default-bold-small")
guiSetProperty(ausleihButton, "NormalTextColour", "FF0CFF00")
label1 = guiCreateLabel(11*x, 25*y, 182*x, 15*y, "Willkommen beim", true, fahrradverleihGui)
guiSetFont(label1, "default-bold-small")
label2 = guiCreateLabel(11*x, 40*y, 182*x, 15*y, "Fahrradverleih!", true, fahrradverleihGui)
guiSetFont(label2, "default-bold-small")
label3 = guiCreateLabel(11*x, 81*y, 182*x, 15*y, "Hier kannst du dir alle 10 Min.", true, fahrradverleihGui)
guiSetFont(label3, "default-bold-small")
label4 = guiCreateLabel(11*x, 96*y, 182*x, 15*y, "Ein Fahrrad ausleihen!", true, fahrradverleihGui)
guiSetFont(label4, "default-bold-small")
label5 = guiCreateLabel(11*x, 111*y, 182*x, 15*y, "Dieses Fahrrad wird dann nach", true, fahrradverleihGui)
guiSetFont(label5, "default-bold-small")
label6 = guiCreateLabel(11*x, 126*y, 182*x, 15*y, "10 Min. auch wieder gelöscht.", true, fahrradverleihGui)
guiSetFont(label6, "default-bold-small")
end
)
PS: Ja, ich würde gerne den LUA Code benutzen, nur verschiebt es sich mal wieder alles in eine Zeile...