Optimization lessons from a Minecraft structure locator

purplesyringa.moe

59 points by ftk_ 6 days ago


dividuum - 17 minutes ago

A few friends and me use bedrock in a similar manner to push the rules on a faction PvP (player-vs-player) server 10 years ago: Basically a faction was a group of players working together on their base. You could claim land and a base on it was then protected from modification by outside players as long as players from your faction didn't die too often. We didn't really participate in PvP (we sucked :-} ), basically never died but did other interesting redstone stuff like vending machines, etc. But other factions did and they were always at risk of becoming raidable as a result of dying too often. Once a base was raidable is was almost always immediately completely destroyed and stripped of anything remotely valuable.

So we figured we might host one of those faction within our claimed land. As long as they store all valuable within our secure base, the fact that their claimed land becomes raidable doesn't really matter. Claimed land had to be at least one block apart from each other. So we had to find a bedrock tunnel: On their claimed land there needed to be free space within the bedrock level to get down to z=-63. Then on the single unclaimable block between our bases we needed bedrock on z=-61 and bedrock on -62/-63 on both sides. Then on our claimed land we again needed a way to get up from z=-63. Basically a single block long fully bedrock-enclosed tunnel. Took a while to find that, but we managed to set it up and caused quite a stir with other players and the server admins once our hosted faction got raidable without consequences :-)

chaps - 5 hours ago

If anyone's interested in this sort of puzzle, the game Noita is filled with them. A large chunk of the code's in lua and you can inspect it!

The final puzzle for the game is a cryptographic puzzle that's been unsolved for five years now. Folk have done just about everything imaginable to solve the puzzle.

jmalicki - 6 hours ago

This is a great real world example of where leetcode is useful.

bombcar - 5 hours ago

One of the nice features of one of the mods I've used is making bedrock one level thick, and flat everywhere. Feels nice to me.

rirze - 6 hours ago

Interesting problem.