Essentials icon indicating copy to clipboard operation
Essentials copied to clipboard

Add an option for placing items in specific slots (offhand, armor, etc)

Open thinstripe opened this issue 1 year ago • 5 comments

Feature description

Currently, when you put an item in your offhand slot, create a kit in-game using /kitcreate and then run /kit <kit> to recieve the kit, the item does not appear in your offhand slot, but in the first available slot instead. Im suggesting to add a toggleable option that, when enabled, would automatically put the item in the offhand slot (as long as the item was in offhand slot when creating the kit of course).

How the feature is useful

The feature could be quite useful for kits containing, for example, shields. As most players would probably want to put them in their offhand slot, I think they would appreciate receiving the kit in this state and not having to move their shield there every time they get the kit.

thinstripe avatar Oct 08 '23 14:10 thinstripe

Have you tried this with the config option use-nbt-serialization-in-createkit set to true?

baailey avatar Oct 08 '23 15:10 baailey

Yes, is that supposed to have any effect on this? Because for me, it does not.

thinstripe avatar Oct 08 '23 16:10 thinstripe

Not sure, I assumed it would've but seems not

baailey avatar Oct 08 '23 22:10 baailey

Rather than auto equip certain items into the offhand slot it would make more sense to allow specific items into separate slots with /kit. This would solve the issue of equipping correctly as well without making assumptions about what items to auto equip (for example, auto equipping shields when someone else may want to auto equip a torch instead).

pop4959 avatar Dec 10 '23 02:12 pop4959

adding onto this, a potential idea of formatting the kits.yml to add this could be as such:

kits:
  a:
    delay: 1
    items:
    - diamond_chestplate 1
    equipment:
      helmet: diamond_helmet 1 name:helmet
      chestplate: diamond_chestplate 1 name:chestplate
      leggings: diamond_leggings 1 name:leggings
      boots: diamond_boots 1 name:boots
      offhand: shield name:shield

Evidentsinger14 avatar Dec 10 '23 02:12 Evidentsinger14