diff --git a/extras/edu/umd/cs/piccolox/util/LineShape.java b/extras/edu/umd/cs/piccolox/util/LineShape.java index 050b8e9..272188f 100644 --- a/extras/edu/umd/cs/piccolox/util/LineShape.java +++ b/extras/edu/umd/cs/piccolox/util/LineShape.java @@ -175,12 +175,12 @@ return false; } x2 = points.getX(0); - y2 = points.getX(0); + y2 = points.getY(0); for (int i = 0; i < points.getPointCount(); i++) { x1 = x2; y1 = y2; x2 = points.getX(i); - y2 = points.getX(i); + y2 = points.getY(i); if (intersects(x, y, x + w, y, x1, y1, x2, y2, true, true, true, true) || intersects(x + w, y, x + w, y + h, x1, y1, x2, y2, true, true, true, true) || intersects(x + w, y + h, x, y + h, x1, y1, x2, y2, true, true, true, true) ||