673 posts
Posted 12 December 2013 - 05:47 PM
I've created a simple and cool program for turtles (obviously) called MobDie. Any mob under it will get literally demolished to pieces, as well as preventing the stopping of the system through blocks. Use on a melee turtle for best results. (also, mobs must be below it)
How to install:
Enable HTTP in the config file and type this on a turtle:
pastebin get 2dCEqaHJ startup
NEW:
Fixed inventory bug.
BUGS:
Attacking is slower due to loops…Can't fix it, not an issue I hope?
Now go put a villager near-under it and watch the zombies chase to death XD
Edited on 17 January 2014 - 05:18 PM
673 posts
Posted 12 December 2013 - 06:02 PM
Surprised by the number of views so far.
Thanks guys :D/>
110 posts
Posted 13 December 2013 - 08:36 AM
It's a good start. What happens when its inventory fills up?
I've got a melee turtle at the end of my mob farm that, at the core, is basically a loop of turtle.attack(), so nothing special there, but when slot 16 gets an item in it, it turns around and dumps the junk on the ground (determined by samples in the first five slots, such as rotten flesh and bows) and the rest in a chest. That's where I also report the number of hits so I don't spam the display.
I actually use three turtles to triple-team the mobs (left, right, above). In the past I had issues with creepers blowing up if they weren't killed fast enough after the first hit. That issue went away but I find one turtle gets the vast majority of the hits while another gets less and the third barely gets any.
BTW, I don't think you need to turtle.suck() because drops from a killed mob go into the inventory. However, I have seen items occasionally get by my turtle, so….
673 posts
Posted 13 December 2013 - 03:35 PM
1. Well, I didn't make it do anything but attack mobs under it.
2. I used turtle.suck() to make it "attack" items, for fun.
I'll see if I can use the dump thing to improve it.
673 posts
Posted 13 December 2013 - 03:56 PM
MOBDIE 0.2:
Added new feature. Items go up if found in turtle.
MOBDIE 0.3:
Fixed the multi-item bug.
5 posts
Location
Netherlands
Posted 01 January 2014 - 03:42 PM
Yo man I used the start of your code and to check my code I like that you made is small and not long thank you your code helped me allot thanks again. Keep up the work!
5 posts
Posted 05 January 2014 - 08:57 PM
Very helpful, thank you very much!
673 posts
Posted 17 January 2014 - 06:17 PM
Very helpful, thank you very much!
Yo man I used the start of your code and to check my code I like that you made is small and not long thank you your code helped me allot thanks again. Keep up the work!
When I make programs, I try to compact them and make them as neat with the intro (like "changing" the intro of when you fire it). Thanks! ;)/>
3 posts
Posted 24 January 2014 - 12:25 PM
term.clear()
term.setCursorPos(1,1)
if term.isColor() == true then
term.setTextColor(colors.yellow)
print("MobDie 0.3")
else
print("MobDie 0.3")
end
while true do
turtle.attackDown()
turtle.suckDown()
turtle.digDown()
for i = 1, 16 do
turtle.select(i)
turtle.dropUp(64)
end
end
improved code:
term.clear()
term.setCursorPos(1,1)
if term.isColor() then
term.setTextColor(colors.yellow)
print("MobDie 0.3")
else
print("MobDie 0.3")
end
while true do
turtle.attackDown()
turtle.suckDown()
turtle.digDown()
for i = 1, 16 do
turtle.select(i)
turtle.dropUp()
end
end
You don't need a == to true ( if (x == true) then ..)
And you don't need to put a parameter in the dropUp since it outputs everything from the slot.
And please use spaces to format your code ;)/>
Cheers