owenashurst / agar.io-clone

Agar.io clone written with Socket.IO and HTML5 canvas
MIT License
2.88k stars 1.12k forks source link

Server breaks if someone incorrectly guesses password #519

Closed TK0805 closed 1 year ago

TK0805 commented 6 years ago

I made my own server thru Heroku, and whenever someone incorrectly guesses the password, the whole server shuts down. So. Is there any way to make that not happen?

IamBlockMan commented 6 years ago

can you paste the server's log here?

dotgodly commented 6 years ago

You have to have a MySQL database to login. You can set up the connection in config.json

PatheticMustan commented 5 years ago

Works every time. Every time my friend dies, he tries to log in with an incorrect password, crashing the server, and restarting everybody.

owenashurst commented 1 year ago

The SQL has been refactored out into its own repository for logging. It's wrapped in a .catch() to prevent the whole server shutting down after it throws an exception. Originally, this was due to the fact no MySQL server had been setup. For the sake of simplicity, it would probably make sense to use SQLLite. Please feel free to submit a PR if you fancy.

owenashurst commented 1 year ago

Fixed in the latest commit to master https://github.com/owenashurst/agar.io-clone/commit/d7717aa9fa2c29670985920c7783a40a143e0e9c