Sueta

BHarvester [Inactive]

1.0.1

Automatically replant and sell harvested crops.

·Plugin

BHarvester
BHarvester is a plugin which allows players to automatically replant, collect and sell crops harvested using a harvester hoe.

Faster support, feedback, suggestions and update notifications can be found on my plugin support discord here.

Features

  • Entirely customisable (see configuration below).
  • Send title, sub title, action bar and chat messages to player when they harvest an item.
  • Select min/max drop amounts per crop.
  • Supports all crop types in all versions.
  • Spigot 1.8 - 1.14+ support.
  • Ability to drop harvested items when the player's inventory is full.
  • Toggle between automatically selling and collecting items.
  • Active development and support.

Dependencies

  • BCommons (download, source)
  • Vault + Economy Plugin (optional, if you want to use the autosell feature)
  • ProtocolLib (optional, if you want to use actionbars/titles)

Commands & Permissions
/harvester
- bharvester.cmd.harvester
/harvester give <player> [amount] - bharvester.cmd.harvester.give
/harvester reload - bharvester.cmd.harvester.reload

Images

Files

config.yml
# BHarvester by Bradley Steele (Ibiza).
#
# /Contact
# Spigot: https://www.spigotmc.org/members/292138/
# Discord: Bradley#4169
# Discord Support Server: https://redirect.bradleysteele.me/bps
#
#
# /Information
# BHarvester allows players to harvest crops and automatically
# replant them and sell the dropped items.
#
# If you have an invalid setting, the plugin will do its best
# to use its default setting without causing any issues.
#
# If you have any questions, suggestions, features you'd like
# to see added or report any bugs, do not hesitate to contact
# me.


# Do not change this number. You will be notified if a new
# configuration version is available.
config-version: 1


harvester:

  # Automatically sells crops which have the 'price' tag, see default
  # wheat for more information.
  #
  # Requires Vault and an economy handler such as Essentials.
  autosell: false

  full:

    # Should the items drop if the players inventory is full. If
    # false, then the block will not be harvested.
    #
    # Next version will include optional messages (title, etc).
    drop: false

  cancel-non-crops:

    # Prevents non-crops from being mined when using the harvester
    # item, useful to prevent players wasting the durability of a
    # breakable harvester.
    enabled: true

    # The message to be sent to the player when they attempt to mine
    # a non-crop item and the above is true. Leave blank for no
    # message.
    message: ''

  item:
    # The item type, materials can be found here: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html
    # Note: material types will vary depending on version.
    material: DIAMOND_HOE
    # The amount of damage the item has, this is also used for certain items such as
    # potions, stained glass, wool, etc. For example, use 'damage: 13' for red wool,
    # and make sure the material (above) is wool.
    damage: 0
    # The display name of the item, uses & for colours.
    name: '&aHarvester Hoe'
    # The lore of the item, can add as many lines as you want.
    lore:
    - '&7Automatically replants your crops.'
    # Sets whether the item is unbreakable.
    unbreakable: true
    # Adds an Enchantment glow effect without displaying any enchantments in
    # the item lore.
    #glow: true


crops:
  wheat:
    # The block which represents the below settings, this is necessary
    # in order for this plugin to support 1.8+
    block: CROPS # 1.13+: WHEAT
    # The text to replace {crop} placeholders in the locale.yml.
    name: '&aWheat'
    # The price PER drop, requires auto sell to be enabled.
    #price: 100
    # Minimum amount of items to drop when this item has been harvested.
    drop-min: 1
    # Maximum amount of items to drop when this item has been harvested.
    drop-max: 1
    # If the player should receive a message when successfully harvesting
    # this item.
    message: true
    # Note: title, subtitle and actionbar require ProtocolLib.
    #
    # If the player should receive a title message when successfully
    # harvesting this item.
    title: true
    # If the player should receive a subtitle message when successfully
    # harvesting this item.
    subtitle: true
    # If the player should receive a actionbar message when successfully
    # harvesting this item.
    actionbar: true

  carrot:
    block: CARROT # 1.13+: CARROTS
    name: '&aCarrot'
    drop-min: 2
    drop-max: 4
    actionbar: true

  potato:
    block: POTATO # 1.13+: POTATOES
    name: '&aPotato'
    drop-min: 2
    drop-max: 4
    actionbar: true

  # Beetroot was introduced in 1.9, if you are running an earlier version
  # you can remove this section completely.
  beetroot:
    block: BEETROOT_BLOCK # 1.13+: BEETROOTS
    name: '&aBeetroot'
    drop-min: 2
    drop-max: 4
    actionbar: true

  netherwarts:
    block: NETHER_WARTS # 1.13+: NETHER_WART
    name: '&aNether Warts'
    drop-min: 1
    drop-max: 3
    actionbar: true

  cactus:
    block: CACTUS
    name: '&aCactus'
    drop-min: 1
    drop-max: 1
    actionbar: true

  sugarcane:
    block: SUGAR_CANE_BLOCK # 1.13+: SUGAR_CANE
    name: '&aSugar Cane'
    drop-min: 1
    drop-max: 1
    actionbar: true
locale.yml
# BHarvester by Bradley Steele (Ibiza).
#
# /Contact
# Spigot: https://www.spigotmc.org/members/292138/
# Discord: Bradley#4169
# Discord Support Server: https://redirect.bradleysteele.me/bps


# Use {prefix} in any of the messages and it will
# be replaced with the below.
prefix: '&7[&6BHarvester&7]'


command:
  no-permission: '{prefix} &7You do not have permission for that command.'
  unknown: '{prefix} &7Invalid usage, use &e/{args}&7.'

  unknown-player: '{prefix} &7Unknown player: &c{player}&7.'

  # /harvester give
  harvester-give: '{prefix} &7Gave &a{player} &e{amount}&7x harvester hoes.'

  # /harvester reload
  harvester-reload: '{prefix} Successfully reloaded &eBHarvester&7.'


# Messages which are sent when a player harvests a crop, these messages
# can be enabled/disabled in the config.yml.
crop:

  pickup-message: '{prefix} &7Harvested &e{amount}&7x &a{name}&7.'
  pickup-title: '&6Harvester'
  pickup-subtitle: '&7Harvested &e{amount}&7x &a{name}&7.'
  pickup-actionbar: '&7You automatically harvested &e{amount}&7x &a{name}&7.'

  autosell-message: '{prefix} &7Sold &e{amount}&7x &a{name}&7 for &e${price}&7.'
  autosell-title: '&6Harvester'
  autosell-subtitle: '&7Harvested &e{amount}&7x &a{name}&7.'
  autosell-actionbar: '&7Sold &e{amount}&7x &a{name}&7 for &e${price}&7.'

config-change-available: '{prefix} &7A config change is available. Current: &c{current} &7New: &a{new}&7.'

Similar projects

Plugin →