I like that idea icehunter but i can't get it to write a number instead of ("..i..")
I think it is because h.write function has to be a string. Also the a-b-c-d… variables are just for telling the turtle that there is a space because it doesn't detect any of the things in it's inventory. If I could get your block function to work i wouldn't need all of them.
Anyway I was trying to add more functionality to my program so now you can ask that it be saved in another location then 'builder'. The problem is you only get one chance to use the save. If you try and make it in an invalid directory you have to rename the file/move it manually. if it fails it will say copy failed. Is there any thing I can do to fix that. I was trying to make it not go to the next function if it fails..
Imput = "read()"
fs.makeDir("blueprints")
fs.copy("builder",read())
I also am looking for a way to have a function that you can type into that will write everything to the program
inside of a print that way you will not accidentally interfere with the program and can call the data on program start.
I feel this is needed because turtles can't remember what is in there slots so if the user can write so they know what it was and in what slot then the program can be very useful.
I think i got this program from someone else… anyway whenever I try to alter it a little it doesn't write at all…
file = io.open("builder", "a")
print("Block Copier 1.0")
print("Enter debuging/write() txt only")
print("Write slot# and type for all blocks")
print("This is for your reference later")
print("DON'T ENTER COMMANDS")
print("Type 'exit' to continue")
local text
while true do
text=io.read()
h = fs.open("builder", "a")
if text ~= 'exit' then
file:write(text.."\n")
else
break
end
end
file:close()
h.close()
I made so some more printed text to help the user not much different…