Melee Turtle

From ATLauncher Wiki
Jump to: navigation, search
This article is a stub. You can help the wiki by expanding it.


Melee Turtle
Melee Turtle

Name Melee Turtle
Source Mod ComputerCraft
ID Name Unknown
Type Mobile computer
Stackable Yes (64)
Damage dealt Heart.pngHeart.pngHeart.pngHeart.pngHeart.png

The Melee Turtle is a ComputerCraft Turtle which specializes in fighting. Its attack is the strongest of all turtles, at 10 hit points (5 hearts) of damage per attack. The turtle will automatically collect its victim's drops upon killing them and will even cause mobs to drop their XP. Turtles on their own however are incapable of collecting XP orbs. To fully automate an XP farm, Melee Turtles can be used in conjunction with items such as the Brain in a Jar, Sewer, Vacuum Hopper, or Misc Peripherals' XP Upgrade peripheral.

The turtle API exposes the function turtle.attack() for Lua scripts but no default program exists for making the turtle attack.

Recipe[edit]

GUI Crafting Table.png
Turtle (ComputerCraft)
Diamond Sword






Melee Turtle
GUI Crafting Table.png
Turtle (ComputerCraft)
Sapphire Sword






Melee Turtle

GUI Crafting Table.png
Turtle (ComputerCraft)
Green_Sapphire Sword






Melee Turtle
GUI Crafting Table.png
Turtle (ComputerCraft)
Ruby Sword






Melee Turtle

Note that:

  • Each recipe is reversible, but not shapeless.
  • Only the swords listed can be used (i.e. an iron sword does not work).
  • The sword must have no damage.
  • Enchantments on the sword will have no effect on the Melee Turtle's attacks.
  • The type of sword used will be shown on the side of the turtle.

Usage[edit]

Crafty Melee Turtle[edit]

GUI Crafting Table.png
Melee Turtle
Crafting Table






Crafty Melee Turtle

Wireless Melee Turtle[edit]

GUI Crafting Table.png
Melee Turtle
Wireless Modem






Wireless Melee Turtle

Attack program[edit]

A simple attack program, which has the turtle continuously attack whatever is in front of it, can be coded as follows:

 while true do
  turtle.attack()
  sleep(.1)
 end

Or, to have the turtle attack only while receiving a redstone signal (to its back, in this example):

 while true do
  while redstone.getInput("back") do
     turtle.attack()
     sleep(.1)
  end
  sleep(.5)
 end

To create either of these programs, type in "edit [program name]" (without the brackets) in the turtle interface and press Enter. Type in your program and save it (press Control to bring up the menu, then hit "s") and exit (Control, "e"). To run the program, type the program name into the turtle interface, and hit Enter.

If you want the program to start automatically whenever the turtle loads or is rebooted, give it the name "startup".

Note that if you are on a multiplayer server without pvp enabled, the turtle will not attack you.