Tradeshop / TradeShop

Unique, new, powerful Minecraft TradeShop plugin!
https://tradeshop.github.io
Apache License 2.0
25 stars 11 forks source link

[BUG] BiTrade messages are confusing #116

Closed Svish closed 2 years ago

Svish commented 2 years ago

Expected behavior

Tried to set-up some [BiTrade], and find the error messages very confusing.

[BiTrade]
64 PINK_WOOL
4 DIAMOND

Also, when the shop is out of stock with something, it would be good if it said what it was out of stock of. Currently it shows this message, regardless of which trade you're trying to do:
"This TradeShop is currently missing items to complete the trade!"

It's also a bit confusing that the shop itself says <Out Of Stock> when there's no more product, even though the cost-item is still in stock so you can do the reverse trade.

Observed/Actual behavior

image

Steps/models to reproduce

Create a [BiTrade] and trade with it, both directions, with and without needed items in chest and/or inventory.

Plugin list

20.11 18:20:22 [Server] INFO Plugins (15): AntiCreeperGrief, Beenfo, CoreProtect, DoorsReloaded, dynmap, FarmProtection, FastAsyncWorldEdit (WorldEdit), floodgate, Geyser-Spigot, OverleveledEnchanter, RHLeafDecay, spark, TradeShop, TreeGravity, WorldEditSelectionVisualizer

TradeShop version and Minecraft version (CraftBukkit/Spigot/Paper/...)

20.11 18:20:12 [Server] INFO Checking version, please wait...
20.11 18:20:12 [Server] INFO This server is running Paper version git-Paper-342 (MC: 1.17.1) (Implementing API version 1.17.1-R0.1-SNAPSHOT) (Git: 40ee634)
20.11 18:20:12 [Server] INFO You are 44 version(s) behind
20.11 18:20:12 [Server] INFO Download the new version at: https://papermc.io/downloads
20.11 18:20:12 [Server] INFO Previous version: git-Paper-"3069eae" (MC: 1.17.1)
20.11 18:20:16 [Server] INFO TradeShop 2.3.1-STABLE by Lori00 & KillerOfPie

Agreements

Other

No response

KillerOfPie commented 2 years ago

Great catches. The code for BiTrades get really confusing since the cost becomes the product and vice versa. Going to number the issues then respond to each.

  1. No Stock message does not change while left clicking BiTrade shops
  2. Missing items message is not specific enough or not sending in the correct place.
  3. BiTrade shops shop oos on sign when they can still trade cost.
KillerOfPie commented 2 years ago

Now for responses to each.

  1. This is definitely a bug caused by the check happening without knowing what trade was requested
  2. When exactly does this message appear, I believe this should show up when the shop has not been assigned a cost/product which would be clearly visible on the sign.
  3. I thought i had fixed this for 2.4 but I'll look again.
Svish commented 2 years ago
  1. It shows up when both cost and product has been assigned, but one of the items are missing.
KillerOfPie commented 2 years ago
  1. It shows up when both cost and product has been assigned, but one of the items are missing.

Okay, but how do you interact with the sign for it to appear, because left/right click should show the messages from 1

KillerOfPie commented 2 years ago
  1. It shows up when both cost and product has been assigned, but one of the items are missing.

Okay, but how do you interact with the sign for it to appear, because left/right click should show the messages from 1

Never mind I found it.

Svish commented 2 years ago

If I remove all the wool (but still have diamonds in the chest, and both diamonds and wool in my inventory), then I get the message "This TradeShop is currently missing items to complete the trade!" regardless of whether I right- or left-click.

KillerOfPie commented 2 years ago

All 3 fixed in e030cec

Dev update should be out in a couple minutes