Turtle

Turtle
File:Turtle.png
Name Turtle
Type Turtles
Stackable Yes (64)
Data Value 216
Mod Included ComputerCraft

Turtles are one block large robots that can be programmed to mine, farm, or attack automatically or communicate over rednet. They are part of the ComputerCraft mod. Turtles can have only 1 tool and 1 peripheral (crafting bench or modem)

Recipe


GUI

File:Turtle gui.png
The GUI that opens, when right-clicking a turtle.

Right-click a turtle to open its GUI.

Here you can input commands and write programs just like at a console.

Block Placement

You can make it place blocks, here is a template to placing blocks API:

turtle.placeDown(1)
turtle.placeUp(1)
turtle.forward(50)
turtle.Placeblock(1)
turtle.back(50)

Disk Drive Connection

To connect a turtle to a Disk Drive, place it on a free side next to the turtle. Disk drives won't connect if placed next to the modem of a wireless turtle. A turtle can only have maximum one Disk Drive connected to it.

Upgrades

A Turtle can be upgraded to be able to Mine/Dig/Cut Wood/Attack/Farm and have Wireless Connectivity/Able to craft items (assuming it have resource to craft something).

Wireless Turtle


Note: You can also use a <tool> Turtle in the recipe for a Wireless <Function> Turtle. With the Wireless Turtle, it can now send/receive messages through the rednet api.

Crafty Turtle


Note: You can also use a <tool> Turtle in the recipe for a Crafty <Function> Turtle. With Crafty Turtle now it can craft items if it has resource needed

Mining Turtle


Note: You can also use a Wireless Modem in the recipe for a Wireless Mining Turtle, and Crafting Bench for Crafty Mining Turtle.

Felling Turtle


Note: You can also use a Wireless Modem in the recipe for a Wireless Felling Turtle, and Crafting Bench for Crafty Felling Turtle.

Digging Turtle


Note: You can also use a Wireless Modem in the recipe for a Wireless Digging Turtle, and Crafting Bench for Crafty Digging Turtle.

Farming Turtle


Note: You can also use a Wireless Modem in the recipe for a Wireless Farming Turtle, and Crafting Bench for Crafty Farming Turtle.

Melee Turtle


Note: You can also use a Wireless Modem in the recipe for a Wireless Melee Turtle, and Crafting Bench for Crafty Melee Turtle.

Issues With Turtles

  • When the chunk they're in is unloaded, they will stop mid-program. This will often leave them hovering in a pit if it is stopped during the "excavate #" command it may also be left at the bottom of a pit.
  • Poorly-written programs can send a turtle running off, never to be seen again.
  • A turtle can easily mine itself under a pool of lava, making it quite the pain to retrieve (or find)
  • Turtles may disappear if left awaiting a command long enough.
  • Turtles do not have a console past coordinates 20,000 y 20,000. Unknown what the max range is.

Commands

To use following lua commands you can

  • run the program "lua"
  • write it in its own file using "edit <filename>" and run the program with "<filename>" (you can choose the <filename>)

Return

Method name

Description

Note

bool "success"

turtle.forward()

Let the Turtle move forward

    •  

bool "success"

turtle.back()

Let the Turtle move back

    •  

bool "success"

turtle.up()

Let the Turtle move up

    •  

bool "success"

turtle.down()

Let the Turtle move down

    •  

bool "true"

turtle.turnLeft()

The Turtle turns left

    •  

bool "true"

turtle.turnRight()

The Turtle turns right

    •  

bool "slot > 9"

turtle.select( slotNum )

The Turtle selects the given Slot (1 is top left, 16 (9 in 1.33 and earlier) is bottom right)

    •  

bool "success"

turtle.dig()

Breaks the Block in front

 

bool "success"

turtle.digUp()

Breaks the Block above

 

bool "success"

turtle.digDown()

Breaks the Block below

 

nil

turtle.placeUp()

Places a Block of the first available slot above

    •  

nil

turtle.placeDown()

Places a Block of the first available slot below

    •  

bool "result"

turtle.detect()

Detects if there is a Block in front

    •  

bool "result"

turtle.detectUp()

Detects if there is a Block above

    •  

bool "result"

turtle.detectDown()

Detects if there is a Block below

    •  

bool "result"

turtle.compare()

Detects if the block in front is the same as the one in the currently selected slot

    •  

bool "result"

turtle.compareUp()

Detects if the block above is the same as the one in the currently selected slot

    •  

bool "result"

turtle.compareDown()

Detects if the block below is the same as the one in the currently selected slot

    •  

bool "success"

turtle.drop( [count] )

Drops all items in the selected slot, or if [count] is specified, drops that many items.

    •  

bool "success"

turtle.dropDown( [count] )

Drops all items in the selected slot, or if [count] is specified, drops that many items.

    •  

bool "success"

turtle.dropUp( [count] )

Drops all items in the selected slot, or if [count] is specified, drops that many items.

    •  

bool "success"

turtle.craft( [quantity] ) Attempts to craft an item with the resources in its inventory. See the page for crafty turtle for more details.

Note: The turtle.dig and turtle.craft commands are restricted to mining and crafty turtles, respectively. All other commands marked with a * are usable by simple and mining turtles.


Cookies help us deliver our services. By using our services, you agree to our use of cookies.

Need wiki hosting?

Do you need a wiki for your Minecraft mod/gaming wiki? We'll host it for free! Contact us.

Other wikis

Indie-game wikis
Powered by Indie Wikis