iFoReX Posted August 15, 2012 Share Posted August 15, 2012 El texto no cambia en el edit he intentado todo, y no hay problemas en el debug cl-side GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Label = {} GUIEditor_Edit = {} GUIEditor_Grid = {} GUIEditor_Window[1] = guiCreateWindow(0.415,0.2333,0.2212,0.3967,"Bienvenido a MultiGames",true) GUIEditor_Label[1] = guiCreateLabel(43,37,91,26,"Elija un spawn...",false,GUIEditor_Window[1]) GUIEditor_Button[1] = guiCreateButton(9,74,156,45,"Zombies",false,GUIEditor_Window[1]) GUIEditor_Button[2] = guiCreateButton(9,126,156,45,"Carreras callejeras",false,GUIEditor_Window[1]) GUIEditor_Button[3] = guiCreateButton(9,178,156,45,"Clan Wars",false,GUIEditor_Window[1]) GUIEditor_Window[2] = guiCreateWindow(0.2738,0.3967,0.54,0.2533,"Zombies Gamemode",true) guiWindowSetSizable(GUIEditor_Window[2],false) GUIEditor_Label[2] = guiCreateLabel(178,36,72,17,"Elije un Skin",false,GUIEditor_Window[2]) GUIEditor_Edit[1] = guiCreateEdit(171,61,79,23,"",false,GUIEditor_Window[2]) guiEditSetReadOnly(GUIEditor_Edit[1],true) GUIEditor_Button[4] = guiCreateButton(145,59,22,29,"<",false,GUIEditor_Window[2]) GUIEditor_Button[5] = guiCreateButton(254,59,22,29,">",false,GUIEditor_Window[2]) GUIEditor_Button[6] = guiCreateButton(11,99,144,44,"Jugar !",false,GUIEditor_Window[2]) GUIEditor_Button[7] = guiCreateButton(280,99,143,44,"Volver",false,GUIEditor_Window[2]) GUIEditor_Window[3] = guiCreateWindow(0.2138,0.0917,0.6875,0.75,"Carreras Callejeras GameMode",true) GUIEditor_Label[3] = guiCreateLabel(62,35,80,23,"Elije tu coche",false,GUIEditor_Window[3]) GUIEditor_Grid[1] = guiCreateGridList(15,71,192,370,false,GUIEditor_Window[3]) guiGridListSetSelectionMode(GUIEditor_Grid[1],2) guiGridListAddColumn(GUIEditor_Grid[1],"Autos",0.2) GUIEditor_Label[4] = guiCreateLabel(403,35,80,23,"Elije Una pista",false,GUIEditor_Window[3]) GUIEditor_Grid[2] = guiCreateGridList(344,71,192,370,false,GUIEditor_Window[3]) guiGridListSetSelectionMode(GUIEditor_Grid[2],2) guiGridListAddColumn(GUIEditor_Grid[2],"Pistas",0.2) GUIEditor_Button[8] = guiCreateButton(209,182,132,51,"Jugar !",false,GUIEditor_Window[3]) GUIEditor_Button[9] = guiCreateButton(209,240,132,51,"Volver",false,GUIEditor_Window[3]) GUIEditor_Window[4] = guiCreateWindow(0.1838,0.0767,0.7312,0.765,"Clan Wars GameMode",true) GUIEditor_Label[5] = guiCreateLabel(263,60,64,21,"Elije 1 clan",false,GUIEditor_Window[4]) GUIEditor_Grid[3] = guiCreateGridList(224,86,139,127,false,GUIEditor_Window[4]) guiGridListSetSelectionMode(GUIEditor_Grid[3],2) guiGridListAddColumn(GUIEditor_Grid[3],"Clanes",0.2) GUIEditor_Label[6] = guiCreateLabel(56,43,154,25,"Elije las Armas",false,GUIEditor_Window[4]) GUIEditor_Grid[4] = guiCreateGridList(29,68,171,148,false,GUIEditor_Window[4]) guiGridListSetSelectionMode(GUIEditor_Grid[4],2) guiGridListAddColumn(GUIEditor_Grid[4],"Arma Primaria",0.2) GUIEditor_Grid[5] = guiCreateGridList(29,229,171,148,false,GUIEditor_Window[4]) guiGridListSetSelectionMode(GUIEditor_Grid[5],2) guiGridListAddColumn(GUIEditor_Grid[5],"Arma Secundaria",0.2) GUIEditor_Label[7] = guiCreateLabel(412,43,154,25,"Elije las Armas",false,GUIEditor_Window[4]) GUIEditor_Grid[6] = guiCreateGridList(385,68,171,148,false,GUIEditor_Window[4]) guiGridListSetSelectionMode(GUIEditor_Grid[6],2) guiGridListAddColumn(GUIEditor_Grid[6],"Arma Terciaria",0.2) GUIEditor_Button[10] = guiCreateButton(225,225,137,48,"Jugar",false,GUIEditor_Window[4]) GUIEditor_Button[11] = guiCreateButton(225,283,137,48,"Volver",false,GUIEditor_Window[4]) guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],false) guiSetVisible(GUIEditor_Window[3],false) guiSetVisible(GUIEditor_Window[4],false) addEvent("openMGMGUI",true) addEventHandler("openMGMGUI",root,function() guiSetVisible(GUIEditor_Window[1],true) showCursor(true) end ) addEventHandler("onClientGUIClick",root,function() if source == GUIEditor_Button[1] then guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) local elTexto = guiGetText(GUIEditor_Edit[1]) local skins = 'Chris Redfield' guiSetText(GUIEditor_Edit[1],skins) if source == GUIEditor_Button[4] then if elTexto == 'Chris Redfield' then guiSetText(GUIEditor_Edit[1],'Sheva') elseif elTexto == 'Sheva' then guiSetText(GUIEditor_Edit[1],skins) end elseif source == GUIEditor_Button[5] then if elTexto == 'Sheva' then guiSetText(GUIEditor_Edit[1],skins) elseif elTexto == 'Chris Redfield' then guiSetText(GUIEditor_Edit[1],'Sheva') end end elseif source == GUIEditor_Button[2] then guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[3],true) elseif source == GUIEditor_Button[3] then guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[4],true) elseif source == GUIEditor_Button[7] then guiSetVisible(GUIEditor_Window[4],false) end end ) sv-side addEventHandler("onPlayerLogin",root,function() triggerClientEvent(source,"openMGMGUI",source) end) Link to comment
Araa Posted August 15, 2012 Share Posted August 15, 2012 No estoy segura pero creo que es porque usas ' ' en lugar de " " para las cadenas de caracteres. Link to comment
Alexs Posted August 15, 2012 Share Posted August 15, 2012 No estoy segura pero creo que es porque usas ' ' en lugar de " " para las cadenas de caracteres. Ambos son strings, estoy buscando el error pero no los veo a simple vista, dejenme que me tome algo para despertarme (me han estado pasando cosas "raras" y no pude dormir) y les ayudo bien. Link to comment
Castillo Posted August 16, 2012 Share Posted August 16, 2012 No estoy segura pero creo que es porque usas ' ' en lugar de " " para las cadenas de caracteres. ' ' y " " es lo mismo . @ElMota: Solo definiste: "elTexto" una sola vez, no lo definiste dentro de cada 'if'. Link to comment
Recommended Posts