Any way to make this faster?
#1

So this is my Range Banning code:
Код:
stock BanRange(l1)
{
    printf("[BanRange] Banning Range Starting from: %d", l1);
	new docmd[128], ipttl[128];
	for(new i=1;i<256;i++)
	{
		for(new b=0;b<256;b++)
		{
		    for(new c=0;c<256;c++)
		    {
			    format(ipttl, sizeof(ipttl), "%d.%d.%d.%d", l1, i, b, c);
			    format(docmd, 128, "banip %s", ipttl);
			    SendRconCommand(docmd);
			}
		}
	}
	return 1;
}
Its slow and it would take hours to ban one range..
Anyway to make it more faster? or optimize it?
Reply


Messages In This Thread
Any way to make this faster? - by MafiaOink - 26.11.2015, 05:56
Re: Any way to make this faster? - by jamesbond007 - 26.11.2015, 06:06
Re: Any way to make this faster? - by iKarim - 26.11.2015, 06:13
Re: Any way to make this faster? - by cawfee - 26.11.2015, 06:15
Re: Any way to make this faster? - by MafiaOink - 26.11.2015, 06:26
Re: Any way to make this faster? - by iKarim - 26.11.2015, 06:31
Re: Any way to make this faster? - by cawfee - 26.11.2015, 06:35
Re: Any way to make this faster? - by iKarim - 26.11.2015, 06:38
Re: Any way to make this faster? - by Vince - 26.11.2015, 10:42
Re: Any way to make this faster? - by Jefff - 26.11.2015, 14:47

Forum Jump:


Users browsing this thread: 1 Guest(s)