Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local whitelist = {
- 'minecraft:coal_ore',
- 'minecraft:iron_ore',
- 'minecraft:gold_ore',
- 'minecraft:redstone_ore',
- 'minecraft:lapis_ore',
- 'minecraft:diamond_ore',
- 'minecraft:emerald_ore',
- 'minecraft:nether_quartz_ore'
- }
- function isOre(name)
- for i = 1, #whitelist do
- if (name == whitelist[i]) then
- return true
- end
- end
- return false
- end
- while true do
- local _, data = turtle.inspect()
- local ore = isOre(data.name)
- print(ore and 'found ore' or 'not ore')
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement