turtle.detectUp
From ComputerCraft Wiki
| Detects if there is a block above the turtle. | |
| Syntax | turtle.detectUp() |
| Returns | boolean is there a block above the turtle? |
| Part of | ComputerCraft |
| API | turtle |
Examples
| The turtle checks if there is a block above it, and if there is, it digs it. | |
| Code |
if turtle.detectUp() then turtle.digUp() end |