UltraTrader
Remember the donate button works, I could use some fresh Mt. Dew (I also except BitCoin (address below)
Information
Links | Description |
---|---|
Development builds of this project can be acquired at the provided continuous integration server. These builds have not been approved by the BukkitDev staff. Use them at your own risk. | |
Jenkins | Development Downloads on CI provided by CloudBees |
GitHub | Source Code is hosted by GitHub.com by DemgelOpenSource group |
Website | WebSite is hosted by Github using maven-site |
Donate BitCoin | 17U5koSrxqYphGTSN4nZsd1sDr7Ti96XW4 |
Donating FUN | Some fun options for donating if you don't have money but want to help |
Citizens Wiki | My Wiki entry on Citizens 2 website |
Most Documentation will be on the Website
at http://ultratrader.thedemgel.com
Installation |
Commands | Permissions | Create A Trader | Localization | Configuration | Setting Shop Limits
UltraTrader and Citizens
UltraTrader doesn't require Citizens to run. But it does come ready to integrate out of the box, and most extensions do currently require the use of citizens. UltraTrader will work with Citizens to create NPC traders, but if you don't want to use Citizens, you can easily make blocks/signs into shops.
Buying and Selling
Some notes on buying and selling:
- Owners will always receive items from their shop for free (FREE)
- Owners can never sell items to their own shop. Items placed into a Traders buy screen will just be returned.
External Plugins
As a way to extend Ultratraders without bloating the already sizable amount of code required any farther, I have started to create external plugins that extend UltraTrader. Some of these can be found on the Jenkins Site, but we aware that these are not bukkit tested yet, and may be full of bugs.
Working Extensions (not flawlessly yet)
- UltraRental - Create Rental NPCs
- UltraDenizen - Allows UltraTrader to work with Denizens
- UltraWorldGuard
- Adds some requirements that can be setup by:
- using required traits in limits.yml
- adding required trait permissions "trader.limit.required.default.worldguardowner"
- currently only adds "worldguardowner" (trader must be standing a region the player owns) and "worldguardmember" (trader must be standing in a region a player is a member of)
- Currently should still work, but updates are suspended till I the new repo.
- Adds some requirements that can be setup by:
- UltraFrames
- Currently will show randomly changing items that your shop sells
- add ultraframe trait to NPC
- right click with stick to select
- place item frames and watch the magic.
- Currently will show randomly changing items that your shop sells
Compatibility Extensions
These extensions are there to extend the compatibility of UltraTraders to more specific modes beyond the normal use of UltraTraders. Some planned extensions will likely be a bridge Extension for handling Bukkit->Forge communications, as well as NBT related code that I don't want to place directly into UltraTrader.
Metrics
This plugin utilizes Hidendra's plugin metrics system, which means that the following information is collected and sent to mcstats.org:
- A unique identifier
- The server's version of Java
- Whether the server is in offline or online mode
- The plugin's version
- The server's version
- The OS version/name and architecture
- The core count for the CPU
- The number of players online
- The Metrics version
If you wish to disable this feature (/me cries), you can do so by opt-ing out, which you can do in the config file under /plugins/PluginMetrics/
Some Videos
If anyone wants to create a video demonstrating the use of UltraTrader, please PM me, thanks. I will be creating more as time goes on, but removed the out dated material for now
TODO
- command to allow Ops to not always get items for free from all stores
- Currently I have removed OPs completely from the free sell list (OPs no longer get free items, or shouldn't)
- Players can use the "/traderplayer toggleop" command to toggle paying at their own shop (for test purposes)
- Item to allow click to see shop information
- The command is there (/trader info) but it does nothing yet due to forced update
- adding aliases: "/trader" -> "/ut" - "/traderplayer" -> "/utp" - "/traderadmin" -> "/uta"
- removing logging from ultratrader and using a extension plugin, to hopefully invite some members to add pull requests to add logging features.
Thanks
- dayron1313 - Github issues
- Chriszh - for being persistant ;)
@siemaeniu500
The jenkins builds should have a fix for this... that is part of my item shop code that was checking for displayname (I wrongly assumed it wouldn't be null if there was ItemMeta data)
This happened, when player use a super breaker ability in plugin mcMMO
@siemaeniu500
"that" is required for the plugin to work, and what do you mean by auto-updating locale? per client?
@duckfan1994
well, that is a good question, and UltraTraders itself does not handle any currency, it just passes information off to economy plugins. So if you have an economy plugin that uses items for currency, it may well be possible if done through Vault (for easy) or even by implementing the Wallet object in your own plugin and offering that as a wallet instead of bank/player/admin/etc (as in there is an API to handle different types of wallets), but it not only poorly documented right now, it isn't documented right now.
So the short answer to you question is YES it is possible, but it will not be done by me.
The other things that this brings up is compatiblity with plugins like Towny, or Factions, etc... it is very possible to make UltraTrader compatable with any of these plugins.
Is it possible or will it be possible to make the price of an item in a shop to another item? Lets say I wanted to make 1 diamond cost 8 iron ingots. So when the player goes to buy the diamond it would take the 8 iron ingots from his inventory as the cost. Or is it currency only as of right now?
@tenowg
1. It is possbile to add auto-updating locale? 2. How i can remove that/ what is that?
At the request of @siemaeniu500 I have added the following:
added to language file and to shop output a message indicating if you bought or sold an item, the amount and how much the transaction was, it is short and simple, so it can be seen.
Also if a player trys to place an item in the sell window it will now direct that play to goto the buy screen if they would like to sell the item.
These options have been added to the Jenkins site and will be added to the Bukkit site as soon as I add a few more tangible items.
@siemaeniu500
yea, that was on the drawing board, I could probably add that now while I add this message,
I just reliazed you asked for description... one of the many things that people complained about Cititraders was that there was to much text while in the inventory screens, so i will be using the item name/displayname in the log message, which it really is.
@tenowg
Can u add diffrent messages when people bur or sell something, because now it's one message, just like:
@siemaeniu500
I could probably add the option that it will tell you that you are on the wrong screen, but I am not going to combine the screens. From my own testing, it needs to be seperate screens to be safer against item duplication, but I already mentioned this to you.
Sorry for my english 1. Can u add option:
When player try to sell item in wrong screen - will show message like: Switch to buy screen if u want to sell that.
2. Or u can just create one screen, when player can click to buy items, and moving to trader inventory, if the want to sell item. This buy screen is useless, it would be simple with one.
Not going to push this single update to Bukkit just yet... But if you goto the Jenkins page, and download v.11-BETA, you will notice that when you click on a new NPC that has the ultratrader trait added to him, you can now assign a pre-existing shop to him.
I would love it if people could test this more than I can, because this does allow a shop to be hosted (assigned) to multiple NPCs at the same time. Great for admin shops, or just players looking to reach out.
@CommodoreAlpha
well, I already thought of this...
http://demgelopensource.github.io/UltraTrader/
@tenowg
Ah, so basically each shop is its own "instance", stored in a sort of "database". That's actually a really good explanation; you could (in the future) make a "How this works" section and put that explanation in it. The way you explained it is actually really different (and more ingenious) from how I interpreted it.
@CommodoreAlpha
Although not implemented yet: I am currently working on just making the shops work and the easist way to do that was with NPCs, so that part is the only functioning part.
Let me explain deeper tho, so you may understand.
A shop is its own entity, it doesn't care if it is attached to an item, NPC, block, door, sheep, cat. None of these control the shop, for instance, the NPC trait only holds the id of the shop that he uses, thats it, no control is issued by Citizens 2.
So with that said, if you have a shop with id 5 (randomly generated from a progressive random number generator), then you can assign that shop (id 5) to the NPC, but nothing will stop you from assigning that shop to an item, or a block, or anything else that can persist data in some way or shape. (items will use Lore, blocks will use metadata or location map, other things will likely use Citizens (like NPC animals)). I could even go as far as a game command to open a shop (/openshop 5) which would magically open shop with id 5 inventory whereever you are.
To narrow it down, items will be shop that you can hold in your hand... mobile shops. Many items can be linked to one shop, so you COULD for instance even sell the Shop items from the shop you have linked to the NPC.
Hope that all made sense.
@tomori_peti
I haven't added this feature yet, but the stub is there for it. Basicly what will happen is one of two things (if not both, I haven't decided).
1) You will make a Master Trader (this will be the same for both methods, although alittle different implementation)
then: a) export the buysell prices to a different .yml, and then different traders would be able to use those list prices for the different shops. b) Create Slave traders (more computer terminalogy instead of Slave trade, lol) which would use the Masters buy/sell list.
Or you comment might be interpretted differently... The Lore of an item doesn't stay with the item when you buy it, the lore on the items in the shops are just dummy items with lore. The actual item is given without any of the shop lore on it.
I can see how entities and signs can be shops - you right click them, and a "shop" GUI opens up. For blocks, that might be a bit more confusing, but with a bit more imagination, you can make a block look like a shop.
But what I'm really confused about, is how an item can be a shop. Do they function as "mobile" shops that you can hold in the palm of your hand? (Basically, you right click with the "item" and it opens up the shop associated with it?) If so, that would be extremely, and utterly cool - carrying an entire shop in your hands.
As for Citizens support, will it be like CitiTraders, where you have to apply the trait(s) first, or are you implementing another method to turn an NPC into a "UltraTrader"? From my own opinion, I'd prefer applying a trait - it just "feels" more "stable" for some reason.
Anyhow, thanks for putting in your time to continue this great plugin! I was afraid I'd have to drop CitiTraders, which had a great concept behind it. :D
Can you add something which can read the sell price of an item from it's lore after a default text like: Price: 50$ or Sell: 50$ and these item's could be sold at all of the traders. I have never seen feature like this in any other plugins. What do you think?
@siemaeniu500
Issue has been fixed, and I will push as soon as I have the inventory setup
@siemaeniu500
Unlimited inventories will be set much the same way as admin wallets, I haven't made that menu yet.
to recreate this error, I had to try to enter and leave the admin conversation several times, as well as try to re-enter it while still in conversation.. is this correct?
@tenowg
How i can set unlimited amount of items in stock?
And errors in console: http://paste.ubuntu.com/6209511/