eTokens

eTokens

Have you ever wanted to reward you players when they do something such as kill a mob, a player or for earning a hard-to-get achievement?

If so then this is the plugin for you!

eTokens is a fairly advanced system that will allow you to do just that! This project is open-source and, as a result is on Github!! To view this project, just click here or go to https://github.com/TGRHavoc/eTokens

If you're having issues and you've recently updated the plugin. Make sure you have reset the player data cache by deleting the "playerdata" folder inside of the plugin folder (Usually found in "<ServerPath>/plugins/eTokens/").

Please Read

The commands in the shop temporary OP the player. This is to allow them to execute the command they've bought. I was originally going to do this through console however, console doesn't have access to some commands (Player specific).

If players are getting OP through some glitch with this remove the "isCommand" in the shops YAML file (located in plugins/eTokens/shops/Shopname.yml) and contact me immediately so that I can fix the bug.

Updates

  • eTokens 2.1
    • Players couldn't open shops before as they required to be OP (Thanks to @Gh0stbuster) for pointing this out.
  • eTokens 2.1
    • Fixed some vital errors
    • Players now start with 0 tokens instead of -1
  • eTokens 2.0
    • You can now use "ALL" as a block-type to represent all the blocks in Minecraft
    • Shops can now sell commands
    • Integration with Vault (See XML)

XML

With this plugin comes a default, easy to configure, XML file that allows you, the server owner, to automatically reward players.

The XML is really easy to grasp. All you need to do is add a "token" tab and tell it what you want to do.

Below are some example and what attribute means what.

XML AttributeWhat it does Values
objectiveThis sets the objective that the player needs to complete in order to receive the tokenblock-break, kill, achievement
token-amountThis is the amount of tokens you want to reward the player withAny number between 0 and 2147483647
block-amountThis should only be used with the "block-break" objectives, this is how many blocks the player needs to breakAny number between 0 and 2147483647
block-typeThe type of block that the user needs to breakSee here Can now be "all" for all blocks
achievementThis should only be used with the "achievement" objective. This is the name of the achievement that the user needs to getSee here
entity-typeThis should only be used with the "kills" objective. This is the type of mob that the player needs to killSee here
killsThe amount of entities the player needs to killAny number between 0 and 2147483647
repeatableStates whether an objective can be repeated by the player (Currently only works with kills and block-break)true or false
use-tokensStates whether you want to give the player eTokenstrue or false (default true)
moneyThe amount of money you want to give to the player (Uses vault)Any double between 0.0 and Infinity

Below is an example XML file:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<tokens>
    <token block-amount="10" block-type="DIAMOND_ORE" objective="block-break" token-amount="10">
         Well done {PLAYER}, have received {TOKEN-AMOUNT} token(s) for breaking {BLOCK-AMOUNT} {BLOCK-TYPE} block(s)!
     </token>
    <token achievement="BUILD_PICKAXE" objective="achievement" token-amount="10">
         You have received {TOKEN-AMOUNT} tokens for getting the achievement {ACHIEVEMENT}!
    </token>
    <token entity-type="ZOMBIE" kills="10" objective="kill" repeatable="true" token-amount="10">
          You have received {TOKEN-AMOUNT} tokens for killing {KILLS} {ENTITY-TYPE}(s)!
    </token>
</tokens>

Commands:

The commands that come with this plugin allow you to control how many tokens each player has.

Command Description
/token add <Player> <Amount>Add a specified amount of tokens to the players' account
/token [remove/take] <Player> <Amount>Remove specified tokens to this players' account
/token set <Player> <Amount>Set this players token count
/tokens give <Player> <Amount>Give this player some of your tokens
/shop create <Name>Create a shop with the specified name (Case sensitive)
/shop add <ShopName> <Price>Add the currently held item to the specified shop
/shop <ShopName>Open a specified shop (Typing in a wrong shop will show available shops)
/shop command <ShopName> <Price> <Command>Add a command to the shop with the specified price. Note: Use {PLAYER} where you want to put the player who purchases' name e.g. /kill {PLAYER}

Permissions:

All commands (Even the /shop) need a permission node before the user can execute it. You can find these permissions and their corresponding commands below

PermissionCommand
etokens.admin/token add
etokens.admin/token [remove/take]
etokens.admin/token set
etokens.give/token give
etokens.shop.create/shop create
etokens.shop.create/shop add
etokens.shop.create/shop command
etokens.shop.<ShopName>This will give the player permission to open the specified shop

Shop

The shop feature is simple to use that gives you the ability to sell items/commands to the players on your server!] Below is a table with commands that allow you to utilize the shop feature and it gives you a detailed description of what the commands does and what it allows the player to do.

CommandWhat It DoesWhat the player can do
/shop create <Name>Creates a shop with the specified name (Case sensitive)Allows the player to open this shop (If they have permission)
/shop add <ShopName> <Price>Add the currently held item to the specified shopAllows the player to buy the item that you're holding for the price that you've set
/shop <ShopName>Open a specified shop (Typing in a wrong shop will show available shops)Allows the player to see the specified shops' contents
/shop command <ShopName> <Price> <Command>Add a command to the shop with the specified price.Allows the player to execute the command when bought

Donations:

Donations are always welcome. If you feel like donating click the button below:

Donate


Comments

  • To post a comment, please or register a new account.
Posts Quoted:
Reply
Clear All Quotes

About This Project

Categories

Members

Recent Files

Bukkit