TechnoCat wrote:I think it is safe to say Ensayia's server doesn't work. None of us can connect to it. Maybe someone else host a server and see if we can connect?
It freezes for me, thus I cannot select a server to connect to.
Does it freeze after you press connect or as soon as you start the program without touching anything? I know that it likes to freeze on occasion with connection issues, I've not worked out a solution for that yet.
Hopefully sometime in the near future I can get a place to host the server so everyone can see it in action.
It freezes on start up. No interaction.
I didn't bother to look at the code(as I'm far too lazy..). Are you by chance using blocking sockets? If you are, are they in your update loop. In my opinion I think its best to make an eventful networking system. Either way, Blocking sockets in an update loop, big no no. If you hang your update loop, your entire program is stuck waiting for a packet. What if the packet never comes? DOOM.
tsturzl wrote:I didn't bother to look at the code(as I'm far too lazy..). Are you by chance using blocking sockets? If you are, are they in your update loop. In my opinion I think its best to make an eventful networking system. Either way, Blocking sockets in an update loop, big no no. If you hang your update loop, your entire program is stuck waiting for a packet. What if the packet never comes? DOOM.
Exactly. Unless you are using love.threads - that could use blocking operations.
tsturzl wrote:It freezes on start up. No interaction.
I didn't bother to look at the code(as I'm far too lazy..). Are you by chance using blocking sockets? If you are, are they in your update loop. In my opinion I think its best to make an eventful networking system. Either way, Blocking sockets in an update loop, big no no. If you hang your update loop, your entire program is stuck waiting for a packet. What if the packet never comes? DOOM.
Not using blocking sockets. I figured that out early on.
It should not even be making an attempt to connect just by starting the program. You seem to be the only person here having the lockup issue, a lot of people over on IRC tested this exact copy of the program a few months back and nobody else had problems. Not really sure what's causing it, but when I get a better net connection and can host the server I'll probably work on the program a bit more.
I don't use anything blocking or halting, not even sleep. I'm not really sure what's up because out of 10+ people that have tested this exact .love file tsturzl is the only one having it freeze up on start
Ensayia wrote:I don't use anything blocking or halting, not even sleep. I'm not really sure what's up because out of 10+ people that have tested this exact .love file tsturzl is the only one having it freeze up on start
I'm not really sure what to make of it.
Dumbness. I never tried clicking configure, I just thought since there was no response from clicking Connect that it was frozen. It does freeze when I click connect.
Perhaps set a shorter timeout(or set a timeout) for connecting.
I have the server program and am contemplating posting it. It was my first experience with LuaSocket so it's very... basic, but it gets the job done. There's not much to see with the chat program without connecting it. I was withholding the server because I wasn't sure how to set up security well, but I will likely end up rewriting huge portions of the client and server anyway.
As it stands right now the whole thing is rather cobbled together and very insecure. Back in the first version it was easy to connect to the server via telnet and make all sorts of things screwy and even crash the server. I made a few changes to prevent it but there are still ways to remotely crash the whole thing if you get creative.