WolfPire Posted February 20, 2012 Share Posted February 20, 2012 So, hello, it's me again. I fixed my problem thanks to an user =) But another problem came in... Here's the problem... Whenever someone clicks in any part of the GUI (Which is not the buttons), the GUI gets duplicated. And i have found no ways yet to find a solution to this... sWidth,sHeight = guiGetScreenSize() function onJoin() showCursor(true) LoginW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Login",false) NameL = guiCreateLabel(28,139,35,15,"Name:",false,LoginW) guiSetFont(NameL,"default-bold-small") PassL = guiCreateLabel(18,180,56,15,"Password:",false,LoginW) guiSetFont(PassL,"default-bold-small") NameED = guiCreateEdit(78,132,233,31,"",false,LoginW) PassED = guiCreateEdit(80,174,233,31,"",false,LoginW) SepAD = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,LoginW) LoginB = guiCreateButton(23,244,120,32,"Login",false,LoginW) RegisterB = guiCreateButton(192,244,120,32,"Register",false,LoginW) AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,LoginW) Logo = guiCreateStaticImage(9,27,322,88,"images/Logo.jpg",false,LoginW) Name = guiGetText(NameED) Pass = guiGetText(PassED) addEventHandler("onClientGUIClick",RegisterB,RegisterC) addEventHandler("onClientGUIClick",LoginB,LoginE) end addEventHandler("onClientResourceStart",getRootElement(),onJoin) function RegisterC() destroyElement(LoginW) RegisterW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Register",false) NameLR = guiCreateLabel(28,77,35,15,"Name:",false,RegisterW) guiSetFont(NameLR,"default-bold-small") PassLR = guiCreateLabel(14,120,56,15,"Password:",false,RegisterW) guiSetFont(PassLR,"default-bold-small") NameEDR = guiCreateEdit(78,69,233,31,"",false,RegisterW) PassEDR = guiCreateEdit(80,111,233,31,"",false,RegisterW) SepADR = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,RegisterW) BackB = guiCreateButton(23,244,120,32,"Back",false,RegisterW) RegisterBR = guiCreateButton(192,244,120,32,"Register",false,RegisterW) ConfEDR = guiCreateEdit(80,154,233,31,"",false,RegisterW) ConfLR = guiCreateLabel(18,163,56,15,"Confirm:",false,RegisterW) guiSetFont(ConfLR,"default-bold-small") AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,RegisterW) NameR = guiGetText(NameEDR) PassR = guiGetText(PassEDR) addEventHandler("onClientGUIClick",BackB,LoginC) addEventHandler("onClientGUIClick",RegisterBR,RegisterE) end function LoginC() destroyElement(RegisterW) LoginW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Login",false) NameL = guiCreateLabel(28,139,35,15,"Name:",false,LoginW) guiSetFont(NameL,"default-bold-small") PassL = guiCreateLabel(18,180,56,15,"Password:",false,LoginW) guiSetFont(PassL,"default-bold-small") NameED = guiCreateEdit(78,132,233,31,"",false,LoginW) PassED = guiCreateEdit(80,174,233,31,"",false,LoginW) SepAD = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,LoginW) LoginB = guiCreateButton(23,244,120,32,"Login",false,LoginW) RegisterB = guiCreateButton(192,244,120,32,"Register",false,LoginW) AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,LoginW) Logo = guiCreateStaticImage(9,27,322,88,"images/Logo.jpg",false,LoginW) addEventHandler("onClientGUIClick",RegisterB,RegisterC) addEventHandler("onClientGUIClick",LoginB,LoginE) end function LoginE() local Name = guiGetText(NameED) local Pass = guiGetText(PassED) triggerServerEvent("login",localPlayer,localPlayer,Name,Pass) end function RegisterE() local NameR = guiGetText(NameEDR) local PassR = guiGetText(PassEDR) local Confirm = guiGetText(ConfEDR) triggerServerEvent("register",localPlayer,localPlayer,NameR,PassR,Confirm) end addEvent("agree",true) addEventHandler("agree",getRootElement(), function() destroyElement(LoginW) WelcomeW = guiCreateWindow(0.2188,0.1325,0.5445,0.7725,"Oriental Night Game - Agreement",true) guiWindowSetMovable(WelcomeW,false) guiWindowSetSizable(WelcomeW,false) EngL = guiCreateLabel(18,31,41,16,"English:",false,WelcomeW) MemoEng = guiCreateMemo(20,54,653,224,"Thank you for joining \"Oriental Night Gaming\"!\n\nThis is a server in development and it's just starting, so please be patient while we complete the development and add all the new functions and resources that will make this server a better one!\n\nFor now, please enjoy our Freeroam play, but follow these rules:\n\n1. Do not kill players while using a Jetpack\n2. You are not allowed to kill a player while you're in a vehicle and the player you want to kill is on foot (Get off the vehicle and kill it)\n3. Absolutely NO SPAWN KILLING, if they spawn, let them spawn normally, do not camp them or the present admin will ban you permanently.\n4. No HeliKill (Do not kill with the chopper razors) NOTE: The vehicle weapons have been disabled.\n5. Do not disrespect admins! (If the admin disrespects you, report it!)\n6. No admin impresionation! (Do not copy their names, if they are admins, they will do an admin function or appear in a team)\n7. No Ramming (Do not step on people with a car)\n_______________________________________________\n\nThis is the Member List so far:\n\n- WolfPire\n- Cross\n- MoonLight\n- Toxiccastle\n- Land\n\nDo not accept copy's!\n_______________________________________________\n\nThat's all! Accept if you agree and enjoy our server! =)",false,WelcomeW) guiMemoSetReadOnly(MemoEng,true) MemoEsp = guiCreateMemo(20,334,653,224,"Gracias por entrar a \"Oriental Night Gaming\"!\n\nEste servidor esta en desarrollo y solo esta empezando, asi que por favor se paciente mientras completamos el desarrollo y anadimos todas las nuevas funciones y recursos que haran de este server uno mejor!\n\nPor ahora, disfruta de nuestro juego Freeroam, pero sigue estas reglas:\n\n1. No mates a otros jugadores mientras usas un Jetpack\n2. No tienes permitido matar a otro jugador mientras estas en un auto y el otro jugador a pie (Salte del auto y matalo)\n3. Absolutamente NO MATAR GENTE DONDE APARECEN, si aparecen, dejalos aparecer normalmente, no los esperes o el admin presente te baneara permanentemente.\n4. No matar con el helicoptero (No los mates con las aspas de el helicoptero) NOTA: Las armas de los vehiculos estan desactivadas.\n5. No le faltes el respeto a los admins! (Si el admin te falta el respeto, reportalo!)\n6. No falsifiques a un admin! (No copies sus nombres, si ellos son admins, ellos haran alguna funcion admin o apareceran en algun equipo)\n7. No pises a los demas (No los pises con un auto)\n\n_______________________________________________\n\nEsta es la Lista de Miembros hasta ahora:\n\n- WolfPire\n- Cross\n- MoonLight\n- Toxiccastle\n- Land\n\nNo aceptes copias!\n_______________________________________________\n\nEso es todo! Acepta nuetras reglas si estas de acuerdo y disfruta nuestro server! =)",false,WelcomeW) guiMemoSetReadOnly(MemoEsp,true) Line = guiCreateLabel(21,278,654,20,"______________________________________________________________________________________________________________",false,WelcomeW) guiLabelSetColor(Line,0,255,0) EspL = guiCreateLabel(18,303,44,16,"Espanol:",false,WelcomeW) AcceptB = guiCreateButton(24,568,220,36,"Accept / Aceptar",false,WelcomeW) addEventHandler("onClientGUIClick",AcceptB,AcceptC) end ) function AcceptC() destroyElement(WelcomeW) showCursor(false) end That's the code, if you could please help me, i would me more than grateful =) Thanks for reading ^^ Link to comment
Kenix Posted February 20, 2012 Share Posted February 20, 2012 sWidth,sHeight = guiGetScreenSize() showCursor(true) LoginW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Login",false) NameL = guiCreateLabel(28,139,35,15,"Name:",false,LoginW) guiSetFont(NameL,"default-bold-small") PassL = guiCreateLabel(18,180,56,15,"Password:",false,LoginW) guiSetFont(PassL,"default-bold-small") NameED = guiCreateEdit(78,132,233,31,"",false,LoginW) PassED = guiCreateEdit(80,174,233,31,"",false,LoginW) SepAD = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,LoginW) LoginB = guiCreateButton(23,244,120,32,"Login",false,LoginW) RegisterB = guiCreateButton(192,244,120,32,"Register",false,LoginW) AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,LoginW) Logo = guiCreateStaticImage(9,27,322,88,"images/Logo.jpg",false,LoginW) Name = guiGetText(NameED) Pass = guiGetText(PassED) addEventHandler( "onClientGUIClick",RegisterB,RegisterC,false ) addEventHandler( "onClientGUIClick",LoginB,LoginE,false ) function RegisterC() destroyElement(LoginW) RegisterW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Register",false) NameLR = guiCreateLabel(28,77,35,15,"Name:",false,RegisterW) guiSetFont(NameLR,"default-bold-small") PassLR = guiCreateLabel(14,120,56,15,"Password:",false,RegisterW) guiSetFont(PassLR,"default-bold-small") NameEDR = guiCreateEdit(78,69,233,31,"",false,RegisterW) PassEDR = guiCreateEdit(80,111,233,31,"",false,RegisterW) SepADR = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,RegisterW) BackB = guiCreateButton(23,244,120,32,"Back",false,RegisterW) RegisterBR = guiCreateButton(192,244,120,32,"Register",false,RegisterW) ConfEDR = guiCreateEdit(80,154,233,31,"",false,RegisterW) ConfLR = guiCreateLabel(18,163,56,15,"Confirm:",false,RegisterW) guiSetFont(ConfLR,"default-bold-small") AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,RegisterW) NameR = guiGetText(NameEDR) PassR = guiGetText(PassEDR) addEventHandler( "onClientGUIClick",BackB,LoginC,false ) addEventHandler( "onClientGUIClick",RegisterBR,RegisterE,false ) end function LoginC() destroyElement(RegisterW) LoginW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Login",false) NameL = guiCreateLabel(28,139,35,15,"Name:",false,LoginW) guiSetFont(NameL,"default-bold-small") PassL = guiCreateLabel(18,180,56,15,"Password:",false,LoginW) guiSetFont(PassL,"default-bold-small") NameED = guiCreateEdit(78,132,233,31,"",false,LoginW) PassED = guiCreateEdit(80,174,233,31,"",false,LoginW) SepAD = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,LoginW) LoginB = guiCreateButton(23,244,120,32,"Login",false,LoginW) RegisterB = guiCreateButton(192,244,120,32,"Register",false,LoginW) AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,LoginW) Logo = guiCreateStaticImage(9,27,322,88,"images/Logo.jpg",false,LoginW) addEventHandler( "onClientGUIClick",RegisterB,RegisterC,false ) addEventHandler( "onClientGUIClick",LoginB,LoginE,false ) end function LoginE() local Name = guiGetText(NameED) local Pass = guiGetText(PassED) triggerServerEvent("login",localPlayer,localPlayer,Name,Pass) end function RegisterE() local NameR = guiGetText(NameEDR) local PassR = guiGetText(PassEDR) local Confirm = guiGetText(ConfEDR) triggerServerEvent("register",localPlayer,localPlayer,NameR,PassR,Confirm) end addEvent("agree",true) addEventHandler("agree",getRootElement(), function() destroyElement(LoginW) WelcomeW = guiCreateWindow(0.2188,0.1325,0.5445,0.7725,"Oriental Night Game - Agreement",true) guiWindowSetMovable(WelcomeW,false) guiWindowSetSizable(WelcomeW,false) EngL = guiCreateLabel(18,31,41,16,"English:",false,WelcomeW) MemoEng = guiCreateMemo(20,54,653,224,"Thank you for joining \"Oriental Night Gaming\"!\n\nThis is a server in development and it's just starting, so please be patient while we complete the development and add all the new functions and resources that will make this server a better one!\n\nFor now, please enjoy our Freeroam play, but follow these rules:\n\n1. Do not kill players while using a Jetpack\n2. You are not allowed to kill a player while you're in a vehicle and the player you want to kill is on foot (Get off the vehicle and kill it)\n3. Absolutely NO SPAWN KILLING, if they spawn, let them spawn normally, do not camp them or the present admin will ban you permanently.\n4. No HeliKill (Do not kill with the chopper razors) NOTE: The vehicle weapons have been disabled.\n5. Do not disrespect admins! (If the admin disrespects you, report it!)\n6. No admin impresionation! (Do not copy their names, if they are admins, they will do an admin function or appear in a team)\n7. No Ramming (Do not step on people with a car)\n_______________________________________________\n\nThis is the Member List so far:\n\n- WolfPire\n- Cross\n- MoonLight\n- Toxiccastle\n- Land\n\nDo not accept copy's!\n_______________________________________________\n\nThat's all! Accept if you agree and enjoy our server! =)",false,WelcomeW) guiMemoSetReadOnly(MemoEng,true) MemoEsp = guiCreateMemo(20,334,653,224,"Gracias por entrar a \"Oriental Night Gaming\"!\n\nEste servidor esta en desarrollo y solo esta empezando, asi que por favor se paciente mientras completamos el desarrollo y anadimos todas las nuevas funciones y recursos que haran de este server uno mejor!\n\nPor ahora, disfruta de nuestro juego Freeroam, pero sigue estas reglas:\n\n1. No mates a otros jugadores mientras usas un Jetpack\n2. No tienes permitido matar a otro jugador mientras estas en un auto y el otro jugador a pie (Salte del auto y matalo)\n3. Absolutamente NO MATAR GENTE DONDE APARECEN, si aparecen, dejalos aparecer normalmente, no los esperes o el admin presente te baneara permanentemente.\n4. No matar con el helicoptero (No los mates con las aspas de el helicoptero) NOTA: Las armas de los vehiculos estan desactivadas.\n5. No le faltes el respeto a los admins! (Si el admin te falta el respeto, reportalo!)\n6. No falsifiques a un admin! (No copies sus nombres, si ellos son admins, ellos haran alguna funcion admin o apareceran en algun equipo)\n7. No pises a los demas (No los pises con un auto)\n\n_______________________________________________\n\nEsta es la Lista de Miembros hasta ahora:\n\n- WolfPire\n- Cross\n- MoonLight\n- Toxiccastle\n- Land\n\nNo aceptes copias!\n_______________________________________________\n\nEso es todo! Acepta nuetras reglas si estas de acuerdo y disfruta nuestro server! =)",false,WelcomeW) guiMemoSetReadOnly(MemoEsp,true) Line = guiCreateLabel(21,278,654,20,"______________________________________________________________________________________________________________",false,WelcomeW) guiLabelSetColor(Line,0,255,0) EspL = guiCreateLabel(18,303,44,16,"Espanol:",false,WelcomeW) AcceptB = guiCreateButton(24,568,220,36,"Accept / Aceptar",false,WelcomeW) addEventHandler( "onClientGUIClick",AcceptB,AcceptC,false ) end ) function AcceptC( ) destroyElement(WelcomeW) showCursor(false) end Link to comment
WolfPire Posted February 20, 2012 Author Share Posted February 20, 2012 sWidth,sHeight = guiGetScreenSize() showCursor(true) LoginW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Login",false) NameL = guiCreateLabel(28,139,35,15,"Name:",false,LoginW) guiSetFont(NameL,"default-bold-small") PassL = guiCreateLabel(18,180,56,15,"Password:",false,LoginW) guiSetFont(PassL,"default-bold-small") NameED = guiCreateEdit(78,132,233,31,"",false,LoginW) PassED = guiCreateEdit(80,174,233,31,"",false,LoginW) SepAD = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,LoginW) LoginB = guiCreateButton(23,244,120,32,"Login",false,LoginW) RegisterB = guiCreateButton(192,244,120,32,"Register",false,LoginW) AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,LoginW) Logo = guiCreateStaticImage(9,27,322,88,"images/Logo.jpg",false,LoginW) Name = guiGetText(NameED) Pass = guiGetText(PassED) addEventHandler( "onClientGUIClick",RegisterB,RegisterC,false ) addEventHandler( "onClientGUIClick",LoginB,LoginE,false ) function RegisterC() destroyElement(LoginW) RegisterW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Register",false) NameLR = guiCreateLabel(28,77,35,15,"Name:",false,RegisterW) guiSetFont(NameLR,"default-bold-small") PassLR = guiCreateLabel(14,120,56,15,"Password:",false,RegisterW) guiSetFont(PassLR,"default-bold-small") NameEDR = guiCreateEdit(78,69,233,31,"",false,RegisterW) PassEDR = guiCreateEdit(80,111,233,31,"",false,RegisterW) SepADR = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,RegisterW) BackB = guiCreateButton(23,244,120,32,"Back",false,RegisterW) RegisterBR = guiCreateButton(192,244,120,32,"Register",false,RegisterW) ConfEDR = guiCreateEdit(80,154,233,31,"",false,RegisterW) ConfLR = guiCreateLabel(18,163,56,15,"Confirm:",false,RegisterW) guiSetFont(ConfLR,"default-bold-small") AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,RegisterW) NameR = guiGetText(NameEDR) PassR = guiGetText(PassEDR) addEventHandler( "onClientGUIClick",BackB,LoginC,false ) addEventHandler( "onClientGUIClick",RegisterBR,RegisterE,false ) end function LoginC() destroyElement(RegisterW) LoginW = guiCreateWindow(sWidth/3.3,sHeight/3.3,500,300,"Oriental Night Gaming - Login",false) NameL = guiCreateLabel(28,139,35,15,"Name:",false,LoginW) guiSetFont(NameL,"default-bold-small") PassL = guiCreateLabel(18,180,56,15,"Password:",false,LoginW) guiSetFont(PassL,"default-bold-small") NameED = guiCreateEdit(78,132,233,31,"",false,LoginW) PassED = guiCreateEdit(80,174,233,31,"",false,LoginW) SepAD = guiCreateLabel(335,24,5,276,"|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n",false,LoginW) LoginB = guiCreateButton(23,244,120,32,"Login",false,LoginW) RegisterB = guiCreateButton(192,244,120,32,"Register",false,LoginW) AD = guiCreateStaticImage(339,23,168,278,"images/AD.jpg",false,LoginW) Logo = guiCreateStaticImage(9,27,322,88,"images/Logo.jpg",false,LoginW) addEventHandler( "onClientGUIClick",RegisterB,RegisterC,false ) addEventHandler( "onClientGUIClick",LoginB,LoginE,false ) end function LoginE() local Name = guiGetText(NameED) local Pass = guiGetText(PassED) triggerServerEvent("login",localPlayer,localPlayer,Name,Pass) end function RegisterE() local NameR = guiGetText(NameEDR) local PassR = guiGetText(PassEDR) local Confirm = guiGetText(ConfEDR) triggerServerEvent("register",localPlayer,localPlayer,NameR,PassR,Confirm) end addEvent("agree",true) addEventHandler("agree",getRootElement(), function() destroyElement(LoginW) WelcomeW = guiCreateWindow(0.2188,0.1325,0.5445,0.7725,"Oriental Night Game - Agreement",true) guiWindowSetMovable(WelcomeW,false) guiWindowSetSizable(WelcomeW,false) EngL = guiCreateLabel(18,31,41,16,"English:",false,WelcomeW) MemoEng = guiCreateMemo(20,54,653,224,"Thank you for joining \"Oriental Night Gaming\"!\n\nThis is a server in development and it's just starting, so please be patient while we complete the development and add all the new functions and resources that will make this server a better one!\n\nFor now, please enjoy our Freeroam play, but follow these rules:\n\n1. Do not kill players while using a Jetpack\n2. You are not allowed to kill a player while you're in a vehicle and the player you want to kill is on foot (Get off the vehicle and kill it)\n3. Absolutely NO SPAWN KILLING, if they spawn, let them spawn normally, do not camp them or the present admin will ban you permanently.\n4. No HeliKill (Do not kill with the chopper razors) NOTE: The vehicle weapons have been disabled.\n5. Do not disrespect admins! (If the admin disrespects you, report it!)\n6. No admin impresionation! (Do not copy their names, if they are admins, they will do an admin function or appear in a team)\n7. No Ramming (Do not step on people with a car)\n_______________________________________________\n\nThis is the Member List so far:\n\n- WolfPire\n- Cross\n- MoonLight\n- Toxiccastle\n- Land\n\nDo not accept copy's!\n_______________________________________________\n\nThat's all! Accept if you agree and enjoy our server! =)",false,WelcomeW) guiMemoSetReadOnly(MemoEng,true) MemoEsp = guiCreateMemo(20,334,653,224,"Gracias por entrar a \"Oriental Night Gaming\"!\n\nEste servidor esta en desarrollo y solo esta empezando, asi que por favor se paciente mientras completamos el desarrollo y anadimos todas las nuevas funciones y recursos que haran de este server uno mejor!\n\nPor ahora, disfruta de nuestro juego Freeroam, pero sigue estas reglas:\n\n1. No mates a otros jugadores mientras usas un Jetpack\n2. No tienes permitido matar a otro jugador mientras estas en un auto y el otro jugador a pie (Salte del auto y matalo)\n3. Absolutamente NO MATAR GENTE DONDE APARECEN, si aparecen, dejalos aparecer normalmente, no los esperes o el admin presente te baneara permanentemente.\n4. No matar con el helicoptero (No los mates con las aspas de el helicoptero) NOTA: Las armas de los vehiculos estan desactivadas.\n5. No le faltes el respeto a los admins! (Si el admin te falta el respeto, reportalo!)\n6. No falsifiques a un admin! (No copies sus nombres, si ellos son admins, ellos haran alguna funcion admin o apareceran en algun equipo)\n7. No pises a los demas (No los pises con un auto)\n\n_______________________________________________\n\nEsta es la Lista de Miembros hasta ahora:\n\n- WolfPire\n- Cross\n- MoonLight\n- Toxiccastle\n- Land\n\nNo aceptes copias!\n_______________________________________________\n\nEso es todo! Acepta nuetras reglas si estas de acuerdo y disfruta nuestro server! =)",false,WelcomeW) guiMemoSetReadOnly(MemoEsp,true) Line = guiCreateLabel(21,278,654,20,"______________________________________________________________________________________________________________",false,WelcomeW) guiLabelSetColor(Line,0,255,0) EspL = guiCreateLabel(18,303,44,16,"Espanol:",false,WelcomeW) AcceptB = guiCreateButton(24,568,220,36,"Accept / Aceptar",false,WelcomeW) addEventHandler( "onClientGUIClick",AcceptB,AcceptC,false ) end ) function AcceptC( ) destroyElement(WelcomeW) showCursor(false) end Thank you =) Quite a newbish mistake from my part! Edit: My bad buddy... But can you give me one last hand? I'm getting an error from the 2 event handlers. "WARNING: en2/en_c.lua:18: Bad argument @ 'addEventHandler' [Expected function at argument 3, got nil]" "WARNING: en2/en_c.lua:19: Bad argument @ 'addEventHandler' [Expected function at argument 3, got nil]" Edit 2: Fixed, just had to move those event handlers to the final of the script (After the functions) Link to comment
Kenix Posted February 21, 2012 Share Posted February 21, 2012 Ah in first time i not see where your function ( you attach function to event handler ) No problem. So structure: addEvent( 'onSomeEvent',true ) local t = { 'some_value' } function some( ) return 'some' end function onSomeEvent( ) outputChatBox '--> onSomeEvent' end addEventHandler( 'onSomeEvent',root,onSomeEvent ) 1.add event 2.variables/tables 3.functions. 4.event handler. 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