EnchantShops - buy enchantments through signs!
Notice
Sorry for the delayed update! D: Currently i am working on allowing enchants to buy purchasable though money and/or xp, but the Bukkit API is very unstable with changing the xp. Will have the update ASAP.
Description
What is EnchantShops? EnchantShops makes getting enchantments easier! Instead of having to battle hundreds of Zombie Pigman to get experience, then having to craft an Enchantment Table, and going though the trouble of building a room, you can simply buy them though signs! EnchantShops allows users to right-click signs and buy the enchantment specified on the sign.
Features
- Configurable enchantment aliases
- Option for using economy through vault or an Item Economy
- Configurable tags and color-codes used in declaring EnchantShops
- Option for disabling and enabled certain enchantments
Commands
/listenchants - list enchantments and their start levels and max levels. For a complete list on the enchantments and the items they enchant, please visit this page.
/enchant-alias <enchantment> - get the alias for an enchantment (not case sensitive).
/enchant-shoptag - get the shop tag required at the top of the EnchantShop.
Permissions
enchantshop.buy - allows users to buy enchantments from signs.
enchantshop.getalias - gives users rights to use '/enchant-alias <enchantment>'.
enchantshop.getshoptag - gives users rights to use '/enchant-shoptag'.
enchantshop.shop.create - gives users rights to build EnchantShops.
enchantshop.shop.delete - gives user rights to remove EnchantShops.
Config
- properites:
- permissions: false - enable permissions
- useVault: true - if true it will use the economy provided through vault, otherwise use Items as the economy
- materialID: 266 - the material id used for the Item Economy
- item-alias: Gold Bar - the alias used for the item for the Item Economy
- shop-tag: [EnchantShop] - the shop tag required at the top of an EnchantShop
- shop-colorcode: '3' - the color code used for coloring the shop-tag on an EnchantShop
- enchant-aliases:
- ARROW_KNOCKBACK: ARROW_KB
- ARROW_INFINITE: ARROW_I
- DAMAGE_UNDEAD: DAMAGE_U
- LOOT_BONUS_BLOCKS: LT_BS_BLOCKS
- LOOT_BONUS_MOBS: LT_BS_MOBS
- PROTECTION_ENVIRONMENTAL: PROT_ENV
- PROTECTION_EXPLOSIONS: PROT_EXP
- PROTECTION_FALL: PROT_FL
- PROTECTION_PROJECTILE: PROT_PROJ
- PROTECTION_FIRE: PROT_FIRE
- DAMAGE_ARTHROPODS: DAMAGE_APODS
- WATER_WORKER: WATER_WKR
- enchant-states
- DURABILITY: true
- PROTECTION_ENVIRONMENTAL: true
- LOOT_BONUS_BLOCKS: true
- PROTECTION_FIRE: true
- DIG_SPEED: true
- PROTECTION_FALL: true
- SILK_TOUCH: true
- PROTECTION_EXPLOSIONS: true
- PROTECTION_PROJECTILE: true
- OXYGEN: true
- WATER_WORKER: true
- ARROW_INFINITE: true
- DAMAGE_UNDEAD: true
- ARROW_FIRE: true
- DAMAGE_ALL: true
- ARROW_KNOCKBACK: true
- KNOCKBACK: true
- ARROW_DAMAGE: true
- DAMAGE_ARTHROPODS: true
- LOOT_BONUS_MOBS: true
- FIRE_ASPECT: true
How to create EnchantShops
Creating an EnchantShop is easy. Simply put the shop-tag (declared in the config and obtainable in-game via command '/enchant-shoptag') on the first line. On the second line, put the enchantment's alias if provided, otherwise put the enchantment's name. On the third line, put the level associated with the enchantment (declared in the config and obtainable in-game via command '/enchant-alias <enchantment>'). Then finally on the fourth line, put the price of the enchantment.
@Tauryuu
The best I could do is add an option for money or xp. Perhaps something like this: "15.00:100"
Can you put more than one compatible enchantment on a single tool, after the first enchantment has been placed?
@goofybud16: That would be "FORTUNE," not "LOOT_BONUS_BLOCK." The enchantment names that won't fit are as follows: Projectile Protection, Blast Protection, and Bane of Arthropods. Of those, only Bane of Arthropods is considered to be even remotely useful. If someone disagrees about the first two, they can easily get them in the usual fashion. I guess that abbreviating the protections to PROJECTILE_P, BLAST_P, and perhaps FIRE_P, while we're at it, sounds reasonable, while BoA could just be ARTHROPODS.
As for what enchantments can go on what items, just use the wiki page on enchanting. Once you've taken one look, you should really have it memorized. If you need a summary to help your memory, read this:
All protections go on all armors.
Feather falling is for boots.
Aqua Affinity and Respiration are for helms.
Bows have the simply-named enchantments of offense, namely Power, Punch, Flame, and Infinity.
Swords have all the other offensive enchantments (Sharpness, Smite, BoA, Knockback, Fire Aspect, and Looting).
Efficiency, Silk Touch, Unbreaking, and Fortune (the enchantments that are obviously about resource-gathering) are applicable to all three of the resource-gathering tools, pickaxes, axes, and shovels.
It's really that simple.
@Randude14: A lot of shop plugins use #:# or B #:S # to segregate buying and selling prices on a single sign, and those usually involve left-clicking and right-clicking. I don't see why you couldn't use a colon to make two buying costs, where the first is the Vault price and the second is EXP. The only thing that you should know about is that setting EXP prices would have to either A) involve the same coding as enchanting costs or B) be simple numbers that represent actual EXP points, not the levels. Which you go with is up to whether you want to make the coding or the usage more complex.
Hey, a better way to see enchantments? I want to see more then like the last 10... Maybe useable from in-terminal, or a link to all the enchants from the post?
Other than that.... HOLY SHIT WHERE HAS THIS PLUGIN BEEN SINCE ENCHANTING WAS SUPPORTED BY BUKKIT??????
Little Loud? lol
EDIT: Some enchantments don't fit on the sign. Give them a number maybe? Like it will put LOOT_BONUS_BLOCK when I put 10 on the #2 line? Also, on that list, can we have what is for what? Like for helmets, tools, chestplates, etc.
I would like to suggest charging gold ingots for enchantments, thanks.
@Tauryuu
Yes I could add that, but idk how that would fit on a sign though :/
Is it possible to make it charge both money and EXP? That would be boss :)
AWESOME!
Downloaded It!