HLMOD.HU Forrás Megtekintés
- www.hlmod.hu/* AMXX Mod script.
*
*
* Client List v.1.1 by KoMeHDaHT.
*
*
* Description:
* Prints in console numbers and names of the players with their IP-adress, Steam-ID, current ping.
* Players may get the client list even in spectator mode.
*
* CVARS:
* No CVars for this plugin.
*
*/
#include <amxmodx>
#include <amxmisc>
public plugin_init()
{
register_plugin("Client List", "1.1", "KoMeHDaHT")
register_concmd("amx_showlist", "client_list", -1, "- Gets client list")
}
public client_list(id,level,cid)
{
if (!cmd_access(id,level,cid,1))
return PLUGIN_HANDLED
new authid[35], user_ip[32], name[32], user_ping, user_loss, text[64], bot_ping[32]
new maxplayers = get_maxplayers()
console_print(id, "Client List:^n# NEV IP AUTHID PING")
for(new j=1; j <= maxplayers; j++)
{
if(is_user_connected(j))
{
get_user_name(j, name, 31)
get_user_ip(j, user_ip, 31, 1)
get_user_authid(j, authid, 34)
get_user_ping(j, user_ping, user_loss)
if(is_user_bot(j))
{
user_ip = "SERVER_IP_LAN"
authid = "NONE"
bot_ping = "BOT"
format(text, 63, "%2d %-18s %-14s %-10s %-8d", j, name, user_ip, authid, bot_ping)
}
else
{
format(text, 63, "%2d %-18s %-14s %-10s %-8d", j, name, user_ip, authid, user_ping)
}
console_print(id, text)
}
}
return PLUGIN_CONTINUE
}