Minecraft Server Wrapper

Noah Petherbridge
kirsle
Posted by Noah Petherbridge on Wednesday, February 12 2014 @ 04:33:24 PM
This is something I've been wanting to program for a while, and I finally have.

It's a Python app that wraps the Minecraft server and makes the server console available over a separate TCP socket (with password authentication, of course).

This allows you to telnet in to this TCP port, provide the password (or a challenge-response hashed version of it), and then you get access to the Minecraft server console. Anything the server outputs is broadcasted to all authenticated clients, and anything the clients send is sent to the Minecraft server. But the real strength in this isn't necessarily just being able to see and type commands into the server console (you can do this at the local shell running the server normally); it's for programs to do this automatically!

For example, you can have a whitelist of users who aren't operators, but you want them to be able to say for example !creative in the server chat window, and have their game mode switched to creative. This is one of the example scripts I included in my project, actually!

01-gamemode.py

And as a more eccentric example, I connected a simple RiveScript bot to this so that it can chat with players using the in-game chat system:

02-rivescript.py

You can get the source code and play around with this yourself at minecraft-control on GitHub!

Categories:

[ Blog ]

Comments

There is 1 comment on this page.

guest
guest
Posted on Thursday, February 27 2014 @ 09:29:39 AM by Schwartz.

I tried your script with a fantastic success.

I will continue to follow your work.

Thank a lot !

Add a Comment

Your name:
Your Email:
Message:
Comments can be formatted with Markdown, and you can use
emoticons in your comment.

If you can see this, don't touch the following fields.