From f213753c7ecf42dac73f59fa1b9a11d72e2f7183 Mon Sep 17 00:00:00 2001 From: Hydrox6 Date: Thu, 4 Jul 2019 14:51:32 +0100 Subject: [PATCH] prayer: fix HD prayer bar flick location --- .../net/runelite/client/plugins/prayer/PrayerBarOverlay.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/prayer/PrayerBarOverlay.java b/runelite-client/src/main/java/net/runelite/client/plugins/prayer/PrayerBarOverlay.java index 5798698621..df4da38850 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/prayer/PrayerBarOverlay.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/prayer/PrayerBarOverlay.java @@ -109,10 +109,11 @@ class PrayerBarOverlay extends Overlay final double t = plugin.getTickProgress(); final int halfBarWidth = (barWidth / 2) - HD_PRAYER_BAR_PADDING; - final int xOffset = (int) (-Math.cos(t) * halfBarWidth) + ((barWidth / 2) - halfBarWidth); + final int xOffset = (int) (-Math.cos(t) * halfBarWidth) + halfBarWidth; graphics.setColor(FLICK_HELP_COLOR); - graphics.fillRect(barX + xOffset + HD_PRAYER_BAR_PADDING, barY + HD_PRAYER_BAR_PADDING, 1, barHeight - HD_PRAYER_BAR_PADDING * 2); + // Padding is accounted for in the offset calculation + graphics.fillRect(barX + xOffset, barY + HD_PRAYER_BAR_PADDING, 1, barHeight - HD_PRAYER_BAR_PADDING * 2); } return new Dimension(barWidth, barHeight);