Jump to content




Wheat farming problem



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

#1 buzzawak

  • Members
  • 64 posts

Posted 27 October 2012 - 09:26 AM

I am writting a wheat farming program and need a bit of help.

The "while turtle.compareDown() do" does not seem to work with wheat.

I have tested it by putting a dirt block in slot one and placing a dirt block
in the path of the turtle and it detects it, but doing the same with wheat and the turtle does not
recognise it.

Is this a bug ?


function farmWheat()
	lastBlock = 1
	turtle.select(1)
	repeat
		turtle.forward()
		if turtle.detectDown() then
			while turtle.compareDown() do
				turtle.digDown()
				turtle.suckDown()
			end		
		end	
		lastBlock = lastBlock + 1
	until lastBlock == 19
end

Thanks in advance

#2 Doyle3694

  • Members
  • 815 posts

Posted 27 October 2012 - 09:33 AM

wheat is a item not a block. you cannot get the wheat with metadata 7(I think it is 7 atleast, don't quote me on that). There is no actual way to detect the wheat, so you are going to have to try a different perspective of doing it

PS: The 'turtle.suckDown()' in your code is unneeded, since the turtle actually gets the wheat.

#3 buzzawak

  • Members
  • 64 posts

Posted 27 October 2012 - 11:31 AM

Thanks for the quick reply " Pro Coder" Thats a pitty that turtles can only detect blocks.

#4 ChunLing

  • Members
  • 2,027 posts

Posted 27 October 2012 - 02:26 PM

If you want to have a turtle farm wheat, then you'll need to use bonemeal farming. This is a more efficient use of the turtle anyway as it does not have to move and can just plant/bonemeal/dig its way through all the bonemeal you can give it. A common design is to use chests so that it can run for longer, but I generally don't bother with this. By the way, does anyone know of a good use for seeds?

#5 Doyle3694

  • Members
  • 815 posts

Posted 27 October 2012 - 07:53 PM

seed oil? and then make that to a alveary
and then have tons of bees

#6 darkrising

  • Members
  • 234 posts
  • LocationScotland

Posted 27 October 2012 - 08:09 PM

If you want to automate it you could just tell the turtle to wait for a few mins between harvesting.

#7 buzzawak

  • Members
  • 64 posts

Posted 28 October 2012 - 06:29 AM

View PostChunLing, on 27 October 2012 - 02:26 PM, said:

If you want to have a turtle farm wheat, then you'll need to use bonemeal farming. This is a more efficient use of the turtle anyway as it does not have to move and can just plant/bonemeal/dig its way through all the bonemeal you can give it. A common design is to use chests so that it can run for longer, but I generally don't bother with this. By the way, does anyone know of a good use for seeds?

I have had a play with the bonemeal. I like the way plants grow in minecraft and want a more nutural look. I have finished my wheat farm, the turtle is more robotic in its task, cutting and planting following a set route. Unaware if the wheat is ready or not, I just wait until I have a fully grown crop and set the turtle to work.

#8 ChunLing

  • Members
  • 2,027 posts

Posted 28 October 2012 - 06:34 AM

Fair enough. I just put my wheat farm in the basement or a closet, it's only a single block of dirt, a water source, a torch, and a turtle.

#9 buzzawak

  • Members
  • 64 posts

Posted 29 October 2012 - 06:04 AM

Started playing around with the Aperture Science Turtle Upgrade. I dont like having addons because things offen stop working when minecraft gets updated, but this upgrade mades the turtle more world aware.

#10 buzzawak

  • Members
  • 64 posts

Posted 29 October 2012 - 11:54 PM

Unfortunately Aperture Science Turtle Upgrade cannot recognise the difference between fully grown wheat and growth stages of wheat, so back to the drawing board.

#11 ChunLing

  • Members
  • 2,027 posts

Posted 30 October 2012 - 02:54 AM

I think that they might use a metadata for the different stages of wheat rather than changing the block ID. So, yeah, not much chance of ever getting that working.

#12 buzzawak

  • Members
  • 64 posts

Posted 02 November 2012 - 04:59 PM

View PostChunLing, on 30 October 2012 - 02:54 AM, said:

I think that they might use a metadata for the different stages of wheat rather than changing the block ID. So, yeah, not much chance of ever getting that working.

I have come to the same conclusion.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users