Minecraft-client networking library in Python
Go to file
2013-11-06 09:31:55 -08:00
networking Fix for 0x64 change 2013-09-25 01:08:03 +05:00
plugins Added optional colorama dependency to allow colours in windows console 2012-12-31 07:20:06 +05:00
pynbt Formatting 2012-12-26 01:38:02 +05:00
.gitignore Fix requirements.txt to actually work correctly. 2012-10-26 09:24:31 -04:00
bots.py Rebase bots branch off master, slightly rewritten and a fun new thing added 2013-09-25 00:31:17 +05:00
LICENSE Licensed under Apache License, Version 2.0 2012-10-10 14:29:32 +05:00
pluginloader.py Added optional colorama dependency to allow colours in windows console 2012-12-31 07:20:06 +05:00
README.md Added optional colorama dependency to allow colours in windows console 2012-12-31 07:20:06 +05:00
requirements.txt Remove wxPython 2012-10-26 09:52:23 -04:00
start.py Update start.py 2013-10-01 14:18:06 -06:00
Utils.py Formatting 2012-12-26 01:38:02 +05:00

pyCraft

Minecraft Python Client!

When running start.py, make sure you duck.

#Requirements

  • pyCrypto 2.5 (Also in requirements.txt)

##PyCrypto on Windows Systems (32 bit) If you use Python 2.7 with win32 you're in luck, theres an installer right here for pyCrypto 2.5 otherwise you're gonna need to compile it, followed by some fancy instructions on how to install pyCrypto over here


On linux you'll need the build-essential and python-dev packages after which running pip install -r requirements.txt, should pull everything in.

Eventually we'll put some run instructions here but start.py --help should cover everything for now

#Writing Plugins for pyCraft pyCraft has some basic plugin support, as a developer making plugins is a simple process. In the plugins folder, simply create a .py file with your plugin's name as the file name. In your plugin.py file define a single class with the exact same spellings as your plugin file name. Now within your plugin class you'll be notified using certain methods when things happen in the minecraft world. See the PacketDumper plugin as an example. Currently these methods are used:

onEnable(self, parser, pluginloader) This fires when your plugin is loaded and passes the option parser as an argument allowing you to add custom command line options

onDisable(self) This fires when pyCraft is exited cleanly, use it for cleaning up

optionsParsed(self, parsedOptions) This fires when command line options have been parsed allowing you to get information from any parameters you may have added in onEnable

packetReceive(self, packetID, receivedPacket) This fires when pyCraft's networking core receives a packet