The old Python version
EnderpearlCheck
This is a plugin for Bukkit written in Python to control the teleport behavior of enderpearls using the factions plugin functionality. It allows to teleport using enderpearls into the players faction territory, Wilderness, SafeZone and Warzone. It blocks enderpearl teleportation into foreign factions territory.
The consequence is, you cannot just use enderpearls to go into a foreign base which is protected by walls - you need other means, like TNT person cannons or plugins like airships or parachutes. The allowed landing zones can be configured from inside the plugin, there is no sophisticated config yet. Basically the plugin catches the teleport event and cancels it if the teleport is caused by an enderpearl and the landing zone conditions are met. Check the code - its easy. Without factions the plugin just breaks and does nothing but spitting out error messages into your server log.
Installation:
- Install and configure Factions - http:dev.bukkit.org/server-mods/factions/
- Install Python Plugin Loader - http:dev.bukkit.org/server-mods/python-plugin-loader/
- Put the folder "EnderPearlCheck.py.dir" in your servers plugin folder
- Restart server
Keep in mind this is a first developer version - so there isn't much documentation or configuration.
Configuration:
At line 50 of the plugin.py file you find this code:
## Is the landing zone allowed? If yes allow Enderpearling if TFaction.getTag() in ["\xa72Wilderness","WarZone","SafeZone"]:
In the square brackets you find a list with the tags of factions that are allowed to teleport into. Format is ["tag1","tag2","tag3"] with as many tags as you like. The tags are case sensitive. You can find these tags in the factions plugin configuration file "factions.json".
The Wilderness "faction" tag in the example above has a color code in it "§2Wilderness" (see factions.json file). This translates to "\xa72Wilderness" in the Python code. The "\x" means "extension of standard Ascii coming as a hex code". ("a7") is the hex code for for the letter "§" which isn't a standard Ascii letter. The "2" is the number for "DarkGreen". So you get "\xa72" which equals "§2" here.
I hope that helps a bit, but basically the plugin does what it tells and doesn't need any configuration. If you want to add allowed factions or tweak its logic its easy - no eclipse, no compilation - just hack into the file and there you go.