PiggyCustomEnchants

PiggyCustomEnchant's documentation page includes the configuration and API documentation.

  • Information

    PiggyCustomEnchants is PocketMine-MP's first public custom enchantments plugin created in April 29, 2017 by MCPEPIG (DaPigGuy).
    If you require additional support with our plugin, then feel free to join our discord server.

    As of October 11, 2019, PiggyCustomEnchants has been completely rewritten from scratch. Click the box below to learn more.

    Version 2.0.0 is a complete rewrite of the plugin and introduces tons of bug fixes, optimizations, and quality of life changes.
    All custom enchantments in Version 1.4.6 have also been ported to Version 2.0.0.

    • Enabling/disabling enchantments in certain worlds/globally is now built into the plugin. (#94)
    • Added a remote enchant disabler for emergency situations (disable affects all servers).
    • Custom enchantments that are disabled will not have their tasks enabled.
    • Execution chances of enchantments are now configurable.
    • Custom enchantments are now registered into PocketMine-MP.
    • Now using Commando virion for command handling.
    • The form version of /ce has been improved upon.
    • Explosive enchants now have a toggle for world damage.
    • Added checks for applying books. (#209)
    • Parachute now uses negative Levitation effect to simulate slow falling.
    • Fixed issue where throwing a projectile and switching to a different weapon would trigger the custom enchants of that weapon. (#157)
    • Fixed "WitherSkull Enchant does not apply Wither Effect." (#182)
    • Fixed pigs/wither skulls remaining. (#189)
    • "Maximum -5 is less than the minimum 0" issue has been fixed. (#211)
  • Default Configuration

    Explanation

                                   
    Key Index Explanation
    rarity-colors common, uncommon, rare, mythic Any of the following color values are accepted for any index:

    Accepted values: black, dark_blue, dark_green, dark_aqua, dark_red, dark_purple, gold, gray, dark_gray, blue, green, aqua, red, light_purple, yellow, white
    enchants position Choose whether to show enchants in name or lore of the item.

    Accepted values: name, lore
    roman-numerals If set to true, then the plugin will show enchantments in roman numerals. Otherwise, it will show as normal numbers.

    Accepted values: true, false
    forms enabled If set to true then the plugin will use forms instead of chat. Otherwise, it will use chat instead.

    Accepted values: true, false
    disabled-enchantments [] List enchantments that you want to be disabled globally in here.
    Example: ["Porkified", "Gears"]

    Accepted values: enchantment names, enchantment ids
    per-world-disabled-enchants worldNameList enchantments that you want to be disabled per-world here.
    Example: NoJetpacks: ["jetpack"]

    Accepted values: world name, enchantment names, enchantment ids
    world-damage blaze, bombardment, explosive, lightning, missile If set to true, then the enchantments will deal damage to the world. Otherwise, the enchantments will not.

    Accepted values: true, false
    chicken drops List drops that the Chicken enchant should have a chance at dropping (all equal %)
    Example: ["266:0:1", "id:meta:count"]

    Accepted values: item id, item meta, amount of items
    miscellaneous armor-hold-equip Enables PiggyCE's implementation of click/hold armor to equip from hotbar, which is not implemented in pmmp.

    Accepted values: true, false
    chances [enchants] Set the chance to activate REACTIVE-type enchantments. Reaction chances are defined as multiplier ∗ enchantment level.

    Accepted values: lowercase enchantment names, chance multiplier

    Adding/removing a custom enchantment.

    As of v2.0.0, you can add/remove enchantments directly from PocketMine-MP's enchantment functions instead of our own.

    Function Parameters
    $item->addEnchantment(new EnchantmentInstance($enchantment, $level)); $enchantment = ID of custom enchant to add
    $level = level of enchant to add
    $item->removeEnchantment($enchantment); $enchantment = ID of custom enchant to remove

    Getting custom enchantments by name/ID

    Function Parameters Returns
    CustomEnchantManager::getEnchantment(int $id); $id = ID of the custom enchant CustomEnchant if successful, else null.
    CustomEnchantManager::getEnchantmentByName(string $name); $name = name of custom enchant CustomEnchant if successful, else null.

    Registering/unregistering a custom enchantment

    As of v2.0.0, unregistering enchants will also automatically cease task-related activities for those enchants.

    Function Parameters
    CustomEnchantManager::registerEnchantment(new CustomEnchant(Plugin $plugin, int $id, int $rarity = self::RARITY_RARE)); $plugin = your plugin main
    $id = ID of custom enchant
    $rarity = rarity of enchant
    CustomEnchantManager::unregisterEnchantment(int $id); $id = ID of custom enchant

    Any custom enchants that you want to be added? Submit your ideas here!

    Type Enchantment Description
    Armor Anti-Knockback Reduces knockback per armor piece.
    Armored Sword-inflicted damage is reduced.
    Berserker Gain strength when low on health.
    Cactus Deal damage to nearby enemies.
    Cloaking Gain invisibility when hit.
    Cursed Inflicts Wither upon hitting enemy.
    Drunk Inflicts Slowness, Mining Fatigue, and Nausea upon hitting enemy.
    Endershift Gain Speed and Absorption when low on health.
    Enlighted Gain Regeneration when hit.
    Forcefield Deflects projectiles and living entities in a radius dependent on enchantment level.
    Frozen Inflicts Slowness upon hitting enemy.
    Hardened Inflicts Weakness upon hitting enemy.
    Heavy Axe-inflicted damage is reduced.
    Molten Sets an enemy on fire when hit.
    Obsidian Shield Gain Fire Resistance while equipped.
    Overload Gives extra health (stackable).
    Poisoned Inflicts Poison when hit by an enemy.
    Poisonous Cloud Creates a cloud of poison around entity, giving poison to anyone who enters.
    Revive Gain another life, but removes a level from armor.
    Revulsion Inflicts Nausea for when hit by an enemy.
    Self Destruct Spawns TNT when you die.
    Shielded Gives Resistance while worn (stackable).
    Tank Decreases damage from bows.
    Helmet Antitoxin Grants immunity to poison.
    Focused Negates or reduces the effects of nausea.
    Glowing Gain Night Vision while equipped.
    Implants Replenishes hunger and air when moving.
    Meditation Replenishes health and hunger every 20 seconds when not moving.
    Chestplate Chicken Lay eggs every 5 minutes with a chance of rare drop.
    Enraged Gain Strength while equipped.
    Parachute Slows your descent above 3 blocks.
    Prowl Gain Invisibility and Slowness while sneaking.
    Spider Ability to climb walls.
    Vacuum Suck up nearby items.
    Boots Gears Gain Speed while equipped.
    Jetpack Flies in the direction you are facing when you sneak.
    Magma Walker Temporarily turns lava into obsidian around you.
    Springs Gain a small jump boost.
    Stomp Deal damage to enemy when taking fall damage.
    Weapon Aerial While in air, damage increases.
    Backstab Backstabbing enemies deals increased damage.
    Blessed Grants a chance to remove harmful effects during combat.
    Blind Inflicts Blindness upon hitting enemies.
    Charge Damage increases while sprinting.
    Cripple Inflicts Nausea and Slowness upon hitting enemy.
    Deathbringer Increases damage inflicted.
    Deep Wounds Inflict on enemies deep wounds that cause bleeding.
    Disarming Grants chance to disarm enemy.
    Disarmor Grants chance to disarmor enemy.
    Gooey Flings enemy into the air.
    Hallucination Grants chance of trapping enemies in a fake prison.
    Lifesteal Steals health upon hitting enemy.
    Lightning Chance to strike enemies with lightning.
    Poison Inflicts Poison upon hitting enemies.
    Vampire Converts damage dealt into health.
    Wither Inflicts Wither on enemies.
    Bow Auto Aim Automatically aims to the nearest target.
    Blaze Shoots blazing fireballs.
    Bounty Hunter Grants chance to obtain treasure from hitting enemies.
    Bombardment Bombard enemies with TNT when shot.
    Grappling Pulls you to the arrow. If enemy is hit, the enemy will be pulled to you.
    Headhunter Headshots deal more damage.
    Healing Heals target for inflicted damage + extra health.
    Homing Arrow will home in on the nearest entity.
    Missile Spawns TNT where arrow lands.
    Molotov Starts a fire where arrow lands.
    Paralyze Inflicts Slowness, Blindness, and Weakness upon hitting enemies.
    Piercing Ignores armor when dealing damage.
    Porkified Oink! Shoots pigs, leaving a mysterious pork behind when killed.
    Shuffle Switches position with target.
    Volley Shoots multiple arrows in a cone shape.
    Wither Skull Shoots wither skulls.
    Tools Driller Drills a 3 by 3 hole.
    Energizing Gain Haste when a block is broken.
    Explosive Causes an explosion when a block is broken.
    Quickening Gain Speed for upon breaking block.
    Smelting Automatically smelts drop when block is broken.
    Telepathy Automatically puts drops into inventory.
    Pickaxe Haste Gain Haste while tool is held.
    Oxygenate Gain Water Breathing while item is held.
    Jackpot Grants chance to increase ore tier.
    Axe Lumberjack Breaks all logs connected to each other.
    Hoe Farmer Automatically replaces seeds when crop is broken.
    Fertilizer Tills land in a radius dependent on enchantment level.
    Harvest Harvest crops in a radius dependent on enchantment level.
    Damageable Autorepair Items automatically repair while moving
    Global Soulbound Keeps item after death, but removes a level from armor.
    Compass Radar Points towards the nearest player.
    Enchantment Incompatible Enchants
    Blaze Porkified
    Wither Skull
    Grappling Volley
    Grow Shrink
    Homing Blaze
    Porkified
    Wither Skull
    Porkified Wither Skull