|
|
|
|
|
by stjo
1739 days ago
|
|
I wrote effectively the same thing without AWS lambdas https://playmcnow.com/ It’s so cheap[1] to start and stop servers on demand that I’ve decided to give “away” servers for free. I wrote a little proxy in Go that detects minecraft login requests and starts a server with the specific world. After a dropped connection I stop it. [1] For 15€/month you can have ~30 servers running in parallel and thousands of powered down worlds. https://contabo.com/en/vps/ |
|
1) Initial world creation is quite slow - 10-15 seconds on a moderately powerful hardware. Since I want first joins to be as fast as possible, I keep 1000 pre-generated worlds and one of them is chosen randomly to be used as template on your first login.
2) In addition to login packets, minecraft clients send a ping packet to check if the server is online. I forge a valid response because I don't want to start a server just so you can see "server is up, 0 players online".