Me and my friends like to play Minecraft sometimes However, we tend to be in the middle of nowhere, with no internet. The most interesting aspect is usually the setting, not the playing.
We usually begin by sharing the most recent Minecraft binaries, and then setting up an ad-hoc WiFi connection. Wzjxzz We're then ready to go!
Minecraft generally performs DRM and verification with the Minecraft website. For the server, this option can be disabled by setting the online-mode to false in server.properties However, with the client, you're out of luck.
The initial solution was to use a smartphone to find an open WiFi network. It was possible to fake the login server before the launcher. Recently I did however discover an alternative to play offline on the client.
Spoiler alert: Minecraft is The Matrix.
That's it. It was necessary to say it. Let's hack Minecraft Matrix style.
You'll be kicked by each other when you click "Play Offline" after an unsuccessful login.
Now, start your terminal, and switch the directory to the bin folder of your Minecraft directory3.
While I'm unable to read or write Matrix as Mouse4, the GNU toolchain is able to. We'll substitute several instances of "Player" by any string with the same length.
First, extract the jar. It turns out that the jar works well as an archive and is more user-friendly.
We now need to determine which files need to be changed. Beware of Deja vu!
Some experimentation shows that MinecraftApplet.class is the one that matters. You will need to use sed to replace "Player", with another name with the same length.
Mac users will require installing GNU sed, as BSD sed scrambles the binary file beyond repair. I used brew install gnu sed, but Macports and Fink could also work.