Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --mMultiOS
- --<~t<true>marcelOS<info<0||name<0|explorer>version<1|0.2>changePrint<2|false>eventfilter<0|mouse_click|window_resize|window_fullscreen>EventManager<3|true>Debug<3|true>>code<0|print("Hello, explorer run under marcelOS")>>other<info<0||name<0|explorer>version<2|0.2>>code<0|~i<23>print("Unknown OS ...")>>>
- Application.window = windows.CreateWindow( "LightSystem" , Application , true)
- Application.window:SetSize(40,35)
- Application.window:FindSpace(111)
- function Rahmen()
- function ComputerraumRahmen()
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,1)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Computerraum:" )
- term.setCursorPos(15,1)
- term.setBackgroundColor(colors.green)
- Application.window:print( "On" )
- term.setCursorPos(20,1)
- term.setBackgroundColor(colors.red)
- Application.window:print( "Off" )
- term.setCursorPos(26,1)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Status:" )
- end
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,2)
- term.setBackgroundColor(colors.black)
- Application.window:print( "----------------------------------------------------------------------------------------------------------------------------------------------------------" )
- function ServerraumRahmen()
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,3)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Serverraum:" )
- term.setCursorPos(15,3)
- term.setBackgroundColor(colors.green)
- Application.window:print( "On" )
- term.setCursorPos(20,3)
- term.setBackgroundColor(colors.red)
- Application.window:print( "Off" )
- term.setCursorPos(26,3)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Status:" )
- end
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,4)
- term.setBackgroundColor(colors.black)
- Application.window:print( "----------------------------------------------------------------------------------------------------------------------------------------------------------" )
- function TekkitraumRahmen()
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,5)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Tekkitraum:" )
- term.setCursorPos(15,5)
- term.setBackgroundColor(colors.green)
- Application.window:print( "On" )
- term.setCursorPos(20,5)
- term.setBackgroundColor(colors.red)
- Application.window:print( "Off" )
- term.setCursorPos(26,5)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Status:" )
- end
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,6)
- term.setBackgroundColor(colors.black)
- Application.window:print( "----------------------------------------------------------------------------------------------------------------------------------------------------------" )
- function LagerraumRahmen()
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,7)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Lagerraum:" )
- term.setCursorPos(15,7)
- term.setBackgroundColor(colors.green)
- Application.window:print( "On" )
- term.setCursorPos(20,7)
- term.setBackgroundColor(colors.red)
- Application.window:print( "Off" )
- term.setCursorPos(26,7)
- term.setBackgroundColor(colors.black)
- Application.window:print( "Status:" )
- end
- Application.window.l:setFontColor( colours.white )
- term.setCursorPos(1,8)
- term.setBackgroundColor(colors.black)
- Application.window:print( "----------------------------------------------------------------------------------------------------------------------------------------------------------" )
- while true do
- Application.window:Paint()
- mTask.sleepEvent(Application,1)
- ComputerraumRahmen()
- ServerraumRahmen()
- TekkitraumRahmen()
- LagerraumRahmen()
- end
- end
- term.setBackgroundColor(colors.black)
- while true do
- Rahmen()
- Eingabe()
- Application.window:Paint()
- mTask.sleepEvent(Application,1)
- end
- -- Dieser Teil funktioniert leider nicht :(
- function Eingabe()
- event,side,x,y = os.pullEvent()
- if event == "monitor_touch" then
- if x == 15 and y == 1 or x == 16 and y == 1 then
- rs.setOutput("bottom", true)
- rednet.send(1, "ComputerraumLightOn") --Zahl= Id des Server
- end
- if x == 20 and y == 1 or x == 21 and y == 1 or x == 22 and y == 1 then
- rednet.send(1, "ComputerraumLightOff") --Zahl= Id des Server
- end
- if x == 15 and y == 3 or x == 16 and y == 3 then
- rednet.send(1, "ServerraumLightOn") --Zahl= Id des Server
- end
- if x == 20 and y == 3 or x == 21 and y == 3 or x == 22 and y == 3 then
- rednet.send(1, "ServerraumLightOff") --Zahl= Id des Server
- end
- if x == 15 and y == 5 or x == 16 and y == 5 then
- rednet.send(1, "TekkitraumLightOn") --Zahl= Id des Server
- end
- if x == 20 and y == 5 or x == 21 and y == 5 or x == 22 and y == 5 then
- rednet.send(1, "TekkitraumLightOff") --Zahl= Id des Server
- end
- if x == 15 and y == 7 or x == 16 and y == 7 then
- rednet.send(1, "LagerraumLightOn") --Zahl= Id des Server
- end
- if x == 20 and y == 7 or x == 21 and y == 7 or x == 22 and y == 7 then
- rednet.send(1, "LagerraumLightOff") --Zahl= Id des Server
- end
- end
- end
- while true do
- Rahmen()
- Eingabe()
- Application.window:Paint()
- mTask.sleepEvent(Application,1)
- end
Advertisement
Add Comment
Please, Sign In to add comment