Jump to content




Can I Do Something Better On This Script?


  • You cannot reply to this topic
6 replies to this topic

#1 DaveyBeer1999

  • Members
  • 7 posts
  • LocationNetherlands

Posted 01 January 2014 - 03:34 PM

Hello people reading this I dont really know how to do this I'm new so I'm posting the script here and also give you the code to download it to your Turtle and the creator of MobDie thank you I used a part of his script for the Dropping of items and the name in the top corner,
Greets and Thank you from Davey Beer,
Download code: pastebin get cKVYkA25
The script:
term.clear()
term.setCursorPos(1,1)
if term.isColor() == true then
term.setTextColor(colors.red)
print("GollemKill 1.0")
else
print("GollemKill 1.0")
end
while true do
turtle.attack()
for i = 1, 16 do
turtle.select(i)
turtle.drop()
end
sleep(5)
end

Edited by Bubba, 02 January 2014 - 04:23 PM.
Use. Code. Tags. That's. What. They're. For.


#2 CometWolf

  • Members
  • 1,283 posts

Posted 01 January 2014 - 04:31 PM

term.clear()
term.setCursorPos(1,1)
if term.isColor() then --if you're just checking for not FALSE you can just write the variable/function without any equal signs
  term.setTextColor(colors.red)
end
print("GolemKill 1.0") --typo, and no need to have it within the if statement, since it's performed either way
while true do
  turtle.attack()
  for i = 1, 16 do
	turtle.select(i)
	turtle.drop()
  end
  sleep(5)
end
It can be shortened a little bit and you can add indentation. Perhaps you could add inventory checking before dropping the items, hard for me to say since i don't know what you want this to do.

#3 DaveyBeer1999

  • Members
  • 7 posts
  • LocationNetherlands

Posted 02 January 2014 - 08:03 AM

The name GollemKiller is ment for what i has to do i made the program for a irongollem farm so thats why thank you for your support

#4 CometWolf

  • Members
  • 1,283 posts

Posted 02 January 2014 - 10:51 AM

That's my point... It's "Golem", note the one "l".

#5 DaveyBeer1999

  • Members
  • 7 posts
  • LocationNetherlands

Posted 02 January 2014 - 01:05 PM

Thank you gonna update when I'm ready to... And also I'm from the Netherlands so you will find mistakes ;P

Edited by DaveyBeer1999, 02 January 2014 - 01:06 PM.


#6 DaveyBeer1999

  • Members
  • 7 posts
  • LocationNetherlands

Posted 04 January 2014 - 11:35 AM

Update is coming got problems with the item count gonna try that later sorry

Edited by DaveyBeer1999, 04 January 2014 - 12:40 PM.


#7 subzero22

  • Members
  • 97 posts

Posted 08 January 2014 - 01:59 PM

while true do
turtle.attack()
for i = 1, 16 do
turtle.select(i)
turtle.drop()
end

For this you would need it to select slot one again after it get's to the 16th's slot.
Here's what I do for my mob farms.

while true do
  if turtle.getItemCount(16) >= 0 then
	x = 1
	for i=1,16 do
	  turtle.select(x)
	  turtle.dropDown()
	  s = s + 1
   else
	  turtle.select(1)
	  turtle.attack()
	  turtle.suck()
      turtle.sleep(0.1)
  end
end
  
	

Edited by subzero22, 08 January 2014 - 02:00 PM.






2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users