TheSanto Posted May 5, 2013 Report Share Posted May 5, 2013 quest gm_list begin state start begin when login begin local gms = { {"[ADM]Dios"}, {"[GM]ToNy"}, {"[GM]Dynato"} {"[GM]TheKill"}, {"[GM]Sternico"}, {"[GM]Darkes"}--On the last not need ',' } for i=1, table.getn(gms), 1 do local name = gms[i][1] if name == nil then return name end cmdchat('SetTeamOffline '..name) end loop_timer("check_gm", 10) end when check_gm.timer begin local t_gms = { {"[ADM]Dios"}, {"[GM]ToNy"}, {"[GM]Dynato"}, {"[GM]TheKill"}, {"[GM]Sternico"}, {"[GM]Darkes"} } for i=1, table.getn(t_gms), 1 do local t_name = t_gms[i][1] if t_name == nil then return t_name end if game.get_event_flag(t_name) == 1 then cmdchat('SetTeamOnline '..t_name) else cmdchat('SetTeamOffline '..t_name) end end end when login with pc.is_gm() begin local name = pc.get_name() game.set_event_flag(name, 1) end when logout with pc.is_gm() begin local name = pc.get_name() game.set_event_flag(name, 0) end end end Error : syntax error : [string "start"]:5: `}' expected (to close `{' at line 1) near `{' gm_list.quest:20:Abort (core dumped) Link to comment Share on other sites More sharing options...
PACI Posted May 5, 2013 Report Share Posted May 5, 2013 quest gm_list begin state start begin when login begin local gms = { {"[ADM]Dios"}, {"[GM]ToNy"}, {"[GM]Dynato"}, {"[GM]TheKill"}, {"[GM]Sternico"}, {"[GM]Darkes"},--On the last not need ',' } for i=1, table.getn(gms), 1 do local name = gms[1] if name == nil then return name end cmdchat('SetTeamOffline '..name) end loop_timer("check_gm", 10) end when check_gm.timer begin local t_gms = { {"[ADM]Dios"}, {"[GM]ToNy"}, {"[GM]Dynato"}, {"[GM]TheKill"}, {"[GM]Sternico"}, {"[GM]Darkes"}, } for i=1, table.getn(t_gms), 1 do local t_name = t_gms[1] if t_name == nil then return t_name end if game.get_event_flag(t_name) == 1 then cmdchat('SetTeamOnline '..t_name) else cmdchat('SetTeamOffline '..t_name) end end end when login with pc.is_gm() begin local name = pc.get_name() game.set_event_flag(name, 1) end when logout with pc.is_gm() begin local name = pc.get_name() game.set_event_flag(name, 0) end end end Ya has probado coger la original y volver a editarla? Link to comment Share on other sites More sharing options...
TheSanto Posted May 5, 2013 Author Report Share Posted May 5, 2013 es la original , sólo le he cambiado los nombre de los gms. Link to comment Share on other sites More sharing options...
TheSanto Posted May 5, 2013 Author Report Share Posted May 5, 2013 Ya pueden cerrar. Gracias Izaviona. izaviona 1 Link to comment Share on other sites More sharing options...
KeKo Posted May 5, 2013 Report Share Posted May 5, 2013 @Pacificador, nunca le pongas la , al ultimo elemento del array como pusiste ahi arriba. PACI 1 Link to comment Share on other sites More sharing options...
PACI Posted May 5, 2013 Report Share Posted May 5, 2013 @Pacificador, nunca le pongas la , al ultimo elemento del array como pusiste ahi arriba. Ops, se me escapó.Gracias por la advertencia, no me habia dado cuenta. Link to comment Share on other sites More sharing options...
TheSanto Posted May 5, 2013 Author Report Share Posted May 5, 2013 Ops, se me escapó. Gracias por la advertencia, no me habia dado cuenta. por si no te has dado cuenta el problema está en mi quest donde pone --On the last not need ','[/size] [size=5] Ya pueden cerrar el post. Link to comment Share on other sites More sharing options...
KeKo Posted May 5, 2013 Report Share Posted May 5, 2013 por si no te has dado cuenta el problema está en mi quest donde pone --On the last not need ','[/size] [size=5] Ya pueden cerrar el post. Yo si que me habia dado cuenta pero como ya lo habias solucionado pos ya na xd Link to comment Share on other sites More sharing options...
Recommended Posts