Advertisement
VikeStep

Rubiks Receivers

Jun 15th, 2013
195
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.34 KB | None | 0 0
  1. rednet.open("right")
  2. local x, y, difference
  3. while true do
  4.     if redstone.getInput("front") == true then
  5.         x = os.clock()
  6.         os.pullEvent("redstone")
  7.         y = os.clock()
  8.         difference = y - x
  9.         if difference < 0.5 then
  10.             rednet.send(219,"L")
  11.         elseif difference > 0.5 then
  12.             rednet.send(219,"L'")
  13.         end
  14.     end
  15.     os.pullEvent("redstone")
  16. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement