Compare Name with part of an enum
#6

If any of the variables are blank, it will say that they matched.

pawn Code:
strsame(firstString[], secondString[], bool: caseSensitive = false)
{
    if(isnull(firstString) || isnull(secondString)) return 0;
    return !strcmp(firstString, secondString, caseSensitive);
}
Requires an isnull function which ZCMD automatically adds to your script. Usage:

pawn Code:
if(strsame("Hello", "Hello"))
That will return true.
Reply


Messages In This Thread
Compare Name with part of an enum - by dusk - 31.03.2013, 13:05
Re: Compare Name with part of an enum - by Neil. - 31.03.2013, 13:12
Re: Compare Name with part of an enum - by Riddick94 - 31.03.2013, 13:24
Re: Compare Name with part of an enum - by Neil. - 31.03.2013, 13:29
Re: Compare Name with part of an enum - by dusk - 31.03.2013, 14:06
Re: Compare Name with part of an enum - by SuperViper - 31.03.2013, 14:41
Re: Compare Name with part of an enum - by dusk - 31.03.2013, 14:48

Forum Jump:


Users browsing this thread: 3 Guest(s)