Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local tArgs = {...}
- if #tArgs ~= 1 then
- print("Usage: apiary <#>")
- return
- end
- local side = "left"
- local colors = {
- "white",
- "orange",
- "magenta",
- "lightblue",
- "yellow",
- "lime",
- "pink",
- "grey"
- }
- local select = tonumber( tArgs[1] )
- local state = tostring( tArgs[2] )
- local offcheck = tostring(tArgs[1])
- for i=1,#colors do
- if select == i then
- local cs = ("colors."..colors[i])
- if state == "on" then
- rs.setBundledOutput(side,cs)
- end
- elseif offcheck = "off"
- rs.setBundledOutput(side,0)
- end
- end
Add Comment
Please, Sign In to add comment