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

[Error] '=' expected

Started by kenken244, 08 January 2013 - 04:11 PM
kenken244 #1
Posted 08 January 2013 - 05:11 PM
Hello. I am writing my first program with computercraft and I am getting this error and I cannot for the life of me figure out what it means or how to fix it. the full error message is below

bios:338: [string "wrench"]:1: "=" expected
The code is below. it is using a miscperipherals wrench turtle to toggle the state of a redstone power conduit above it every time the redstone signal changes.

While true do
  local event = os.pullEvent("redstone")
  if event=="redstone" then turtle.digUp() end
  end
end
Dlcruz129 #2
Posted 08 January 2013 - 05:13 PM
Lua is case-sensitive. While true do should be while true do.

Edit: you also have one too many ends.
kenken244 #3
Posted 08 January 2013 - 05:15 PM
Ah. I fixed every other case issue bit I missed that one. I also had an extra "end". now it seems to be working. thanks.