From 7a843edbbc816235e3e2e2c2bd35e53aab80364f Mon Sep 17 00:00:00 2001 From: luigi-budd <90123055+luigi-budd@users.noreply.github.com> Date: Sun, 27 Oct 2024 19:04:57 -0500 Subject: [PATCH] Remove possible exploit --- src/Lua/Hooks/HUD/Drawers/role.lua | 32 ++++++++++++++++-------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/src/Lua/Hooks/HUD/Drawers/role.lua b/src/Lua/Hooks/HUD/Drawers/role.lua index 80ffc57..13165a3 100644 --- a/src/Lua/Hooks/HUD/Drawers/role.lua +++ b/src/Lua/Hooks/HUD/Drawers/role.lua @@ -67,21 +67,23 @@ local function HUD_RoleDrawer(v,p) v.drawScaled(x + off, y, FU, patch, V_SNAPTOTOP|V_SNAPTORIGHT|V_50TRANS) v.drawString(x + off, y + (2*FU), version, V_SNAPTOTOP|V_SNAPTORIGHT|V_80TRANS, "thin-fixed") - local mchance = p.mm_save.cons_murderer_chance - local schance = p.mm_save.cons_sheriff_chance - - v.drawString(320*FU + off - 30*FU, - y + (2*FU), - string.format("%.2f",mchance).."%", - V_SNAPTOTOP|V_SNAPTORIGHT|V_REDMAP, - "thin-fixed-right" - ) - v.drawString(320*FU + off, - y + (2*FU), - string.format("%.2f",schance).."%", - V_SNAPTOTOP|V_SNAPTORIGHT|V_BLUEMAP, - "thin-fixed-right" - ) + if p == consoleplayer + local mchance = p.mm_save.cons_murderer_chance + local schance = p.mm_save.cons_sheriff_chance + + v.drawString(320*FU + off - 30*FU, + y + (2*FU), + string.format("%.2f",mchance).."%", + V_SNAPTOTOP|V_SNAPTORIGHT|V_REDMAP, + "thin-fixed-right" + ) + v.drawString(320*FU + off, + y + (2*FU), + string.format("%.2f",schance).."%", + V_SNAPTOTOP|V_SNAPTORIGHT|V_BLUEMAP, + "thin-fixed-right" + ) + end end if p.spectator