Generalized boundsCheck() to be used on either team