v49: Reduce memory usage for resources cache

It was already designed to be memory-efficient, however we can reduce it
even more by using a byte array with just one bit per cache group instead
of a boolean array with one byte per cache group.

The additional calculations take away a tiny bit of the performance boost,
but it's still good (and faster than using a BitSet).

Thanks to @Tungstwenty for the suggestion!