r/ComputerCraft • • Aug 01 '20

Help with a finding code.

Hey, I was wondering if anyone new the code for a farming turtle that could farm a plot of 16x16 (if possible). I've looked around and haven't found much for CC 1.58, the version used for tekkit. Any help is appreciated, thanks.

0 Upvotes

6 comments sorted by

View all comments

1

u/boxesandcircles Aug 01 '20

The program of it would depend on how full featured it would be. Does it build the farm? Are you gonna have him use turtle.inspect to harvest and replant? Would those be better as separate programs?

1

u/music_stormcatcher Aug 01 '20

Thanks for the reply. The idea is that it would harvest the farm and dispense it into a chest at a "home station" if possible?

1

u/boxesandcircles Aug 01 '20

turtle.inspect returns a bunch of tables, use the Lua prompt to see. Inspect will return a table including data values, full grown wheat has a data values of seven. Create a function that inspects down every time it moves forward and harvests if it's full grown wheat. Then create code to have him move over your whole plot. At the end of movement he deposits in a chest, waits for a while using sleep(seconds) then the main loop runs again.

1

u/music_stormcatcher Aug 01 '20

Brilliant I'll try that when I get the chance. Thanks!