I just started playing around with computercraft, and I seem to have hit a few speed bumps. Mainly, the error "bios:206: [string "startup"]:6: syntax error"
this is my code
oldPull = os.pullEvent
os.pullEvent = os.pullEventRaw
while true do
term.clear()
term.setCursorPos(1,1)
write ("Passcode")
if read ("*") == "Password" then
ptint ("Access Granted")
term.clear()
term.setCursorPos(1,1)
break
else
print ("Access Denied")
end
end
os.pullEvent = oldpull
Help w/ password locked computer
Started by Fish_tacoz, Nov 05 2012 03:30 PM
5 replies to this topic
#1
Posted 05 November 2012 - 03:30 PM
#2
Posted 05 November 2012 - 03:36 PM
Try taking out the spaces from write and print. So this:
write(" ")
Instead of this:
write (" ")
If that doesn't work then try changing around then try. changin the code to this:
Tell me how it works out.
write(" ")
Instead of this:
write (" ")
If that doesn't work then try changing around then try. changin the code to this:
write("Passcode: ")
pass = read("*")
if pass == "Password" then
Tell me how it works out.
#3
Posted 05 November 2012 - 05:54 PM
oldPull = os.pullEvent
os.pullEvent = os.pullEventRaw
while true do
term.clear()
term.setCursorPos(1,1)
write ("Password: ")
if read("*") == "1234" then
print("Access Granted")
term.clear()
term.setCursorPos(1,1)
break
else
print("Access Denied")
end
end
os.pullEvent = oldpull
thar i fixed it
#4
Posted 05 November 2012 - 07:41 PM
Lol ptint?
#6
Posted 30 December 2012 - 09:47 AM
Thanks Everyone
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












