public boolean isInArea(Area checkArea, boolean isAllWithinArea) {
        return ((isAllWithinArea && pos1.isInArea(checkArea) && pos2.isInArea(checkArea))
                || (!isAllWithinArea && (pos1.isInArea(checkArea) || pos2.isInArea(checkArea))));
    }