From 6e73c25afdb025223b9e76665bac79fe2cf3e5b6 Mon Sep 17 00:00:00 2001 From: BenCat07 Date: Fri, 27 Apr 2018 17:21:57 +0200 Subject: [PATCH] exclude specific autoheal name --- src/hacks/AutoHeal.cpp | 6 ++++++ src/reclasses/CTFPartyClient.cpp | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/hacks/AutoHeal.cpp b/src/hacks/AutoHeal.cpp index c7627752..f4326464 100755 --- a/src/hacks/AutoHeal.cpp +++ b/src/hacks/AutoHeal.cpp @@ -44,6 +44,7 @@ static CatEnum vacc_sniper_enum({ "NEVER", "ZOOM & VISIBLE", "ANY ZOOMED" }); static CatVar vacc_sniper(vacc_sniper_enum, "auto_vacc_sniper_pop", "1", "Pop if Sniper", "Defines Auto-Vacc behaviour with snipers"); +static CatVar ignore(CV_STRING, "autoheal_ignore", "", "Ignore", "Ignore people with this name"); int ChargeCount() { @@ -561,6 +562,11 @@ int HealingPriority(int idx) } } #endif + player_info_s info; + g_IEngine->GetPlayerInfo(idx, &info); + info.name[31] = 0; + if (strcasestr(info.name, ignore.GetString())) + priority = 0.0f; return priority; } diff --git a/src/reclasses/CTFPartyClient.cpp b/src/reclasses/CTFPartyClient.cpp index f909f8f6..9da525b0 100644 --- a/src/reclasses/CTFPartyClient.cpp +++ b/src/reclasses/CTFPartyClient.cpp @@ -69,7 +69,7 @@ char re::CTFPartyClient::RequestQueueForMatch(int type) { typedef char (*RequestQueueForMatch_t)(re::CTFPartyClient *, int); uintptr_t addr = gSignatures.GetClientSignature( - "55 89 E5 57 56 53 81 EC ? ? ? ? 8B 45 ? E8 ? ? ? ?"); + "55 89 E5 57 56 53 81 EC ? ? ? ? 8B 75 ? 89 F0"); RequestQueueForMatch_t RequestQueueForMatch_fn = RequestQueueForMatch_t(addr);