diff options
author | Walker Selby <git@walkerselby.com> | 2023-09-29 11:30:27 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-29 20:30:27 +0200 |
commit | 343d5d9cea12beaf7a8dfabda2f61ad940be592a (patch) | |
tree | ceb0a82790eaa1a1babfe4a2e05220378037a748 /src/main/java/at/hannibal2/skyhanni/features/cosmetics | |
parent | b364b6da62668ea44dfc23180fe70c13ec707804 (diff) | |
download | skyhanni-343d5d9cea12beaf7a8dfabda2f61ad940be592a.tar.gz skyhanni-343d5d9cea12beaf7a8dfabda2f61ad940be592a.tar.bz2 skyhanni-343d5d9cea12beaf7a8dfabda2f61ad940be592a.zip |
Random Code Cleanup (#516)
Sonar Lint for the win #516
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/cosmetics')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/cosmetics/CosmeticFollowingLine.kt | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/cosmetics/CosmeticFollowingLine.kt b/src/main/java/at/hannibal2/skyhanni/features/cosmetics/CosmeticFollowingLine.kt index 1f84e9e7b..e73a88fb5 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/cosmetics/CosmeticFollowingLine.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/cosmetics/CosmeticFollowingLine.kt @@ -55,19 +55,13 @@ class CosmeticFollowingLine { for ((a, b) in locations.keys.zipWithNext()) { val locationSpot = locations[b]!! - if (firstPerson) { - if (!locationSpot.onGround) { - if (b in last7) { - // Do not render the line in the face, keep more distance while the line is in the air - continue - } - } + if (firstPerson && !locationSpot.onGround && b in last7) { + // Do not render the line in the face, keep more distance while the line is in the air + continue } - if (b in last2) { - if (locationSpot.time.passedSince() < 400.milliseconds) { - // Do not render the line directly next to the player, prevent laggy design - continue - } + if (b in last2 && locationSpot.time.passedSince() < 400.milliseconds) { + // Do not render the line directly next to the player, prevent laggy design + continue } event.draw3DLine(a, b, color, locationSpot.getWidth(), !config.behindBlocks) } |