Alexander Pruss's Blog

2 min read
21 September 2022

This is very attractive because my kids are really into Minecraft. But we don't have an PI and, while they're inexpensive, they require an HDMI display device, and we don't have one. It turns out that there are plugins (e.g., Raspberry Juice for Bukkit) for Minecraft servers that use (most of) the protocol of the PI, however it's not a good idea to run a private server just to do this.

In January, I developed an mod for Minecraft 1.8 and Forge that implements the majority of the Raspberry PI protocol and works with most of the python scripts that work with Minecraft PI Edition. For example, here's a spiral and a glass torus with water inside.

To install, you'll require Python, Minecraft 1.8, Minecraft Forge, my Raspberry Jam Mod and the Minecraft PI Python package. Then:

1. Install Forge for 1.8. 2. Create a Minecraft profile that utilizes it. 3. Create a mods subdirectory to your Minecraft directory (%appdata%\.minecraft on Windows, I believe). 4. My mod is now in the mods directory. 5. Create an mcpipy subdirectory to your Minecraft directory. 6. Copy the contents of the Minecraft PI Python package into the mcpipy directory. 7. Create a Minecraft profile that makes use of the 1.8 Forge. 8. Run Minecraft and create a new world. 9. Run python scripts via commandline or directly into Minecraft with the command /py scriptname. E.g. the command with /py nt7s_sphere, you can draw the shape of a sphere.

The scripts communicate with Minecraft via ASCII messages that are sent over port 4711. This article explains the Python API. The subset I implement is the Raspberry Juice one. There's a lot of information about python programming for Minecraft here (and the author of that site has a book which I've ordered for my children but hasn't arrived yet).

In case you have found a mistake in the text, please send a message to the author by selecting the mistake and pressing Ctrl-Enter.
Pape Junker 0
Joined: 1 year ago
Comments (0)

    No comments yet

You must be logged in to comment.

Sign In / Sign Up