Hiranus icon

bee sth

Hiranus | PRO | 09/29/14 08:39:14 PM UTC | 0 ⭐ | 491 👁️ | Never ⏰ | []
text |

710 B

|

None

|

0 👍

/

0 👎

os.loadAPI("button")
button.prepareMonitor()
button.setSleep(0)
 button.setBasicButtonVar(7,5,1)
  local isAuto=true
function beeAuto ()
	if isAuto == false then
		isAuto=true
		button.selectGroup("B")
		rs.setOutput("left",true)
		rs.setOutput("right",false)
	else
		isAuto=false
		button.selectGroup("A")
		rs.setOutput("left",false)
		rs.setOutput("right",true)
	end
	button.redrawScreen()
 end
beeAuto()
button.selectGroup("A")
button.addBasicButton("Au OFF",beeAuto,button.flash)
button.selectGroup("B")
button.addBasicButton("Au ON",beeAuto,button.flash,colors.lime,colors.blue)
button.selectGroup("A")
button.calculateButtons()
 button.redrawScreen()
while true do
	button.getClick()
end

Comments

  •  icon
    01/01/70 12:00:00 AM UTC
    Plain Text |

    0 B

    |

    👍

    /

    👎