Promote server

Initial release 1.0.0

Browse Source
1.0.0 - Initial release.
Daemon666 committed commit 0d2f2afaf92e20c87ad1bd37b5a275b004193d2d
4 changed files with 161 additions and 0 deletions
+3 -0 CHANGELOG.md A
@@ -0,0 +1,3 @@
1 +## 1.0.0 (2025-09-03)
2 +
3 +1.0.0 - Initial release.
+1 -0 README.md A
@@ -0,0 +1 @@
1 +<p><strong>CSB Admin ESP</strong> lets an admin spot players through walls without changing what anyone else sees. It hooks <code>FM_AddToFullPack</code> and rewrites the entity render state (<code>kRenderFxGlowShell</code> plus a team colour) <em>only</em> in the packets destined for that one admin client. Because the change is per-recipient, ordinary players receive their normal packets and see no glow at all.</p><h2>Features</h2><ul><li>Per-admin toggle with <code>amx_esp [0|1]</code>, restricted by flag.</li><li>Glow injected in <code>FM_AddToFullPack</code> for the requesting client only &mdash; server-side, no client mods.</li><li>Team-coloured shells: red for T, blue for CT.</li><li>Works while alive or spectating; state clears automatically on disconnect.</li><li>A live counter avoids the forward doing any work when no admin has ESP on.</li></ul><h2>Installation</h2><ol><li>Make sure the <code>fakemeta</code> module is enabled in <code>addons/amxmodx/configs/modules.ini</code>.</li><li>Compile <code>csb_admin_esp.sma</code>, copy it to <code>addons/amxmodx/plugins/</code> and add it to <code>plugins.ini</code>.</li><li>Change the map.</li></ol><p><code>amx_esp</code> needs the <code>ADMIN_CFG</code> flag (<code>u</code>) by default. This is an admin visibility aid, not a client cheat: the glow never reaches non-admin clients.</p>
+120 -0 addons/amxmodx/scripting/csb_admin_esp.sma A
@@ -0,0 +1,120 @@
1 +/*
2 + * CSB Admin ESP
3 + * Copyright (C) 2026 counter-strike-boost.com
4 + *
5 + * Gives an admin a wallhack-style glow on players. It hooks FM_AddToFullPack and
6 + * sets kRenderFxGlowShell + a team colour ONLY in the packets destined for that
7 + * one admin client, so normal players see nothing changed. Toggled per admin
8 + * with amx_esp and restricted by a flag.
9 + *
10 + * This program is free software: you can redistribute it and/or modify it under
11 + * the terms of the GNU General Public License as published by the Free Software
12 + * Foundation, either version 3 of the License, or (at your option) any later
13 + * version. It is distributed in the hope that it will be useful, but WITHOUT
14 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
15 + * FOR A PARTICULAR PURPOSE. See <https://www.gnu.org/licenses/> for details.
16 + */
17 +
18 +#include <amxmodx>
19 +#include <amxmisc>
20 +#include <fakemeta>
21 +
22 +new const PLUGIN[] = "CSB Admin ESP"
23 +new const VERSION[] = "1.0.0"
24 +new const AUTHOR[] = "counter-strike-boost.com"
25 +
26 +new bool:g_bEsp[33]
27 +new g_pEnabled
28 +new g_iActive = 0
29 +
30 +public plugin_init()
31 +{
32 + register_plugin(PLUGIN, VERSION, AUTHOR)
33 +
34 + g_pEnabled = register_cvar("csb_esp_enabled", "1")
35 +
36 + register_concmd("amx_esp", "cmdEsp", ADMIN_CFG, "[0|1] - toggle wallhack glow ESP for yourself")
37 +
38 + register_forward(FM_AddToFullPack, "fwAddToFullPack", 1)
39 +}
40 +
41 +public client_disconnected(id)
42 +{
43 + if (g_bEsp[id])
44 + {
45 + g_bEsp[id] = false
46 + g_iActive--
47 + }
48 +}
49 +
50 +public cmdEsp(id, level, cid)
51 +{
52 + if (!cmd_access(id, level, cid, 1))
53 + return PLUGIN_HANDLED
54 +
55 + if (!get_pcvar_num(g_pEnabled))
56 + {
57 + console_print(id, "[CSB] ESP is disabled (csb_esp_enabled 0).")
58 + return PLUGIN_HANDLED
59 + }
60 +
61 + new bool:want = !g_bEsp[id]
62 +
63 + if (read_argc() > 1)
64 + {
65 + new arg[4]
66 + read_argv(1, arg, charsmax(arg))
67 + want = (str_to_num(arg) != 0)
68 + }
69 +
70 + if (want == g_bEsp[id])
71 + {
72 + client_print(id, print_chat, "[CSB] ESP already %s.", want ? "ON" : "OFF")
73 + return PLUGIN_HANDLED
74 + }
75 +
76 + g_bEsp[id] = want
77 + g_iActive += want ? 1 : -1
78 +
79 + client_print(id, print_chat, "[CSB] Admin ESP %s.", want ? "ON" : "OFF")
80 +
81 + new aname[32]
82 + get_user_name(id, aname, charsmax(aname))
83 + log_amx("[CSB ESP] %s turned ESP %s", aname, want ? "on" : "off")
84 + return PLUGIN_HANDLED
85 +}
86 +
87 +public fwAddToFullPack(es, e, ent, host, hostflags, player, pSet)
88 +{
89 + /* only rewrite entity states for player entities... */
90 + if (!player)
91 + return FMRES_IGNORED
92 +
93 + /* ...and only when the receiving host is an admin with ESP enabled */
94 + if (host < 1 || host > 32 || !g_bEsp[host])
95 + return FMRES_IGNORED
96 +
97 + if (ent == host || !is_user_alive(ent))
98 + return FMRES_IGNORED
99 +
100 + new r = 200, g = 200, b = 200
101 +
102 + switch (get_user_team(ent))
103 + {
104 + case 1: { r = 255; g = 60; b = 60; } /* T - red */
105 + case 2: { r = 60; g = 120; b = 255; } /* CT - blue */
106 + default: { r = 200; g = 200; b = 200; }
107 + }
108 +
109 + new Float:color[3]
110 + color[0] = float(r)
111 + color[1] = float(g)
112 + color[2] = float(b)
113 +
114 + set_es(es, ES_RenderMode, kRenderNormal)
115 + set_es(es, ES_RenderFx, kRenderFxGlowShell)
116 + set_es(es, ES_RenderColor, color)
117 + set_es(es, ES_RenderAmt, 30.0)
118 +
119 + return FMRES_HANDLED
120 +}
+37 -0 csb.json A
@@ -0,0 +1,37 @@
1 +{
2 + "name": "CSB Admin ESP",
3 + "category": "admin",
4 + "tags": "esp, glow, spectator",
5 + "image": "",
6 + "original_author": "",
7 + "original_url": "",
8 + "license": "GPL-3.0",
9 + "title": "CSB Admin ESP",
10 + "short_desc": "Wallhack-style glow on players for admins only, injected per-client in FM_AddToFullPack so normal players see nothing.",
11 + "version": "1.0.0",
12 + "amxx_min": "1.9",
13 + "amxx_compile_default": "1.9",
14 + "rehlds_ok": true,
15 + "hlds_ok": true,
16 + "regamedll_required": false,
17 + "metamod_flavor": "any",
18 + "reapi_required": false,
19 + "modules": "fakemeta",
20 + "install_notes": "1. Enable the fakemeta module in addons/amxmodx/configs/modules.ini\n2. Put csb_admin_esp.amxx in addons/amxmodx/plugins/ and add it to plugins.ini\n3. Change map",
21 + "known_conflicts": "Other plugins that set player render properties in FM_AddToFullPack or via set_user_rendering can fight over the glow shell.",
22 + "cvars": [
23 + {
24 + "name": "csb_esp_enabled",
25 + "default": "1",
26 + "description": "Enable or disable the amx_esp command."
27 + }
28 + ],
29 + "commands": [
30 + {
31 + "name": "amx_esp",
32 + "access": "u (ADMIN_CFG)",
33 + "description": "amx_esp [0|1] - toggle wallhack glow ESP for yourself."
34 + }
35 + ],
36 + "main": "addons/amxmodx/scripting/csb_admin_esp.sma"
37 +}
0 38