TransWikia.com

Execute one /data command for block entities of some kind within a range?

Arqade Asked on January 5, 2021

I know I can have one /data command target multiple entities of one kind in a given range like this:

/execute as @e[type=some_entity,x=1,y=2,z=3,dx=4,dy=5,dz=6] run data modify @s Example

It’s a command that I can put into ONE command block no matter how many entities are targeted.

Is there a way to achieve a similar result for block entities? Examples include furnaces, hoppers, dispensers/droppers etc. It may not necessarily be one command, but the number of command blocks required should not depend on number of blocks targeted (assume the range doesn’t go over limits like 32768).

Need a solution for Java 1.16.x.

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP