private void checkObstacleBounds(boolean positiveSide, float delta, float half) {
		positionCenter = originalCenter + delta;
		if (positiveSide) {
			positionCorner = Math.abs(originalCorner + delta);
			delta = 0.5f * (positionCenter + positionCorner - half);
			if (delta > 0) {
				positionCenter -= delta;
				positionCorner -= delta;
			}
			else {
				delta = 0.5f * (positionCenter - positionCorner + half);
				if (delta < 0) {
					positionCenter -= delta;
					positionCorner += delta;
				}
				if (positionCenter < -half) {
					positionCorner = 0.5f * Obstacle.MIN_THICKNESS;
					positionCenter = positionCorner - half;
				}
			}
		}
		else {
			positionCorner = Math.abs(originalCorner - delta);
			// a negative delta means enlargement in the negative zone
			delta = 0.5f * (positionCenter - positionCorner + half);
			if (delta < 0) {
				positionCenter -= delta;
				positionCorner += delta;
			}
			else {
				delta = 0.5f * (positionCenter + positionCorner - half);
				if (delta > 0) {
					positionCenter -= delta;
					positionCorner -= delta;
				}
				if (positionCenter > half) {
					positionCorner = 0.5f * Obstacle.MIN_THICKNESS;
					positionCenter = half - positionCorner;
				}
			}
		}
	}