47 posts
Posted 15 April 2013 - 01:35 AM
Hello Everyone!,
I have created a Program for the Turtle, with help from the Community.
[EDIT] New Download:
pastebin get NGcfU25z
To Install:Go to your Search Bar, and type %appdata%.It will bring to to your Roaming File. Click .minecraft.Once you are in your .minecraft, Click on a File called Save's.Click on your World File, click on a File called Computer.If you have a Disk in your World click on the Disk File, Then Drag the File I have attached to this Topic into a file called DiskThis is also my First Program for the Turtle. Enjoy!Also if there are any Bugs, Notify me Straight away!
1583 posts
Location
Germany
Posted 15 April 2013 - 01:57 AM
Your code works only by you.
Take screens, on they we can see how it constructed and how does it work.
47 posts
Posted 15 April 2013 - 03:34 AM
What do you mean?
Coal in Slot 1.
Torch's in Slot 2.
645 posts
Location
'Merica
Posted 15 April 2013 - 07:35 AM
All it does is place torches? Work on the GUI a bit more, also you might want to think about letting the user choose how far the turtle will travel to place torches, and what happens when the turtle runs into a block? That means you should also make it maneuver around blocks as well.
47 posts
Posted 15 April 2013 - 08:28 AM
Well it is Customisable. You just have to Change a bit of Code.
47 posts
Posted 16 April 2013 - 07:34 AM
There is now a Pastebin Download :)/>
645 posts
Location
'Merica
Posted 16 April 2013 - 03:29 PM
Well it is Customisable. You just have to Change a bit of Code.
Yes, but programs are better if you let the user customize it inSIDE the program..
47 posts
Posted 17 April 2013 - 08:40 AM
Okay, Well in V1.2 I will Implement that :)/> .
1583 posts
Location
Germany
Posted 17 April 2013 - 10:29 AM
Well it is Customisable. You just have to Change a bit of Code.
Yes, but programs are better if you let the user customize it inSIDE the program..
yea, I agree Spongy
The best is he safe the options into a confing file :3
[HAPPY]
I like config files very much :D/>
[/HAPPY]
4 posts
Location
Lithuania, Europe
Posted 18 April 2013 - 11:12 AM
Better one:
for 64*100 territory.
turtle.refuel(1)
for i = 1,64 do
for u = 1,100 do
turtle.select(2)
if turtle.getItemCount(2) == 0
then turtle.select(3)
end
turtle.place()
turtle.back()
turtle.back()
turtle.back()
end
turtle.left()
turtle.left()
turtle.left()
turtle.turnLeft()
turtle.turnLeft()
end
645 posts
Location
'Merica
Posted 19 April 2013 - 03:59 AM
Better one:
for 64*100 territory.
turtle.refuel(1)
for i = 1,64 do
for u = 1,100 do
turtle.select(2)
if turtle.getItemCount(2) == 0
then turtle.select(3)
end
turtle.place()
turtle.back()
turtle.back()
turtle.back()
end
turtle.left()
turtle.left()
turtle.left()
turtle.turnLeft()
turtle.turnLeft()
end
To bad yours only moves… if you JUST select the torch doesn't mean you place it.
55 posts
Posted 19 April 2013 - 10:51 PM
+ turtle.place() places only in front of the turtle … so if there's no wall, you fail.
mine is some minutes:
--- initialisation ---
print("Please put coal in slot 1 and torches in others slots")
print("how long?")
L = read()
L = math.floor(tonumber(L)/5)
print("how wide?")
W = read()
W = tonumber(W)
slotbase = 2
--- function ---
function testSlot()
while turtle.getItemCount(slotbase) == 0 do
slotbase = slotbase +1
if slotbase == 17 then slotbase = 2 end
end
function Job()
for j = 1, W do
for i = 1,L do
if turtle.getItemCount(slotbase) == 0 then testSlot() end
turtle.forward()
turtle.forward()
turtle.forward()
turtle.forward()
turtle.forward()
if turtle.detectDown() == false then
turtle.placeDown()
end
end
for i = 1, L do
turtle.forward()
turtle.forward()
turtle.forward()
turtle.forward()
turtle.forward()
end
end
function Fuel()
if fuelLvL < 2*L*W+10 then
turtle.select(1)
if turtle.refuel() == false then
print("Please, put fuel in slot 1")
else
turtle.refuel(5)
Fuel()
end
else
Job()
end
Fuel()
may contains bugs.
645 posts
Location
'Merica
Posted 20 April 2013 - 02:05 PM
^
Whats with you guys posting new code, … this guy is just trying to make his own program, if he wanted help he would have asked.
47 posts
Posted 22 April 2013 - 08:09 AM
^
Whats with you guys posting new code, … this guy is just trying to make his own program, if he wanted help he would have asked.
Thanks for Saying that, Spongy.