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

[SOLVED]'then' expected

Started by Rangicus, 08 September 2012 - 12:26 PM
Rangicus #1
Posted 08 September 2012 - 02:26 PM
So I am making a program to record how many times my door has tried to be opened with a wrong password,
but I get this error:

bios:206: [string "startup"]:7: 'then' expected
Here is my code:

os.pullEvent = os.pullEventRaw
function PrintDoors()
x = x + 1
print("Failed Opening Attempts:(..x..)")
end
if rs.getInput("bottom")
PrintDoors()
end
Help?
Chain #2
Posted 08 September 2012 - 02:43 PM
You forgot the "then" after if rs.getInput("bottom")

also wrong forum