Jump to content




targs?


  • You cannot reply to this topic
1 reply to this topic

#1 jakemg

  • Members
  • 88 posts

Posted 15 June 2013 - 06:27 PM

Hi I forgot how to do targs for my turtle
what im trying to is have the program start with
"welcome to quarry"
"please say how far you want me to mine"
"width":(then have the turtle read what was input and set that to x)

you dont have to put print("welcome to quarry blah blah blah you can just say how to put targs and how to read them

thanks =D

#2 ElvishJerricco

  • Members
  • 803 posts

Posted 15 June 2013 - 06:30 PM

tArgs = { ... }

local x = tonumber(tArgs[1] or "")
while not x do
	print("Need a distance to travel in number form")
	x = tonumber(read())
end

-- rest of code goes below






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users