Guest Posted June 30, 2008 Share Posted June 30, 2008 This GUI make me crazy function CreateGameModeMenu ( ) -- Crea il menu showCursor ( true ) GamemodeMenu = guiCreateWindow ( 0.30, 0.55, 0.4, 0.4, "Gamemode Panel Settings", true ) guiWindowSetMovable ( GamemodeMenu, false ) ButtonOK = guiCreateButton( 0.32, 0.9, 0.15, 0.2, "OK", true, GamemodeMenu ) ButtonExit = guiCreateButton( 0.52, 0.9, 0.17, 0.2, "Exit", true, GamemodeMenu ) ButtonStartClanwar = guiCreateButton( 0.65, 0.12, 0.3, 0.1, "Start Clanwar", true, GamemodeMenu ) addEventHandler ( "onClientGUIClick", ButtonOK, CloseOKguiAdminPanel) addEventHandler ( "onClientGUIClick", ButtonExit, CloseExitguiAdminPanel) addEventHandler ( "onClientGUIClick", ButtonStartClanwar, CloseStartClanwarguiAdminPanel) end When i click on button 'Start Clanwar' or 'Ok' or 'Exit' all work nicely But, when i click over these buttons (on blank space of GUI), the GUI execute all 'EventHandler' at same time... why? tnx in advance... sorry 4 my bad english Link to comment
50p Posted June 30, 2008 Share Posted June 30, 2008 Add false as the last argument in addEventHandler, like so: addEventHandler ( "onClientGUIClick", ButtonOK, CloseOKguiAdminPanel, false ) Link to comment
Guest Posted June 30, 2008 Share Posted June 30, 2008 OMG... Many tanks!!! You're the man 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