There are many "show ip" plugins, but none has what I need. So here is a new one.
Features:
1) Print a list of all connected players.
- client & server console commands
- amx_ip
- amxip
- show_ip
- showip
- clcmd
- prints also SPECTATOR and UNASSIGNED
- annonymization of admins:
- If a player invokes amx_ip, all connected admins get a different IP and steamID. Both are derived from 'id' and random values created on plugin_init.
- IP is currently set in a dynamic range 78.99.*.* (TODO : multiple dynamic ranges.)
- Admins see each others real IPs and SteamIDs.
Code:
[IP] printing all players IPs
[IP] 1: 'Player1' (CT) -- 72.109.74.152:27005 [STEAM_0:0:12423349]
[IP] 2: 'Player2' (UNASSIGNED) -- 87.216.155.23:27005 [STEAM_0:0:1622349]
[IP] 3: 'Player3' (TERRORIST) -- 73.136.133.136:28305 [STEAM_0:0:1654741]
[IP] 4: 'HLTV-Guard' (SPECTATOR) -- 42.230.284.36:37017 [HLTV]
(TODO: 2-letter assigment descriptions - CT, TE, UN, SP.)
2) printing IP and SteamID on player connect/disconnect to admins.
Code:
[IP] 'Player1' Connected -- 72.109.74.152:27005 [STEAM_0:0:12423349]
[IP] 'Player1' Disconnected -- 72.109.74.152:27005 [STEAM_0:0:12423349]
(admin annonymization does not work for connects and disconnects! Connect pritns are meant only for admins.)
CVARS:
//cvar amx_ip_con_print = [0|1]
// default 1
// 0 - do not print (dis)connected players in admin consoles
// 1 - print (dis)connected players in admin consoles
//cvar amx_ip_srv_print = [0|1]
// default 1
// 0 - do not print (dis)connected players in server console
// 1 - print (dis)connected players in server console
CONSTATNTS:
#define IP_LVL ADMIN_ALL
level at which are amx_ip commands availiable
#define IP_CON_PRINT_LVL ADMIN_KICK
level at which are connect and disconnect messages availiable.
(plugin is already on multiple servers and working flawlessly.)