directions |= CompassPoints.invert(directions); if ((trackLock & directions) == 0) {
int lock = trackLock | CompassPoints.invert(trackLock); if ((lock & directions) == 0) {
    public boolean getLock(byte directions) {	directions |= CompassPoints.invert(directions);	if ((trackLock & directions) == 0) {	    trackLock |= directions;	    return true;	}	return false;    } 