Posted 19 January 2014 - 12:43 AM
I know you can call functions inside other functions. But can you call a function inside itself?
I would test this but right now at work and decided to edit one of my codes. Here's a snipit of my code so you know what I'm trying to ask.
I would test this but right now at work and decided to edit one of my codes. Here's a snipit of my code so you know what I'm trying to ask.
function check()
if s == 16 and turtle.getItemCount(16) >= 1 then
print("Turtle ran out of resources to build with")
print("Please refill turtle with needed blocks and")
print("press any key to continue building")
os.pullEven("key")
s = 1
end
if turtle.compareTo(16) == false then
s = s + 1
turtle.select(s)
check()
end
end