IronKeys

IronKeys Banner

What is IronKeys?

IronKeys is a plugin, that I originally coded just for my own server and that I'm now planning to share with you. The idea is that a player should be able to open iron doors in a specific region with a specific key. The key is a predefined item which you can e.g. give to others or store in a treasure chest.

How does it work?

This plugin requires WorldGuard on your server. Inside of a WorldGuard region, any iron doors / trapdoors can be opened with a key, that has the name of that region as metadata (lore, to be exact). The key can be generated with a command. Any player, who has a key (and the permission to use keys in general) can try to open any iron door/trapdoor. If the key doesn't fit with the door in this region, a chat notice can be displayed or a sound can be played.

Why would I need this?

I use this plugin myself on an adventure map where you have to solve riddles to find a key and unlock new rooms/stories and stuff. But I could also imagine this on normal maps for griefing protection or whatever, since I added several custom settings, such as automatic close after x seconds, custom key material, automatic member adding (for regions with deny-entry flag).

Which Bukkit version?

As I programmed this to work with iron trapdoors as well, the plugin is currently only for Spigot/Bukkit versions 1.8 and above. I may create a version for 1.7 as well, depending on your feedback.

EDIT: As requested I modified the plugin to work with 1.7.9 / 1.7.10. You can download it here:

dev.bukkit.org/bukkit-plugins/irondoors/files/4-iron-keys-1-7-10/

Commands

/ironkeys or /ironkey - The base command

/ironkeys help - Displays all commands

/ironkeys reload - Reloads the config.yml

/ironkeys add <region> [amount] - Adds a key to your inventory for a given region.

<region> can also be -c (your cursor target) or -p (your player position). Underscores in region names will be converted to spaces.

[amount] is optional, default is 1

Hint: WorldGuard can have a region that is called:

__global__
It contains the whole world. Make a key with this region to open all iron doors/trapdoors in that world.

The config.yml explained

key:
  name: Key
  # The display name you'll see, when holding the key in your hand
  material: TRIPWIRE_HOOK
  # The material, the key is made of
  # Scroll down for a link to a list of available materials.
door:
  enabled: true
  # If set to false, no iron doors can be opened with keys
  auto-close: true
  # The iron door will automatically close after opening
  auto-close-delay: 1
  # The time between opening and automatic closing (in seconds)
trapdoor:
  enabled: true
  auto-close: true
  auto-close-delay: 1
  # Same as above, just for the iron trapdoor
region:
  add-member: true
  # If set to true, the user will be added to the member list of the region he opened a door in. If the WorldGuard flag deny-entry is set to true, it comes very handy, when you don't want other players to follow you in.
  remove-member: true
  # If set to true, the user will be removed from the member list of the region he opened a door in, when auto closing is enabled.
  include-parents: false
  # If set to true, IronKeys will include WorldGuard parent/child regions relations. That means a key from the parent region can open all doors within the child regions (even if not located within the parent region)
notice:
  display: false
  # If set to true, IronKeys will display notices such as when using wrong keys (others may follow)
  wrong-key: The key doesn't fit in this lock!
  # The message that will be displayed
sounds: # Currently only 1.8
  play: true
  # If set to true, IronKeys will play sounds such as when using wrong keys (others may follow)
  volume: 0.3
  # The sound volume all sounds will be played with
  wrong-key: CLICK
  # The sound that will be played. A list with currently available sound can be found below

Materials: hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html

Sounds: hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html

Permissions

  ironkeys.*:
  # Give access to all IronKeys functions
  ironkeys.reload:
  # Reloads IronKeys, default is op
  ironkeys.key.use:
  # Allows you to use a key to open a door, default is true
  ironkeys.key.add:
  # Allows you to create a key, default is op

Please report any bugs/errors. Criticism is appreciated, as this is my first plugin.


Comments

Posts Quoted:
Reply
Clear All Quotes

About This Project

Categories

Members

Recent Files