hollow-cube / minestom-ce

1.20.4 Lightweight Minecraft server
https://minestom.net
Apache License 2.0
108 stars 36 forks source link

Campfire doesn't have own InventoryType #109

Closed bivashy closed 8 months ago

bivashy commented 8 months ago

Is your feature request related to a problem? Please describe. When we should implement Campfire inventory, we cannot rely on the InventoryType that doesn't have such inventory type.

Describe the solution you'd like Adding CAMPFIRE into InventoryType interface. Current implementation is: https://github.com/hollow-cube/minestom-ce/blob/78cb62fa72906907aa29d6523095967ccc0bf4ae/src/main/java/net/minestom/server/inventory/InventoryType.java#L6-L32

Describe alternatives you've considered We could use LOOM enum, but then this will be misleading to the other project maintainers, also this may lead to the confusion.

Additional context _

MelonHell commented 8 months ago

InventoryType is responsible for the inventory type in the protocol. The protocol does not contain the CAMPFIRE inventory type https://wiki.vg/Inventory#Windows

MelonHell commented 8 months ago

If you need to make an inventory that doesn't need to be displayed to the player, then you don't need to use InventoryType at all

bivashy commented 8 months ago

Thank you for help! Sorry for taking your time