HomeJavaModsRepairTokens
RepairTokens
ModsJava

RepairTokens

tokens, repair, tools, fix, broken tools, new repairing, prison repair. Free Minecraft Java mod for 1.8.

⬇ Download on Spigot
Commands:
Permissions:
Usage:

Currently it only works with tools that you break blocks with.

Once a tool is broken you'll be given a tool handle (stick) that will contain the name, enchantments and lore from the previous item that broke. Hold that item and run the command /tokenrepair and if you have a token it will restore your item.

Files:

Config.yml

Code (Text):

#The valid place holders are {tokens} and {player} they can only be used in messages that use them by default.

addtokens_failed: '&CSorry, that player is invalid.'
addtokens_success: '&4Added &A{tokens} tokens &4to &A{player}&4.'
settokens_failed: '&CSorry, that player is invalid.'
settokens_success: '&4Set &A{player} &4balance to &A{tokens}&4.'
save_success: '&4Saved token data.'
tokenbalance_self_success: '&4Your balance is &A{tokens}&4 tokens.'
tokenbalance_others_success: '&A{player} &4has a balance of &A{tokens}&4 tokens.'
tokenbalance_others_invalid: '&CSorry, that player is invalid.'
tokenrepair_failed_item: '&CYou have to be holding a tool handle.'
tokenrepair_failed_balance: '&CInsufficient funds, check your /tokenbalance.'
tokenrepair_success_item: '&4Your item has been restored!'
item_broken_event: '&4Your item has broken use /tokenrepair to fix it.'

#This is all the tools that will use the token repairing system.
#Item examples:
#Axe: TYPE_AXE
#Shovel: TYPE_SPADE
#Pick: TYPE_PICKAXE
#Case doesn't matter.
#Only tools that you normally break blocks with if AutoSell is present in the server.

tools:
  - DIAMOND_PICKAXE
  - IRON_PICKAXE
  - GOLD_PICKAXE
  - STONE_PICKAXE
  - WOOD_PICKAXE

 

Plugin.yml
Code (Text):

name: RepairTokens
version: 1.0
author: Apteryx
description: Creates a new mechanic that allows players to repair items via tokens.
main: me.apteryx.repairtokens.RepairTokens
commands:
    addtokens:
      description: Add tokens to a player's balance.
      usage: /addtokens <name> <amount>
      aliases: atokens
    savetokens:
      description: Save data to the token data file.
      usage: /savetokens
      aliases: satokens
    tokenbalance:
      description: Get your current or a players token balance.
      usage: /tokenbalance [name]
      aliases:
      - tbalance
      - tbal
    tokenrepair:
      description: Repairs tool handles to their former state.
      usage: /tokenrepair
      aliases: trepair
    settokens:
      description: Sets tokens in a player's balance.
      usage: /settokens <name> <amount>
      aliases: stokens

 
Thanks clip for helping me figure out the issue.

Thanks Nmap for the great idea. :)

Commands

Plugin details

Read from the plugin's own plugin.yml.

RepairTokens is a free Minecraft Java mod. Compatible with Minecraft 1.8. Downloaded 543 times (via Spigot). Download it and open it directly in the game.

Explore more