Trading
Trading
A user-friendly, fun, fair, and incredible way to conduct trades. A simple Inventory GUI that helps players visualize what items they want to trade without fear of being cheated. Easily see what the other player wants to trade and agree to a simultaneous trade. Second thoughts at the last seconds? No problem, simply cancel the trade in the "Second Thoughts" countdown. Both players involved in the trade will receive their items at the exact same time with no problems. A great asset to have for role-playing Minecraft Servers!
Description
Get within 10 blocks of a player and request a trade. If the player accepts, an Inventory GUI will open. Place the items you want to trade in your section and have the other player place theirs. Once ready, click the green wool to indicate you are ready. Once the both players have done so, a 5 second countdown will begin where no players can change the traded items. If you have second thoughts, cancel the trade by clicking the red wool. If you both like the selection of items, leave the inventory alone until the countdown is over. Both players will receive their traded items at the exact same time. Trading has never been more fair, safe, or easy.
Commands
- /Trade (PlayerName) - Requests a trade with the designated player
- /Trade Accept - Accepts the current trade request
- /Trade Decline - Declines the current trade request
- /Trade Reload - Reloads the trading config.yml file
Permissions
* trading.trade
* trading.admin - for /trade reload
Installation
To install the plugin onto your server...
Stop your server
Drag and drop the plugin into your plugins folder
Start your server
Enjoy!
Configuration
CountdownLength: 5 Distance: 10.0 TradeCurrency: true TradeCurrencyAmount: 100.0 TradeInCreative: false ShiftRightClick: true Messages: error-not-involved: '&bTrading> &7You are currently not involved in any trades' error-trade-already-accepted: '&bTrading> &7The trade has already been accepted' error-accepter-different-trade: '&bTrading> &7The player &b%accepter% &7is currently involved in a different trade' error-requester-different-trade: '&bTrading> &7You are currently involved in a different trade' error-distance: '&bTrading> &7You must be within 10 blocks of a player to trade' error-world: '&bTrading> &7You must be in the same world as a player to trade' error-self: '&bTrading> &7You cannot trade with yourself' error-not-online: '&bTrading> &7The player &b%accepter% &7is not online' error-creative: '&bTrading> &7You cannot trade while in &bCreative &7mode' error-incorrect-usage: '&bTrading> &7Incorrect Usage, Correct Usage: &b/Trade (PlayerName)&7, &b/Trade Accept&7, or &b/Trade Decline' trade-request-sent: '&bTrading> &7Trade request sent to the player &b%accepter%' trade-request-received: '&bTrading> &7The player &b%requester% &7has just requested a trade with you. You have 15 seconds to accept' trade-accepted: '&bTrading> &7Trade has been accepted' trade-successful: '&bTrading> &7Trade was successful' trade-cancelled: '&bTrading> &7Trade has been cancelled' trade-cancelled-creative-reason: '&bTrading> &7This was because a player was in creative mode' traded-currency: '&bTrading> &7You have traded &b%currencyamount% &7as a result of the trade' received-currency: '&bTrading> &7You have received &b%currencyamount% &7as a result of the trade' config-reloaded: '&bTrading> &7The &bconfig.yml &7file has been reloaded' Item-Names: inventory: '|You| |Other|' divider: ' ' decline-trade: '&cClick to Cancel Trade' accept-trade: '&aClick to Ready Trade' not-ready: '&7Not Ready' ready: '&aReady' add-currency: '&aAdd &f%currencyamount%' remove-currency: '&cRemove &f%currencyamount%' total-currency: '&aCurrent Money-to-be-Traded: &f%currencyamount%' Item-Lores: decline-trade: - '&7Click this block at any' - '&7time during the trade to cancel' accept-trade: - '&7Once both traders have clicked' - '&7this block, the countdown will' - '&7begin' add-currency: - '&7Adds your money to the trade' remove-currency: - '&7Removes your money from the trade'
CountdownLength - Set this number to the time in seconds to wait before completing a trade.
Distance - Max distance of a trade (Set to -1 for no distance. Trades will still not work across different worlds).
TradeCurrency - Set it to either 'true' or 'false'. If enabled (set to 'true'), the plugin will actively search for an economy plugin using Vault. If the economy plugin is found, all of the economy features of the plugin will be enabled if the TradeCurrencyAmount is greater than 0.
TradeCurrencyAmount - The amount of money increments to add or subtract by on trades. When a player adds money to the trade, the money added is by this amount.
TradeInCreative - When set to false, trading while in Creative mode is disabled.
ShiftRightClick - When set to true, trades can be initiated and accepted by holding shift and right clicking a player.
Messages - Replace the messages with your own.
Item-Names - Replace the name with your own custom names (inventory must be under 32 characters).
Item-Lores - Replace the messages with your own custom lores. Add more and more lines to it to add more and more messages to the lore.
Video Tutorial
Future Plans
- Add a configuration file for custom "Second Thoughts" countdowns DONE!
- Cancel trade on damage (Suggested by daniel0964) DONE!
- Language options configurable in a config (Suggested by cPathz) DONE!
- Economy support (Suggested by Everyone) DONE!
- Configurable distance option (Suggested by Everyone) DONE!
- Configurable world ignore option (Suggested by BiGUNMAN) DONE!
- Ignored PvP Compatibility (Suggested by Chris_GSPvP) DONE!
- VIP trading with more slots (Suggested by daniel0964)
- Log player trades (Suggested by daniel0964)
- Switch from Ready to Not Ready if items are changed (Suggested by Jleeevinnn)
- Prevent players from trading with vanished players (Suggested by Stealth)
Donations
It was brought to my attention that the demand for this plugin is pretty high. I honestly am honored to be able to log onto a server and pretty much find this plugin everywhere. The reason I am adding a donation button is for those server owners who feel a need to donate as encouragement. Honestly, a simple thanks suffices most of the time. However, I do have to balance between school, work, gaming, and plugin making. Donations tend to tip the scale. Therefore, there's a really cool button on the top right of the page. Click it!
Message From The Developer
Hi there! This is david_rosales and I bring you another plugin. This one is a role-playing must-have for all servers. It adds a fun little trading system. Hope you all enjoy it as much as I enjoyed making it. If you have any problems with the plugin, comment below and I will try to fix them immediately. Any suggestions? Suggest them! My future plans is pretty much empty since I don't see how I can improve this plugin with new features. Also, I'm thinking of adding a "Servers With This Plugin" section so... If you are going to use this plugin on your server, feel free to comment with the name and server IP address and I'll add it to the list. Thanks for reading this.. :D it means a lot. Have fun with the plugin!
Does this support custom items with special NBT data etc?
== Update Request ==
Customable Trade Time
15 Second is not Enough for players some player are slow in typing also some noob
by:Pinoy LifeCraft
Not sure if your still working on this or not but could you make it so there isnt the limit on how close you have to be? Or atleast add a config option to disable it?
This is exactly what I was looking for! Thanks for making this simple plugin! Although I hope you address the concerns @raphaelsimon and @ropng have noted.
One of the most stable trade plugin so far. It'd be great if you can add economy into it!
if others close the trade , when you hold the item ,but not put in the trade area,item will drop on the ground , can you fix this?
Like some people have already posted, it would be nice to add a trade for money feature.
Hi David! My users can take the items from the "trade" gui :( for example, the wool items, is there any feature to fix this?
It would be nice to have a way to trade items for money
Add economy support. Some people would like to trade 4 apples for 50.00 :) Ability to trade across distances (in same world)
Is there any economy support for this plugin? (i.e. a way to trade virtual currency from iConomy/EE/etc. with items)
@cPathz
I don't mind. Thanks. Also, I'll add the customize language options as config file where you can set the messages without having to edit the classes. Thanks for the suggestion (adding it to the list). Also thanks for the error code. Will fix it in the next update.
@tachohentai
And I think i know the problem for world trading. It should be a really simple fix. Will fix it in the next update.
@tachohentai
I attached the error displayed on the console.
Console Error Code...
The error is caused when I use the plugin with another user who is in a different world.
Not seem to affect the operation of the server. Only the error console.
We use:
-Spigot 1.7.2 -R0.3 -122
-Multiworld Plugin : Multiverse-Core-2.5
-Trading v1.0 for CB 1.7.9 -R0.1
@davidrosales
Error - Trade in different worlds
Great plugin. Thanks a Lot. We had searched for a "Trade" plugin that were simple and easy.
Well. My language is Spanish. I modify the text in the class files to translate into my language (I hope you will not mind).
https://db.tt/81wvyTcK
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Bug?
If your inventory is full and you make the Trade. You lose the items sent by another user.
But the other user receive the items that you sent him.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Request:
External file to change the language.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Several ideas:
Config option to make players in a trade invincible. Config option to right-click a target player to initiate trade. Config option to set the amount of times to right-click. Config option to initiate a PVP check. (Similar to Essentials tp delay)
Let's just say Iike config options. :P
For enhanced security and happy customers you should add a check for when one player has accepted, the other has not, and then the player that has not accepted takes out their items, the player that accepted still has accepted, allowing the player that has not accepted to click accept, with his items removed.
An easy fix is to unready the player that has readied if a player changes/removes items from the offer.
@NumbrainNetwork
I noticed many of those problems while creating the plugin and have fixed all the ones i have tested for. If you notice or find any other dupe bugs while using it, notify me and i will fix them immediately.
I've seen so many plugins like this one. Almost everyone of the even the best trading plugins have dupe bugs. I hope you do a great job with it though! I'll come back to see progress. ;) bookmarked
@daniel0964
Thanks for the suggestions! I like the vip trading and trade close on damage! :D I will add those to my future plans