client icon indicating copy to clipboard operation
client copied to clipboard

Generic item name grouping for search and xray

Open meganukebmp opened this issue 5 years ago • 4 comments

Add generic names for various items that have different names but are a subset of the same thing like wools, shulkers, logs and so on.

Right now for example to add all shulker boxes one has to do

;xray +white_shulker_box
;xray +black_shulker_box
;xray +red_shulker_box
;xray +green_shulker_box
;xray +blue_shulker_box
etc etc

This is quite annoying for such items, there should be a generic name to group all of them together so that they can be added and removed together

;xray +log
;xray +wool
;xray +carpet
etc etc
  • sign
  • banner

meganukebmp avatar Jun 22 '20 11:06 meganukebmp

I'm not sure how this will work, seeing as currently the command autocomplete just takes Minecraft's list of blocks

5HT2 avatar Dec 30 '20 05:12 5HT2

I'm not sure how this will work, seeing as currently the command autocomplete just takes Minecraft's list of blocks

Wildcards could be a decent solution. *_shulker_box la?? -> lava/lamp etc

meganukebmp avatar Jan 02 '21 07:01 meganukebmp

Returning a list from a wildcard isn't very intuitive. I'm thinking we could have our own Block list or add to the existing one and return a list of actual Blocks

5HT2 avatar Jan 02 '21 07:01 5HT2

I have no idea how it works right now. Havent touched net.minecraft.* in ages. There arent that many blocks, maybe dynamically generating a list of every single block identifier with reference on initialization and just keeping that in memory for whenever it's needed. Doubt it'll use more than 2-3kb of memory. Would make wildcards or even regex far more rudimentary.

meganukebmp avatar Jan 02 '21 07:01 meganukebmp