vacuum_item: type: item debug: false material: hopper display name: <&[item]>Vacuum enchantments: - vanishing_curse:1 mechanisms: hides: all vacuum_entity: type: entity entity_type: armor_stand mechanisms: visible: false gravity: false marker: true is_small: true equipment: helmet: vacuum_item vacuum_world: type: world debug: false events: on player right clicks block with:vacuum_item: - determine passively cancelled - wait 1t - if : - stop - flag vacuum_queue: - spawn vacuum_entity save:spawned - define spawned - if !<[spawned].is_spawned||false>: - narrate "<&[error]>Vacuum broke" - stop - while && && : - wait 1t - adjust <[spawned]> move:]> - foreach <[spawned].location.find_entities[dropped_item|experience_orb|mob].within[7]> as:victim: - define rel <[spawned].location.sub[<[victim].location>]> - playeffect effect:town_aura at:<[spawned].location.points_between[<[victim].location>].distance[0.5].random[].round_up>].parse[above]> offset:0.1 - adjust <[victim]> velocity:<[rel].normalize.mul[]>]> - foreach <[spawned].location.find_entities[dropped_item|experience_orb|mob].within[2]> as:victim: - adjust <[spawned]> fake_pickup:<[victim]> - remove <[spawned]>