[Include] [I-ZCMD]Improved ZCMD - Fastest Command Processor
#24

Quote:
Originally Posted by ipsNan
Посмотреть сообщение
Your code is missing the flag #define ICMD_CALLBACK, to use OnCommandCalled, then you don't need to create this forward again, it already exists on inc file.
Yea, I fixed it later :P

By the way, I made a pull request at github for ICMD!!
-------------------------------------------------------------------------------------
I-ZCMD new update is 3x faster than ZCMD,5x faster than y_commands and slightly faster than ICMD

I-ZCMD (v0.2) is 2.79 times faster than ZCMD
I-ZCMD (v0.2) is 5.06 times faster than y_commands
I-ZCMD (v0.2) is 1.35 times faster than ICMD

Speed Test Code for ICMD Benchmark
Код:
#include <a_samp>


#define IZCMD

#if defined ICMD

#define ICMD_CALLBACK
#include <icmd>

public OnCommandCalled(playerid, cmd[])
{
	if (!cmd_exists(cmd))
	{
	    return ICMD_ERROR;
	}
	return ICMD_OKAY;
}

public Listeners(playerid, params[])
{
	get_cmd_params(mycommand)
	{
		return 1;
	}
	return 0;
}

#endif

#if defined IZCMD
	#include <XCMD>
	COMMAND:mycommand(playerid,params[])
	{
		return CMD_SUCCESS;
	}
	public OnPlayerCommandReceived(playerid,cmdtext[])
	{
		return 1;
	}
	public OnPlayerCommandPerformed(playerid,cmdtext[], success)
	{
		return success;
	}
#endif

main ()
{
	new a = GetTickCount();
	for(new i = 0;i < 1000000;i++)
		CallLocalFunction("OnPlayerCommandText","is",0,"/mycommand someshit");
	new b = GetTickCount();
	printf("%d",b-a);
}
Reply


Messages In This Thread
[I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 01.06.2015, 07:02
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by SickAttack - 01.06.2015, 07:19
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Manyula - 01.06.2015, 09:18
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by HydraHumza - 01.06.2015, 09:36
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by SickAttack - 01.06.2015, 14:51
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by PT - 01.06.2015, 17:26
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Pottus - 01.06.2015, 18:06
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by hamzajaved780 - 01.06.2015, 18:37
AW: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Mellnik - 01.06.2015, 19:05
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Pottus - 01.06.2015, 19:39
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by PeterJane - 06.06.2015, 11:01
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by admantis - 06.06.2015, 18:12
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Ritzy2K - 06.06.2015, 18:34
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 07.06.2015, 02:46
Respuesta: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Zume - 07.06.2015, 22:01
Re: Respuesta: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by SickAttack - 07.06.2015, 22:10
Re: Respuesta: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 08.06.2015, 15:10
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Pottus - 14.06.2015, 04:15
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by n0minal - 14.06.2015, 04:55
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 14.06.2015, 05:47
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by DRIFT_HUNTER - 14.06.2015, 05:54
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by WLSF - 14.06.2015, 10:17
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by RaeF - 14.06.2015, 10:31
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 14.06.2015, 15:06
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Crayder - 25.03.2016, 07:32
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 25.03.2016, 09:22
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Kar - 25.03.2016, 09:35
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 25.03.2016, 09:50
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Zorono - 16.06.2016, 19:52
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 06.07.2016, 13:42
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Untonyst - 14.07.2016, 07:54
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 15.07.2016, 13:36
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Arithmetic - 15.07.2016, 18:13
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 15.07.2016, 18:20
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 01.08.2016, 14:37
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Gammix - 01.08.2016, 15:35
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yashas - 02.08.2016, 07:20
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Romz - 19.10.2016, 20:18
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Yousha - 19.10.2016, 20:31
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Crayder - 20.10.2016, 04:15
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Command - 30.04.2017, 16:19
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by AbyssMorgan - 30.04.2017, 16:23
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Command - 30.04.2017, 16:49
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by feheristi97 - 23.07.2017, 16:23
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by Deken - 28.12.2018, 19:01
Re: [I-ZCMD]Improved ZCMD - Fastest Command Processor - by cuber - 28.12.2018, 20:12

Forum Jump:


Users browsing this thread: 1 Guest(s)