Tokens - [1.8.x - 1.13] [SQL] [API] 2.2.5

an economy with tokens

  1. Twan040
    Tested Minecraft Versions:
    • 1.8
    • 1.9
    • 1.10
    • 1.11
    • 1.12
    • 1.13
    Contributors:
    Twan L
    Tokens Banner-01.png

    What is this?

    this is a tokens economy plugin, and you can buy tokens with with the default economy



    ⚠️BUILD IN SHOP⚠️
    Version 2.2.4, the most bugs and error message's are fixed, i don't recommend this shop mudule in this stage
    List of Item's that won't work for the shop
    - Potions
    - enchanted books
    - arrows, but the default arrow work

    what wil be added
    - left click buy & right click sell
    - support for all the items

    Known Bugs\Glitches:
    - when the item cost is 0 and shift clicking the item it will spamm into the player inventory
    - if there is multiple items with the same item displayname it will use the first one in the GUI






    COMING UPDATE 2.3.0 (delayed)
    next update i will add a brand new future, so you can edit everything in the shop from in game, so you don't have to edit in the data.yml file


    Futures:
    - OfflinePlayer Support
    - mySQL Support
    - transfer from file-based to mySQL
    - Vault Support
    - Build in Shop


    Coming Futures:
    - convert you tokens to an item
    - API for developers
    - support multiple versions
    - OfflinePlayer Support
    - MySQL Support
    - set a limit for the minimum amount of tokens
    - remove the ID an let tokens stack together
    - add support for more languages
    - holographics
    - bank system with multiple users
    - placeholder support (BiBeo2006)
    - get tokens from killing a player (BiBeo2006)
    - add an option to sell item in the shop (Nawaf)


    (Outdated)
    How to add a menu:
    To add your first menu do /tokens shop add <menu> <slots> <title>

    It looks like this
    Code (YAML):
    shop:
      member
    :
        options
    :
          slot
    : 36
          title
    : '&cMember'
    with this command /tokens shop edit <menu>, you can put your item
    from in game into it

    than it looks like this
    Code (YAML):
    shop:
      member
    :
        options
    :
          slot
    : 36
          title
    : '&cMember'
        slots
    :
          '0'
    :
            name
    : Diamond
            slot
    : 0
            amount
    : 1
            Id
    : 264
            Data
    : 0
            cost
    : 0
          '1'
    :
            name
    : TNT
            slot
    : 1
            amount
    : 1
            Id
    : 46
            Data
    : 0
            cost
    : 0
          '2'
    :
            name
    : Grass Block
            slot
    : 2
            amount
    : 1
            Id
    : 2
            Data
    : 0
            cost
    : 0
     
    you can edit the cost of the item by cost: 10
    you can easily add custom permissions on each item, just add: permissions: custom.permission.node

    now you can add the following line on the item, command:

    if you want to close the inventory just set command: <close>
    if you want open a other menu, set command: <open> member
    if you want to give the player the item, set command: <item>
    if you want to execute a console command, set command: <command> kill {player}


    xxxx.png

    aliases: /t
    Vault needed for some commands
    Commands:

    - /tokens main command, show your information
    - /tokens add <amount> <playername> adding tokens
    - /tokens remove <amount> <playername> removing tokens
    - /tokens set <amount> <playername> set tokens
    - /tokens pay <amount> <playername> pay a player
    - /tokens balance see you tokens
    - /tokens balance <player> see tokens from a player
    - /tokens get <amount> exchange your tokens from your account to your inventory
    - /tokens bonus <amount> give all online players a amount of tokens and configure you own message with placeholder( {tokens} )
    - /tokens shop opens the shop
    - /tokens top show the to 10 players with the most tokens
    - /tokens reload reload the configuration files
    - /tokens help show the commands
    - /tokens convert sql convert from flat-file to sql (efficient for existing servers with this plugin)
    - /tokens shop edit <menu> edit the menu, you can put items into it
    - /tokens shop add <menu> <slots> <title> adding a menu
    - /tokens shop list show the list of all the menu's (shops)



    * Requires Vault

    - /tokens buy <amount> buy tokens with money
    - /tokens sell <amount> sell tokens for money



    Permissions:
    Default permissions:
    - tokens.tokens
    - tokens.balance
    - tokens.pay
    - tokens.get
    - tokens.buy
    - tokens.sell
    - tokens.shop
    - tokens.top
    - tokens.help



    Admin permissions:
    - tokens.admin.reload
    - tokens.admin.bonus
    - tokens.admin.add
    - tokens.admin.remove
    - tokens.admin.set
    - tokens.admin.convert
    - tokens.shop.add
    - tokens.shop.list
    - tokens.shop.edit


    Other Permissions:
    - tokens.sign.place - place the sign for your balance



    if you want to enable sql you have to change "database: file" to "database: sql"



    Known issues:

    - none



    Config File

    Code (YAML):
    #
    #                     <--- Tokens --->
    #                   Created by Twan Luttik
    ConfigVersion
    : 1.1
    update_message
    : true
    bonus_message
    : '&a&l» &r&freceived &a{tokens} {prefix} &ffrom your boss'
    prefix
    :
      prefix
    : '&cB&6e&ea&au&bt&9y&5 &cT&6o&ek&ae&bn'
      enable
    : false
    tokens
    :
      buy_price
    : 100
      sell_price
    : 100
    sign
    :
      line1
    : '&a   Tokens '
      line2
    : '&8&m-------------'
      line3
    : '  &fRight Click'
      line4
    : '&8&m-------------'
    mySQL
    :
      host
    : "localhost"
      port
    : 3306
      username
    : "root"
      password
    : ""
      database
    : "players"
      table
    : "player_data"
     


    API
    -
    Code (Text):

    // Accessing the API
    private TokensAPI api = new TokensAPI();


    // remove a amount of tokens from a player
    api.TokensAPI.playerRemoveTokens(player, 100);

    // add a amount of tokens from a player
    api.TokensAPI.playerAddTokens(player, 100);

    // set a amount of tokens
    api.TokensAPI.playerSetTokens(player, 100);

    // return an int
    api.TokensAPI.playerBalance(player);

    // return a true or false
    api.TokensAPI.hasAccount(player);

    // return the name of the token (in colors)
    api.TokensAPI.getPrefix();
     






    Images:

    Sign:
    upload_2018-3-30_8-36-42.png
    upload_2018-3-30_8-36-56.png

    Phyisical Note
    Screenshot_1.png


    Help Command
    shop.png



    Do you want to have your server below here if your server using this plugin, dm me your ip adres


    You can contact me on discord Twan#9968
    BiBeo2006 and JohnnySig like this.

