DJsidjiqwdq Posted January 26, 2018 Share Posted January 26, 2018 hi i 've created my first menu with Guieditor and i've scripted it but after i want to test it it didn't work and i found this Error: as you can see it on the image and this is the script GUIEditor = { button = {}, window = {}, edit = {} } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(519, 260, 344, 304, "", false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.edit[1] = guiCreateEdit((344 - 199) / 2, (304 - 20) / 2, 199, 20, "", false, GUIEditor.window[1]) GUIEditor.button[1] = guiCreateButton(280, 256, 55, 26, "‗הב", false, GUIEditor.window[1]) GUIEditor.edit[2] = guiCreateEdit(507, 146, 0, 110, "", false, GUIEditor.window[1]) GUIEditor.edit[3] = guiCreateEdit(17, 196, 245, 86, "", false, GUIEditor.window[1]) end ) local key = "F3" bindkey(key, "down", function() guiSetVisible(GUIEditor.window[1])) showCursor(guiGetVisible(GUIEditor.window[1])) end ) addEventHandler("onClienGUIClick",root, if (source == GUIEditor.button[1]) guiSetVisible(GUIEditor.window[1],false) showCursor(false) end end what do i do to fix this?? Link to comment
Scripting Moderators thisdp Posted January 26, 2018 Scripting Moderators Share Posted January 26, 2018 addEventHandler("onClienGUIClick",root, if (source == GUIEditor.button[1]) guiSetVisible(GUIEditor.window[1],false) showCursor(false) end end) Link to comment
DJsidjiqwdq Posted January 26, 2018 Author Share Posted January 26, 2018 5 minutes ago, thisdp said: addEventHandler("onClienGUIClick",root, if (source == GUIEditor.button[1]) guiSetVisible(GUIEditor.window[1],false) showCursor(false) end end) didn't work the error says line 24 Link to comment
Scripting Moderators thisdp Posted January 26, 2018 Scripting Moderators Share Posted January 26, 2018 5 hours ago, MANSOR12312 said: didn't work the error says line 24 guiSetVisible(GUIEditor.window[1])0) guiSetVisible(GUIEditor.window[1]) Link to comment
DRW Posted January 26, 2018 Share Posted January 26, 2018 (edited) GUIEditor = { button = {}, window = {}, edit = {} } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(519, 260, 344, 304, "", false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.edit[1] = guiCreateEdit((344 - 199) / 2, (304 - 20) / 2, 199, 20, "", false, GUIEditor.window[1]) GUIEditor.button[1] = guiCreateButton(280, 256, 55, 26, "‗הב", false, GUIEditor.window[1]) GUIEditor.edit[2] = guiCreateEdit(507, 146, 0, 110, "", false, GUIEditor.window[1]) GUIEditor.edit[3] = guiCreateEdit(17, 196, 245, 86, "", false, GUIEditor.window[1]) end ) local key = "F3" bindkey(key, "down", function() guiSetVisible(GUIEditor.window[1],true) showCursor(guiGetVisible(GUIEditor.window[1])) end ) addEventHandler("onClientGUIClick",root, if (source == GUIEditor.button[1]) guiSetVisible(GUIEditor.window[1],false) showCursor(false) end end By the way, this should go to the "scripting" section, not here. Edited January 26, 2018 by MadnessReloaded Link to comment
DJsidjiqwdq Posted January 26, 2018 Author Share Posted January 26, 2018 2 hours ago, MadnessReloaded said: GUIEditor = { button = {}, window = {}, edit = {} } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(519, 260, 344, 304, "", false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.edit[1] = guiCreateEdit((344 - 199) / 2, (304 - 20) / 2, 199, 20, "", false, GUIEditor.window[1]) GUIEditor.button[1] = guiCreateButton(280, 256, 55, 26, "‗הב", false, GUIEditor.window[1]) GUIEditor.edit[2] = guiCreateEdit(507, 146, 0, 110, "", false, GUIEditor.window[1]) GUIEditor.edit[3] = guiCreateEdit(17, 196, 245, 86, "", false, GUIEditor.window[1]) end ) local key = "F3" bindkey(key, "down", function() guiSetVisible(GUIEditor.window[1],true) showCursor(guiGetVisible(GUIEditor.window[1])) end ) addEventHandler("onClientGUIClick",root, if (source == GUIEditor.button[1]) guiSetVisible(GUIEditor.window[1],false) showCursor(false) end end By the way, this should go to the "scripting" section, not here. did you fix this script? if yes ty i'll test it Link to comment
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