wS выкладывал...
Код
public OnPluginStart()
{
////////////////////////////////////////////////////////
// на каком должен работать
new const String:IP_PORT[] = "1.2.3.4:27015";
/////////
new Handle:h_IP = FindConVar("hostip");
new Handle:h_PORT = FindConVar("hostport");
if (h_IP == INVALID_HANDLE || h_PORT == INVALID_HANDLE)
{
SetFailState("h_IP || h_PORT == INVALID_HANDLE");
return;
}
new hostip = GetConVarInt(h_IP);
new ip1 = hostip >>> 24 & 255;
new ip2 = hostip >>> 16 & 255;
new ip3 = hostip >>> 8 & 255;
new ip4 = hostip & 255;
decl String:current_ip_port[75];
Format(current_ip_port, 75, "%d.%d.%d.%d:%d", ip1, ip2, ip3, ip4, GetConVarInt(h_PORT));
if (strcmp(current_ip_port, IP_PORT, false) != 0)
{
SetFailState("\nYour server: %s. Plugin for: %s", current_ip_port, IP_PORT);
}
////////////////////////////////////////////////////////
}