Recent Updates

  1. v2.2.5 performance update + fix
  2. v2.2.4
  3. v2.2.3 quick error fix

Recent Reviews

  1. BlackGamerHD
    BlackGamerHD
    5/5,
    Version: 2.2.4
    Hello, your plugin is really good and performant. I would be very happy, if you can upload it on this website again, because I and many of my buddies use this, and that is really cool. <3 https://trailcraft.net/
    1. Twan040
      Author's Response
      Thank you, i will add post it on the website
  2. kassad
    kassad
    5/5,
    Version: 2.2.2
    I still can not understand the purpose of this plugin. Can someone tell me more? My server already has an economy. Why do I need tokens?
    1. Twan040
      Author's Response
      Maybe you want that players can buy a special items and they need the collect tokens to get the special item.
  3. GravityTurtalz
    GravityTurtalz
    5/5,
    Version: 2.2.0
    I like the concept, but I was wondering if there was anyway I could have it so my players got tokens for voting on my servers (this would be a cool way to have players vote for the server and then get tokens to use in the shop)
    1. Twan040
      Author's Response
      Thank you for the review, I will do you for more informations
  4. BiBeo2006
    BiBeo2006
    5/5,
    Version: 2.1.1
    It's amazing! Can you please add placeholder support in PlaceholderAPI plugin? And other way to obtain it like one kill give one token.
    1. Twan040
      Author's Response
      Thank you, i will gonna add your request
  5. Hips_
    Hips_
    5/5,
    Version: 1.6.1
    Great plugin! can be used as an alternate economy simple and easy to use.
    Could you also add it where players can't place the tokens?

    Thanks
    1. Twan040
      Author's Response
      Thanks, i will gonna add that
  6. izoody
    izoody
    5/5,
    Version: 1.6.1
    great plugin use on my faction server for a way for players to grind out to get ranks well done
    1. Twan040
      Author's Response
      Thank you for using Tokens. :)
  7. Holographic_
    Holographic_
    5/5,
    Version: 1.6.1
    Could you add the ability to change the name of the Tokens? Would be awesome, thanks!
    1. Twan040
      Author's Response
      i will add that in the coming update
  8. ogplayerfc
    ogplayerfc
    5/5,
    Version: 1.3.3
    Daily updates, Amazing plugin.
    But could you do updates once a while [massive updates at once]
    1. Twan040
      Author's Response
      Thank you, i gonna try bigger updates, and just little fix updates.
  9. razorblur
    razorblur
    5/5,
    Version: 0.0.3
    How can you pay for things if you can't transfer them to other players? :D
    Do you need permissions for these commands? ^^
    1. Twan040
      Author's Response
      there will be more updates today, adding permissions, adding more commands like admin commands and player default commands