Raised This Month: $51 Target: $400
 12% 

Radio Gag System


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   Admin Commands       
CT_Spawn
Junior Member
Join Date: Apr 2024
Old 04-22-2024 , 11:40   Radio Gag System
Reply With Quote #1

Radio Gag System

Description:
  • This plugin is to silence annoying people who spam radio messages (note that the plugin does not depend on a database, it only works once per map)

Commands Usage:
  • amx_rgag <nick | authid | #userid> (for gag radio spammer by name or steamid or 'userid but use # before userid' )
  • amx_ip_rgag <ip> (for gag radio spammer by ip)
  • amx_unrgag <nick | authid | #userid> (for ungag radio user by name or steamid or 'userid but use # before userid' )
  • amx_ip_unrgag <ip> (for ungag radio user by ip)
Video:


Screenshot:


Attached Thumbnails
Click image for larger version

Name:	screenshot.jpg
Views:	33
Size:	49.0 KB
ID:	204162  
Attached Files
File Type: sma Get Plugin or Get Source (radio_gag.sma - 35 views - 7.5 KB)
File Type: zip cstrike (addons and sounds).zip (27.0 KB, 21 views)

Last edited by CT_Spawn; 04-22-2024 at 11:52.
CT_Spawn is offline
bigdaddy424
Senior Member
Join Date: Oct 2021
Location: Jupiter
Old 04-22-2024 , 23:05   Re: Radio Gag System
Reply With Quote #2

good idea but poorly executed
very hardcoded and i recommend browsing the web api and in this case reading about Trie array...
https://www.amxmodx.org/api
https://forums.alliedmods.net/showthread.php?t=201872
and since youre blocking `STEAM_ID_LAN` and `localhost` where this only happens when youre running a lan server than theres a function that detects just that `is_dedicated_server`
__________________
bigdaddy424 is offline
CT_Spawn
Junior Member
Join Date: Apr 2024
Old 04-23-2024 , 15:38   Re: Radio Gag System
Reply With Quote #3

Quote:
Originally Posted by bigdaddy424 View Post
good idea but poorly executed
very hardcoded and i recommend browsing the web api and in this case reading about Trie array...
https://www.amxmodx.org/api
https://forums.alliedmods.net/showthread.php?t=201872
and since youre blocking `STEAM_ID_LAN` and `localhost` where this only happens when youre running a lan server than theres a function that detects just that `is_dedicated_server`
Thanks for your comment and ideas
But regarding dynamic arrays
I actually intended to work with it, but I changed my mind and put static arrays
Because I didn't trust the plugin_end function
And you know that the server works 24/24 and 7/7
If there is an error in the plugin_end function, the memory will fill up with arrays. This will do more harm than good.

That's why I decided to put static

Detecting the IP using the is_dedicated_server function is a good idea, but I think I will not update it for this reason only.

As for the percentage of STEAM_ID_LAN and others

You are completely wrong, because I have seen cases of some players entering the server with these IDs

Regarding the latter, above all this, this code is a quote from the official admincmd.sma
CT_Spawn is offline
bigdaddy424
Senior Member
Join Date: Oct 2021
Location: Jupiter
Old 04-23-2024 , 21:48   Re: Radio Gag System
Reply With Quote #4

in order to occupy around 1mb of ram memory you need an array of 20-30k entries so its safe to say that memory isnt an excuse not that it ever has been something to consider especially working on mods for games.
the last major update admincmd.sma file has had was when 1.75 was introduced according to some sources and this was in 2007 or 2008. since then there've been minor edits and additions. theres no such cases as players having STEAM_ID_LAN on multiplayer, unless you account for reunion or dproto which is against ToS.
__________________
bigdaddy424 is offline
CT_Spawn
Junior Member
Join Date: Apr 2024
Old 04-24-2024 , 09:06   Re: Radio Gag System
Reply With Quote #5

Quote:
Originally Posted by bigdaddy424 View Post
in order to occupy around 1mb of ram memory you need an array of 20-30k entries so its safe to say that memory isnt an excuse not that it ever has been something to consider especially working on mods for games.
the last major update admincmd.sma file has had was when 1.75 was introduced according to some sources and this was in 2007 or 2008. since then there've been minor edits and additions. theres no such cases as players having STEAM_ID_LAN on multiplayer, unless you account for reunion or dproto which is against ToS.


image link
You get this picture. Don't deny it, I saw it myself, my friend

I did not understand what you meant by dproto, but if you meant that the server targets “non steam player”, the server definitely targets them. Who is the idiot who opens a server and does not put dproto in it?
CT_Spawn is offline
WATCH_D0GS UNITED
Senior Member
Join Date: Jan 2023
Old 04-24-2024 , 12:33   Re: Radio Gag System
Reply With Quote #6

PHP Code:
new array_cells[30000
32-bit system:

30000 * 4 = 120000

120000 Bytes -> 0.114 Megabytes

64-bit system:

0.228 Megabytes
__________________
💻Know Our New Blog👄
🔗tube2downs.blogspot.com
WATCH_D0GS UNITED is offline
Jhob94
AMX Mod X Donor
Join Date: Jul 2012
Old 04-24-2024 , 12:39   Re: Radio Gag System
Reply With Quote #7

Quote:
Originally Posted by CT_Spawn View Post


image link
You get this picture. Don't deny it, I saw it myself, my friend

I did not understand what you meant by dproto, but if you meant that the server targets “non steam player”, the server definitely targets them. Who is the idiot who opens a server and does not put dproto in it?
First you have no idea what you are doing and you should consider learn more before posting plugins.
Second you should read rules, we do not support non-steam. If people use, we don’t care, but we do not support it so don’t say that kind of things.
Third, no one is idiot for wanting steam only servers, they are cleaner.
__________________
Jhob94 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 15:34.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode