public PathQuad(PathQuad parent, float x, float y, BufferedImage hitmap) {
		this.parent = parent;
		right = new ArrayList<PathQuad>();
		down = new ArrayList<PathQuad>();
		left = new ArrayList<PathQuad>();
		up = new ArrayList<PathQuad>();
		if(parent == null) {
			//box = new Rectangle2D.Float(x, y, (float)foreground.getBox().getWidth(), (float)foreground.getBox().getHeight());
			box = new Rectangle2D.Double(x, y, hitmap.getWidth(), hitmap.getHeight());
			right.add(null);
			down.add(null);
			left.add(null);
			up.add(null);
			pos = -1;
		} else {
			box = new Rectangle2D.Double(x, y, (float)Math.ceil(parent.getBox().getWidth()/2), (float)Math.ceil(parent.getBox().getHeight()/2));
		}
		buildQuad(hitmap);
	}