Minecraft Inventory Scanner

Minecraft Inventory Scanner - Warehouse with Concrete Floors

I want to do a sort of "inventory scanner" that scans EVERY slots of the inventory of a player. I don't want to write 32 commands in 32 commands blocks, so is there a way to make it short?

For more precision, what I need to scan is the TNT blocks, lava buckets, flint & steel, detected either if renamed or not renamed.



Best Answer

You can do /testfor @p {Inventory:[{id:"tnt"},{id:"lava_bucket"},{id:"flint_and_steel"}]}




Pictures about "Minecraft Inventory Scanner"

Minecraft Inventory Scanner - Photo Of Gynecologist Sitting Near Medical Equipment
Minecraft Inventory Scanner - Men Working in a Warehouse
Minecraft Inventory Scanner - Stack of Books in Shelf



How do you use the inventory scanner in Minecraft?

Usage. For an Inventory Scanner to function, two of them are required. Place an Inventory Scanner down then place another Inventory Scanner 2 blocks away, leaving a 1 block space between them, facing the first Inventory Scanner. A laser will form between them when set up correctly.



Minecraft Mod Spotlight: Securitycraft




Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

Images: Tiger Lily, MART PRODUCTION, Tiger Lily, Pixabay