diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerConfig.java b/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerConfig.java index c577f72f35..0882225d68 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerConfig.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerConfig.java @@ -98,4 +98,14 @@ public interface GroundMarkerConfig extends Config { return 2; } + + @ConfigItem( + keyName = "fillOpacity", + name = "Fill Opacity", + description = "Opacity of the tile fill color" + ) + default int fillOpacity() + { + return 50; + } } diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerOverlay.java b/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerOverlay.java index 266e89c9b5..ffe39109c8 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerOverlay.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/groundmarkers/GroundMarkerOverlay.java @@ -114,7 +114,7 @@ public class GroundMarkerOverlay extends Overlay Polygon poly = Perspective.getCanvasTilePoly(client, lp); if (poly != null) { - OverlayUtil.renderPolygon(graphics, poly, color, borderStroke); + OverlayUtil.renderPolygon(graphics, poly, color, new Color(0, 0, 0, config.fillOpacity()), borderStroke); } if (!Strings.isNullOrEmpty(label)) diff --git a/runelite-client/src/main/java/net/runelite/client/ui/overlay/OverlayUtil.java b/runelite-client/src/main/java/net/runelite/client/ui/overlay/OverlayUtil.java index 26497ab43d..df52467132 100644 --- a/runelite-client/src/main/java/net/runelite/client/ui/overlay/OverlayUtil.java +++ b/runelite-client/src/main/java/net/runelite/client/ui/overlay/OverlayUtil.java @@ -54,12 +54,17 @@ public class OverlayUtil } public static void renderPolygon(Graphics2D graphics, Shape poly, Color color, Stroke borderStroke) + { + renderPolygon(graphics, poly, color, new Color(0, 0, 0, 50), borderStroke); + } + + public static void renderPolygon(Graphics2D graphics, Shape poly, Color color, Color fillColor, Stroke borderStroke) { graphics.setColor(color); final Stroke originalStroke = graphics.getStroke(); graphics.setStroke(borderStroke); graphics.draw(poly); - graphics.setColor(new Color(0, 0, 0, 50)); + graphics.setColor(fillColor); graphics.fill(poly); graphics.setStroke(originalStroke); }