Prodvigat server

Initial release 1.0.0

Browse Source
1.0.0 - Initial release.
Daemon666 committed commit 9eec67bbebcb9dceac5ee29eb24c8163a07ad16e
4 changed files with 145 additions and 0 deletions
+3 -0 CHANGELOG.md A
@@ -0,0 +1,3 @@
1 +## 1.0.0 (2026-05-24)
2 +
3 +1.0.0 - Initial release.
+1 -0 README.md A
@@ -0,0 +1 @@
1 +<p><strong>CSB Anti Ghosting</strong> closes the everyday ways a dead player feeds intel to the living. Chat from a dead player is intercepted and delivered only to other dead and spectating players, so it can never leak to someone still in the round. At the start of each round the plugin sets <code>mp_forcecamera</code> to your configured value, pinning spectators to a limited camera instead of free-look on enemies, and forces <code>sv_alltalk</code> off so voice cannot cross the alive/dead line while the round is running.</p><h2>Features</h2><ul><li>Dead say / say_team is routed to dead players only and blocked from the living.</li><li>Command-style messages (<code>/</code> or <code>!</code>) are passed through so other plugins still work.</li><li><code>mp_forcecamera</code> re-applied each round from <code>csb_gh_forcecamera</code>.</li><li><code>sv_alltalk</code> forced off at round start when <code>csb_gh_alltalk</code> is on.</li><li>Every rule has its own cvar so you can enable only what you need.</li></ul><h2>Installation</h2><ol><li>Compile <code>csb_anti_ghosting.sma</code> and copy it to <code>addons/amxmodx/plugins/</code>.</li><li>Add it to <code>plugins.ini</code> and change the map.</li></ol><p>No extra modules are required. If you run a plugin that already manages dead chat, disable one of the two with <code>csb_gh_deadchat 0</code>.</p>
+95 -0 addons/amxmodx/scripting/csb_anti_ghosting.sma A
@@ -0,0 +1,95 @@
1 +/*
2 + * CSB Anti Ghosting
3 + * Copyright (C) 2026 counter-strike-boost.com
4 + *
5 + * Closes the common ghosting channels on a live round: dead players' chat is
6 + * routed only to other dead players (never leaked to the living), spectators
7 + * are pinned to a limited camera mode via mp_forcecamera, and sv_alltalk is
8 + * forced off while a round is running. All values are cvar-controlled.
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 +
20 +new const PLUGIN[] = "CSB Anti Ghosting"
21 +new const VERSION[] = "1.0.0"
22 +new const AUTHOR[] = "counter-strike-boost.com"
23 +
24 +new g_pEnabled, g_pDeadChat, g_pForceCamVal, g_pAllTalk
25 +
26 +new g_pForceCamera, g_pSvAllTalk
27 +
28 +public plugin_init()
29 +{
30 + register_plugin(PLUGIN, VERSION, AUTHOR)
31 +
32 + g_pEnabled = register_cvar("csb_gh_enabled", "1")
33 + g_pDeadChat = register_cvar("csb_gh_deadchat", "1")
34 + g_pForceCamVal = register_cvar("csb_gh_forcecamera", "1")
35 + g_pAllTalk = register_cvar("csb_gh_alltalk", "1")
36 +
37 + register_clcmd("say", "cmdSay")
38 + register_clcmd("say_team", "cmdSay")
39 +
40 + register_logevent("evRoundStart", 2, "1=Round_Start")
41 +
42 + g_pForceCamera = get_cvar_pointer("mp_forcecamera")
43 + g_pSvAllTalk = get_cvar_pointer("sv_alltalk")
44 +}
45 +
46 +public evRoundStart()
47 +{
48 + if (!get_pcvar_num(g_pEnabled))
49 + return
50 +
51 + if (g_pForceCamera)
52 + set_pcvar_num(g_pForceCamera, get_pcvar_num(g_pForceCamVal))
53 +
54 + if (get_pcvar_num(g_pAllTalk) && g_pSvAllTalk)
55 + set_pcvar_num(g_pSvAllTalk, 0)
56 +}
57 +
58 +public cmdSay(id)
59 +{
60 + if (!get_pcvar_num(g_pEnabled) || !get_pcvar_num(g_pDeadChat))
61 + return PLUGIN_CONTINUE
62 +
63 + /* living players use normal chat */
64 + if (is_user_alive(id))
65 + return PLUGIN_CONTINUE
66 +
67 + new said[128]
68 + read_args(said, charsmax(said))
69 + remove_quotes(said)
70 + trim(said)
71 +
72 + if (!said[0])
73 + return PLUGIN_HANDLED
74 +
75 + /* let command-style messages fall through to their own plugins */
76 + if (said[0] == '/' || said[0] == '!')
77 + return PLUGIN_CONTINUE
78 +
79 + new name[32]
80 + get_user_name(id, name, charsmax(name))
81 +
82 + /* deliver only to other dead / spectating players */
83 + new players[32], num, pid
84 + get_players(players, num)
85 +
86 + for (new i = 0; i < num; i++)
87 + {
88 + pid = players[i]
89 +
90 + if (!is_user_alive(pid))
91 + client_print(pid, print_chat, "*DEAD* %s : %s", name, said)
92 + }
93 +
94 + return PLUGIN_HANDLED
95 +}
+46 -0 csb.json A
@@ -0,0 +1,46 @@
1 +{
2 + "name": "CSB Anti Ghosting",
3 + "category": "anticheat",
4 + "tags": "ghosting, dead chat, spectator",
5 + "image": "",
6 + "original_author": "",
7 + "original_url": "",
8 + "license": "GPL-3.0",
9 + "title": "CSB Anti Ghosting",
10 + "short_desc": "Routes dead chat to dead players only, pins spectators to a limited camera via mp_forcecamera, and forces sv_alltalk off while a round is live.",
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": "",
20 + "install_notes": "1. Put csb_anti_ghosting.amxx in addons/amxmodx/plugins/\n2. Add it to addons/amxmodx/configs/plugins.ini\n3. Change map",
21 + "known_conflicts": "Other dead-chat or all-talk managers will conflict; run only one.",
22 + "cvars": [
23 + {
24 + "name": "csb_gh_enabled",
25 + "default": "1",
26 + "description": "Master switch for all anti-ghosting rules."
27 + },
28 + {
29 + "name": "csb_gh_deadchat",
30 + "default": "1",
31 + "description": "Route dead chat to dead players only."
32 + },
33 + {
34 + "name": "csb_gh_forcecamera",
35 + "default": "1",
36 + "description": "Value applied to mp_forcecamera at round start."
37 + },
38 + {
39 + "name": "csb_gh_alltalk",
40 + "default": "1",
41 + "description": "Force sv_alltalk off at round start."
42 + }
43 + ],
44 + "commands": [],
45 + "main": "addons/amxmodx/scripting/csb_anti_ghosting.sma"
46 +}
0 47