This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
Crowdy199's profile picture

Login Screen

Started by Crowdy199, 21 November 2012 - 10:12 AM
Crowdy199 #1
Posted 21 November 2012 - 11:12 AM
ok guys i am makeing a login screen this is my problem i want to make it type

username:
password:

at the same time then be able to type the username and password next to it plz help thank you guys
Luanub #2
Posted 21 November 2012 - 11:34 AM
Use term.setCursorPos()

Example

print("username: ")
write("password: ")
term.setCursorPos(11,1)
local uname = read()
term.setCursorPos(11,2)
local uname = read("*")
zekesonxx #3
Posted 22 November 2012 - 06:41 PM

print("Zeke's Wonderfully Horrible Login Panel")
write("Username: ")
username = read()
write("Password: ")
password = read()
print("Congrats, you have just used a horrible piece of code")

There you are.
Luanub #4
Posted 22 November 2012 - 08:41 PM

print("Zeke's Wonderfully Horrible Login Panel")
write("Username: ")
username = read()
write("Password: ")
password = read()
print("Congrats, you have just used a horrible piece of code")

There you are.

That does not do what he wanted, he wants the Username: and Password: to be displayed on the screen prior to the reads.
zekesonxx #5
Posted 22 November 2012 - 10:27 PM
Oh. Well your method works better then.