IsNull change
#1

Is there any way to replace IsNull with something? and how..

Код:
CMD:boost(playerid, params[])
{
	if(isnull(params)) return SendClientMessage(playerid, COLOR_YELLOW, "Usage: /boost [me/other]");
	{
		    if(!strcmp(params, "me", true))
		    {
				SetPlayerHealth(playerid, 100);
			}
			if(!strcmp(params, "other", true))
			{
				
			}
	return 1;
}
Reply
#2

pawn Код:
if (strlen(params)==0) return SendClientMessage(playerid, COLOR_YELLOW, "Usage: /boost [me/other]");
Is this the kind of thing you mean?
Reply
#3

Well its good but is it possible to use like Sscanf or such?
Reply
#4

pawn Код:
if(sscanf(params, "s[8]", params)) return SendClientMessage(playerid, COLOR_YELLOW, "Usage: /boost [me/other]");
Reply
#5

Thanks!
Reply
#6

My pleasure. Hope it works as you wanted.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)