EssentialsX

EssentialsX

2M Downloads

The /sell hand command sells all items of the item type in hand

AMDBartek opened this issue · 5 comments

commented

Details

Output of /ess version

Server version: 1.12.2-R0.1-SNAPSHOT git-Paper-1618 (MC: 1.12.2)
EssentialsX version: 2.17.1.53 (Happens in newest release as well)
LuckPerms version: 5.0.39
PlaceholderAPI version: 2.10.4
Vault version: 1.7.2-b107
EssentialsXProtect version: 2.17.1.53
EssentialsXChat version: 2.17.1.53
EssentialsXSpawn version: 2.17.1.53

Description
For example, you have 1 stack of iron ingots in your hand and you have another stack in your inventory/hotbar then you select one stack of iron ingots in your hotbar and you execute /sell hand command it sells both stacks of iron ingots

Steps to reproduce

  1. Have one type of item in your inventory and one in your hand
  2. Execute /sell hand
  3. It sells the items in your hand AND the ones in your inventory/hotbar

Expected behavior
It only sells the items you have in your hand and keeps the ones in your inventory/hotbar

Screenshots

commented

Seems to be working as intended. The /sell hand command sells all of the item in your hand. You probably meant to be using /sell <item> [amount].

commented

@pop4959 What I mean by this is, for example, I have 2 stacks of diamond, one stack is in my hand and the other stack is in a slot other than my hand and I execute ”/sell hand” it sells the stack of diamonds that is in my hand and the stack of diamonds that is in the other slot that is not my hand. (If this is how it is meant to work, I am sorry for any inconveniences caused by this)

commented

I would like this to be fixed as soon as possible because this has already happened to over 2 of my players and they lost some items

commented

Fully understood; this is how it is meant to work.

The /sell hand command only means that you want to sell the item in your hand. For all intents and purposes, it is simply a shortcut to /sell <item>, where the item is in your hand. You still need to specify the amount if you don't want to sell everything. The following are equivalent:

  • /sell hand with diamond blocks in your hand would sell all of your diamond blocks.
  • /sell diamond_block sells all of your diamond blocks.

Likewise:

  • /sell hand 64 with diamond blocks in your hand would sell exactly 64 diamond blocks.
  • /sell diamond_block 64 would also sell 64 diamond blocks.
commented

Ok, thanks for the explanation