Filled Item Chip Away

Discussion in 'Plugin Requests' started by RainingDolphins, Mar 23, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    RainingDolphins

    This plugin is similar to the GoldBleed plugin I requested the other day but I decided to remake my request so the plugin would also be useful on other servers than just my own.

    Plugin category:
    Mechanics/Fun

    Suggested name: ItemChipAway

    What I would like: When a player takes damage they will drop one random item out of their inventory. A configuration can be used to specify what items can be dropped when players receive damage. Please make the config something like this:

    Items players can drop:
    - gold_ingot
    - mushroom_stew


    This config says that players will drop either a gold ingot or a mushroom stew if they take damage. (if they do not have either of these items in their inventory they won't drop anything when they take damage.)

    Ideas for commands: No commands needed for this plugin.

    Ideas for permissions: No permissions needed for this plugin.

    When I'd like it by: As soon as possible would be nice but i'm in no rush. :)

    This plugin is good for kitPvP servers that want to give players rewards for attacking another player but don't want them to have to kill the player in order to receive these awards. This plugin is also good for any server that would like to be more challenging and require its players to be more careful about taking damage. For example if you fell in a lava pool you would loose a lot of items because you would drop one every time you took damage.


     
  2. Offline

    htmlman1

    I can make this for you, though it would take about a day - if only because of outside obligations and debugging.
     
  3. Offline

    RainingDolphins

    @htmlman1
    Ok that would be awesome! and thats fine. :)
     
    Last edited: Mar 25, 2015
  4. Offline

    htmlman1

    @RainingDolphins

    Alright, I've finished your plugin! Here's the link:

    https://www.dropbox.com/s/vqfl2e5xzibp1vq/ItemChipAway.jar?dl=0

    I've added the features that you requested, and a few more for convenience's sake. Here's the general layout of the config file:

    Code:
    toggle: ON
    chance: 100
    items:
    - GOLD_INGOT
    - MUSHROOM_SOUP
    These are the default options for the config file. I'll explain their effects:
    • toggle - Controls whether the plugin is on or not. Values can be ON or OFF respectively.
    • chance - The chance of the plugin doing its stuff. 100 is at all times, 0 is for never. This works as a percentage, though make sure you omit the % sign. (For example, 57% would be 57).
    • items - A list of the items that can drop. The names within are based right off the way they're referred to in the code. Here's a list of the names:
    https://github.com/Bukkit/Bukkit/blob/master/src/main/java/org/bukkit/Material.java

    Scroll down a little bit to see a large list of names. They should contain any and all items you want to include in the list.

    I've also added one permission to the plugin:
    • itemchipaway.exempt - If a player has this permission, this plugin will ignore them when they take damage and won't try to steal items.
    Tell me if there are any bugs!
     
  5. Offline

    RainingDolphins

    @htmlman1

    I'm sorry for the late reply. Thank you so much this is awesome! :) I just tested it and it works perfectly thank you so much!
     
  6. Offline

    htmlman1

    Oh, no problem about the late reply, haha. You're welcome :)
     
  7. Offline

    nverdier

  8. Offline

    RainingDolphins

    @nverdier Oh yeah sorry about that. I just fixed it thanks for reminding me. :)
     
Thread Status:
Not open for further replies.

Share This Page