Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- bCableLeft = rs.getBundledInput("left")
- bCableRight = rs.getBundledInput("right")
- -- Get a number representing colors on in both right and left bundled cables
- commonColors = bit.band(bCableLeft, bCableRight)
- -- Get all the colors active on either right or left
- totalColors = bit.bor(bCableLeft, bCableRight)
- -- Get the colors which are active on right, or left, but not both at the same time
- exclusiveColors = bit.bxor(bCableLeft, bCableRight)
- -- Get the colors that are not active on the left
- offColorsA = bit.bnot(bCableLeft)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement