Okay, so you know how strings are made up of characters, and all those characters are made up of a single byte each. Assuming I'm using a string to represent a ton of bits, how can I get the values for a range of the bits? So say, I wanted the bits from 2 to 13 for some obscure reason, how can I take my string and extract all of the bits in that range?
As an example, "FF" is 0000111100001111 in binary. If I wanted to select bits 2 -> 13 in that, I'd get 000111100001. And then somewhere along the line somebody decides whether to pad the 0s to the left or to the right when converting it back to the string but that's not a problem.
Extra useful if an explanation includes how to turn the range into a boolean array (I have a solution for this bit but it's not particularly efficient).
If you're needing a use case, I'm planning on creating my own replication because Roblox networking sucks.

4 comments
Once you get the binary value, you could use the :sub. For example, if it was in a string value: print(game.ServerStorage.IntValue.Value:sub(2,13))
Hm, I could convert it to binary, but that would require evaluating the values of the entire string and I'm hoping not to do that.
I'm not sure how you would do this without first converting it to a binary format. I don't know of any built-in method that will extract such data from a variable/literal.
I can turn it into an array of bytes with {string.byte()} but that only gets me so far.