Sziasztok!
Nemrég kezdtem a LUA-t. Guieditor-ral GUI felületet akarok készíteni. Ha megvan a GUI, akkor innentől hogyan tovább? Mármint a label-ekre hogyan tudok tenni valamit, mint pl. outputChatBox-ot?
addEventHandler(\"onClientResourceStart\", resourceRoot,
function teszt()
gomb1 = guiCreateLabel(586, 229, 239, 33, \"AK-47\", false)
guiSetFont(GUIEditor.label[9], \"default-bold-small\")
guiLabelSetColor(GUIEditor.label[9], 0, 0, 0)
guiLabelSetHorizontalAlign(GUIEditor.label[9], \"center\", false)
guiLabelSetVerticalAlign(GUIEditor.label[9], \"center\")
gomb2 = guiCreateLabel(586, 271, 239, 33, \"AK-47\", false)
guiSetFont(GUIEditor.label[10], \"default-bold-small\")
guiLabelSetColor(GUIEditor.label[10], 0, 0, 0)
guiLabelSetHorizontalAlign(GUIEditor.label[10], \"center\", false)
guiLabelSetVerticalAlign(GUIEditor.label[10], \"center\")
gomb3 = guiCreateLabel(587, 313, 239, 33, \"AK-47\", false)
guiSetFont(GUIEditor.label[11], \"default-bold-small\")
guiLabelSetColor(GUIEditor.label[11], 0, 0, 0)
guiLabelSetHorizontalAlign(GUIEditor.label[11], \"center\", false)
guiLabelSetVerticalAlign(GUIEditor.label[11], \"center\")
gomb4 = guiCreateLabel(587, 355, 239, 33, \"AK-47\", false)
guiSetFont(GUIEditor.label[12], \"default-bold-small\")
guiLabelSetColor(GUIEditor.label[12], 0, 0, 0)
guiLabelSetHorizontalAlign(GUIEditor.label[12], \"center\", false)
guiLabelSetVerticalAlign(GUIEditor.label[12], \"center\")
gomb5 = guiCreateLabel(586, 397, 239, 33, \"AK-47\", false)
guiSetFont(GUIEditor.label[13], \"default-bold-small\")
guiLabelSetColor(GUIEditor.label[13], 0, 0, 0)
guiLabelSetHorizontalAlign(GUIEditor.label[13], \"center\", false)
guiLabelSetVerticalAlign(GUIEditor.label[13], \"center\")
gomb6 = guiCreateLabel(586, 439, 239, 33, \"AK-47\", false)
guiSetFont(GUIEditor.label[14], \"default-bold-small\")
guiLabelSetColor(GUIEditor.label[14], 0, 0, 0)
guiLabelSetHorizontalAlign(GUIEditor.label[14], \"center\", false)
guiLabelSetVerticalAlign(GUIEditor.label[14], \"center\")
gomb7 = guiCreateLabel(586, 481, 239, 33, \"AK-47\", false)
guiSetFont(GUIEditor.label[15], \"default-bold-small\")
guiLabelSetColor(GUIEditor.label[15], 0, 0, 0)
guiLabelSetHorizontalAlign(GUIEditor.label[15], \"center\", false)
guiLabelSetVerticalAlign(GUIEditor.label[15], \"center\")
end
)
addEventHandler(\"onClientRender\", root,
function teszt1()
dxDrawLine(577 - 1, 220 - 1, 577 - 1, 551, tocolor(255, 255, 255, 254), 1, false)
dxDrawLine(835, 220 - 1, 577 - 1, 220 - 1, tocolor(255, 255, 255, 254), 1, false)
dxDrawLine(577 - 1, 551, 835, 551, tocolor(255, 255, 255, 254), 1, false)
dxDrawLine(835, 551, 835, 220 - 1, tocolor(255, 255, 255, 254), 1, false)
dxDrawRectangle(577, 220, 258, 331, tocolor(0, 0, 0, 148), false)
dxDrawRectangle(587, 230, 238, 32, tocolor(255, 255, 255, 255), false)
dxDrawRectangle(587, 272, 238, 32, tocolor(255, 255, 255, 255), false)
dxDrawRectangle(587, 314, 238, 32, tocolor(255, 255, 255, 255), false)
dxDrawRectangle(587, 356, 238, 32, tocolor(255, 255, 255, 255), false)
dxDrawRectangle(587, 398, 238, 32, tocolor(255, 255, 255, 255), false)
dxDrawRectangle(587, 440, 238, 32, tocolor(255, 255, 255, 255), false)
dxDrawRectangle(587, 482, 238, 32, tocolor(255, 255, 255, 255), false)
end
)