View Single Post
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