From b05614ee63e66656699cc6b60eb48806f6cbf1a7 Mon Sep 17 00:00:00 2001 From: ifBars <114284668+ifBars@users.noreply.github.com> Date: Sat, 14 Oct 2023 01:51:12 -0600 Subject: [PATCH] Update hack.hpp - Moved the flag_render_distance so that nothing will be drawn unless player is in range Feel free to change this how you see fit --- memory-external/hacks/hack.hpp | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/memory-external/hacks/hack.hpp b/memory-external/hacks/hack.hpp index 09e7309..644ce93 100644 --- a/memory-external/hacks/hack.hpp +++ b/memory-external/hacks/hack.hpp @@ -106,6 +106,15 @@ namespace hack { float distance = localOrigin.calculate_distance(origin); int roundedDistance = std::round(distance / 10); + /** + * I know is not the best way but a simple way to not saturate the screen with a ton of information + * From IfBars - I decided to move this up here so that it will not render anything unless the player is within the flag_render_distance + * I did this so people aren't confused on why only half the players hp values are showing, however feel free to change this however you see fit + * Personally I prefer to see everyone no matter the difference, but everyone has their preferences + */ + if (roundedDistance > config::flag_render_distance) + continue; + render::DrawBorderBox( g::hdcBuffer, screenHead.x - width / 2, @@ -137,11 +146,7 @@ namespace hack { 10 ); - /** - * I know is not the best way but a simple way to not saturate the screen with a ton of information - */ - if (roundedDistance > config::flag_render_distance) - continue; + render::RenderText( g::hdcBuffer,