From 1580fbe339163b7d581b81faf38afcbecf320a47 Mon Sep 17 00:00:00 2001
From: Avi Weinstock <aweinstock314@gmail.com>
Date: Sat, 8 May 2021 17:16:53 -0400
Subject: [PATCH] Distinguish NAMETAG_MERCHANT_RANGE from NAMETAG_GROUP_RANGE.

---
 voxygen/src/hud/mod.rs | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/voxygen/src/hud/mod.rs b/voxygen/src/hud/mod.rs
index b5c2fad8f1..c4c8cf2a7d 100644
--- a/voxygen/src/hud/mod.rs
+++ b/voxygen/src/hud/mod.rs
@@ -177,6 +177,8 @@ const MENU_BG: Color = Color::Rgba(0.1, 0.12, 0.12, 1.0);
 
 /// Distance at which nametags are visible for group members
 const NAMETAG_GROUP_RANGE: f32 = 1000.0;
+/// Distance at which nametags are visible for merchants
+const NAMETAG_MERCHANT_RANGE: f32 = 50.0;
 /// Distance at which nametags are visible
 const NAMETAG_RANGE: f32 = 40.0;
 /// Time nametags stay visible after doing damage even if they are out of range
@@ -1572,8 +1574,10 @@ impl Hud {
                                 || in_group
                                 || is_merchant)
                                 && dist_sqr
-                                    < (if in_group || is_merchant {
+                                    < (if in_group {
                                         NAMETAG_GROUP_RANGE
+                                    } else if is_merchant {
+                                        NAMETAG_MERCHANT_RANGE
                                     } else if hpfl
                                         .time_since_last_dmg_by_me
                                         .map_or(false, |t| t < NAMETAG_DMG_TIME)