FSXTim Posted May 27, 2012 Posted May 27, 2012 (edited) Hello, when I click on the image 'ImageSchwarz1', all the other images are set to the front, but not the labels, they are still in the background, please have a look: ... Greets Edited May 27, 2012 by Guest
Jaysds1 Posted May 27, 2012 Posted May 27, 2012 try this: iphone_Window = guiCreateWindow(0.0401,0.2232,0.1255,0.3046,"",true) main = guiCreateStaticImage(0.3942,0.8146,0.2033,0.1307,"images/iphonebutton.png",true,iphone_Window) GUIEditor_Label1 = guiCreateLabel(0.0456,0.7568,0.9087,0.0547,"_______________________________",true,iphone_Window) guiLabelSetColor(GUIEditor_Label1,0,0,0) guiSetFont(GUIEditor_Label1,"default-bold-small") GUIEditor_Label2 = guiCreateLabel(0.0432,0.076,0.029,0.7204,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",true,iphone_Window) guiLabelSetColor(GUIEditor_Label2,0,0,0) guiSetFont(GUIEditor_Label2,"default-bold-small") GUIEditor_Label3 = guiCreateLabel(0.9295,0.076,0.029,0.7204,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",true,iphone_Window) guiLabelSetColor(GUIEditor_Label3,0,0,0) guiSetFont(GUIEditor_Label3,"default-bold-small") GUIEditor_Label4 = guiCreateLabel(0.0456,0.0486,0.9087,0.0547,"_______________________________",true,iphone_Window) guiLabelSetColor(GUIEditor_Label4,0,0,0) guiSetFont(GUIEditor_Label4,"default-bold-small") GUIEditor_Image2 = guiCreateStaticImage(0.1867,0.155,0.2241,0.1307,"images/mp3.png",true,iphone_Window) GUIEditor_Image3 = guiCreateStaticImage(0.5851,0.155,0.2199,0.1307,"images/notizen.png",true,iphone_Window) GUIEditor_Image4 = guiCreateStaticImage(0.5768,0.5775,0.2241,0.1459,"images/zeit.png",true,iphone_Window) GUIEditor_Image5 = guiCreateStaticImage(0.5809,0.3647,0.2158,0.1398,"images/sms.png",true,iphone_Window) GUIEditor_Image6 = guiCreateStaticImage(0.195,0.3678,0.1992,0.1277,"images/finfo.png",true,iphone_Window) GUIEditor_Image7 = guiCreateStaticImage(0.1909,0.5745,0.2033,0.1368,"images/hilfe.png",true,iphone_Window) GUIEditor_ImageSchwarz1 = guiCreateStaticImage(0.0372,0.0638,0.9256,0.9088,"images/schwarz.png",true,iphone_Window) function schwarz1(state) if state == "left" then if source == GUIEditor_ImageSchwarz1 then guiBringToFront(main) guiBringToFront(GUIEditor_Image2) guiBringToFront(GUIEditor_Image3) guiBringToFront(GUIEditor_Image4) guiBringToFront(GUIEditor_Image5) guiBringToFront(GUIEditor_Image6) guiBringToFront(GUIEditor_Image7) guiBringToFront(GUIEditor_Label1) guiBringToFront(GUIEditor_Label2) guiBringToFront(GUIEditor_Label3) guiBringToFront(GUIEditor_Label4) -- bring the labels up after the images are brought to the front end end end addEventHandler("onClientGUIClick",guiRoot, schwarz1,true) --don't forget the boolean at the end. (true for source's and false for individual buttons) My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
FSXTim Posted May 27, 2012 Author Posted May 27, 2012 (edited) Sorry, but it also doesn't work. Here another example, this works perfectly, the images and the labels are at the front, when I click on the image 'GUIEditor_ImageSchwarz3'. ... Edited May 27, 2012 by Guest
Jaysds1 Posted May 27, 2012 Posted May 27, 2012 try sending the image to the back My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
FSXTim Posted May 27, 2012 Author Posted May 27, 2012 Thanks, sir! That' working: guiMoveToBack(GUIEditor_ImageSchwarz1) function schwarz1 (state) if state == "left" then if source == GUIEditor_ImageSchwarz1 then guiMoveToBack(GUIEditor_ImageSchwarz1) end end end addEventHandler("onClientGUIClick", getRootElement(), schwarz1) Greets
Jaysds1 Posted May 27, 2012 Posted May 27, 2012 np My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now