Live data from Hacker News

Running a million-board chess MMO in a single process

eieio.games

1–10 of 41 posts

Re: Running a million-board chess MMO in a single process

#2
We did a very similar thing with UltimateArcade (shut down long ago) where we optimized everything to be single threaded. We had a pretty intense updates/s rate from players, and that got pretty crazy pretty fast. Actor models with single threads made things easy because we could skip locks and play with contigious chunks of memory, which as the author found, is pretty fast.

Re: Running a million-board chess MMO in a single process

#4
Could you save even more bandwidth by updating static data and letting Cloudflare cache/serve it?

ie: put the batches on disk then have the clients grab it? It would be the equivalent of frame differencing, with the total board state being saved occasionally as a keyframe equivalent.

You're doing that dynamically anyway by sending batches and snapshots to the client.

Using the above you're basically making your game board into an interactive movie that's replaying moves from disk most of the time.

Re: Running a million-board chess MMO in a single process

#6
post #5

I feel like I keep seeing one million checkboxes guy's experiments, and I wonder.... Where is the monetization? Is this just a FANGAM engineer with a lot of free time? Am I just beaten down by the SWE landscape of 2025?

Have you never made anything without trying to make a dollar on it?

Re: Running a million-board chess MMO in a single process

#8
post #5

I feel like I keep seeing one million checkboxes guy's experiments, and I wonder.... Where is the monetization? Is this just a FANGAM engineer with a lot of free time? Am I just beaten down by the SWE landscape of 2025?

He mentions he worked at Jane Street for 7 years in his "what's my deal" section of his blog. It might have given him some space to have fun for a while - and just build stuff for the joy of building stuff.

Re: Running a million-board chess MMO in a single process

#9
post #5

I feel like I keep seeing one million checkboxes guy's experiments, and I wonder.... Where is the monetization? Is this just a FANGAM engineer with a lot of free time? Am I just beaten down by the SWE landscape of 2025?

Hi! I'm the guy.

I have the savings to not worry about monetizing anything for a while. So I don't monetize my stuff. It's freeing and kinda fun!

Re: Running a million-board chess MMO in a single process

#10
post #4

Could you save even more bandwidth by updating static data and letting Cloudflare cache/serve it? ie: put the batches on disk then have the clients grab it? It would be the equivalent of frame differencing, with the total board state being saved occasionally as a keyframe equivalent. You're doing that dynamically anyway by sending batches and snapshots to the client. Using the above you're basically making your game…

I thought about not pushing snapshot/move data over websockets - one of the systems-y friends I ran my architecture by brought this up while I was speccing the site out.

You can't really put move batches on disk and have clients grab them (afaik), since the set of moves you want to send to an individual client depends on their position (and you don't want to send every move to every client).

But you could do this by not sending move batches at all, and instead having clients poll for the entire current state of the board.

The thing is, for them to get realtime-ish move updates they'd have to poll constantly. Cloudflare also has a min TTL of 1 second so there'd be more latency, and also if I screwed something up or saw more cache misses than anticipated I could end up unintentionally hammering my server.

Also if I'd had 100x more traffic (which would be crazy and well beyond what I prepared for!) I think I'd owe like $95 or so for bandwidth with my current setup. So the benefits to reducing bandwidth even more were a little marginal!

Post reply on HN