76 posts
Location
Death City
Posted 13 September 2012 - 11:31 PM
PLACEHOLDER: #3
No questions for now
Oh and please answer questions in this format:
Spoiler
#1: bla bla bla
436 posts
Posted 13 September 2012 - 11:42 PM
#1: RichardG had the turtle make the computer a peripheral (peripheral.wrap("front")) and then have it reset, which I think is something like per.shutdown(), per.start(), where per is the variable for the wrapped computer.
#2: That depends on what you are doing, but most times, you are going to be using os.pullEvent("key"), which will wait for a key to be pressed. Then, just have an if statement looking for those specific keys, and have them do what you want.
#3: You can find this in the config file. For most programs, though, you will want to check it, by using x, y = term.getSize(). The x variable will be the number you are looking for.
3790 posts
Location
Lincoln, Nebraska
Posted 13 September 2012 - 11:45 PM
- You can use the Peripheral API, since computers and turtles are treated as peripherals.
- You would want the os.pullEvent() function.
- Like this:
local event,p1 = os.pullEvent()
if p1 == KEYCODE then
--do stuff here
end
- What do you mean how many columns?
edit: keycodes can be found here:
http://www.minecraftwiki.net/wiki/Key_Codes