Valid Chars - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Valid Chars (
/showthread.php?tid=133016)
Valid Chars -
Brawl - 10.03.2010
Hi. I have this code for my rename command
Код:
stock IsValidChar(character[])
{
for(new i; i < strlen(character); i++)
{
if(character[i] < 36 || character[i] > 36 && character[i] < 40 ||
character[i] > 41 && character[i] < 46 || character[i] > 46 &&
character[i] < 48 || character[i] > 57 && character[i] < 64 ||
character[i] > 91 && character[i] < 91 || character[i] > 93 &&
character[i] < 93 || character[i] > 95 && character[i] < 95 ||
character[i] > 95 && character[i] < 97 || character[i] > 122) return 0;
}
return 1;
}
it works all fine but the = char is not in this code... how to enable the = char in this code ?
Re: Valid Chars -
pen_theGun - 10.03.2010
pawn Код:
stock IsValidChar(character[])
{
for(new i; i < strlen(character); i++)
{
if(character[i] < 36 || character[i] > 36 && character[i] < 40 ||
character[i] > 41 && character[i] < 46 || character[i] > 46 &&
character[i] < 48 || character[i] > 57 && character[i] < 64 ||
character[i] > 91 && character[i] < 91 || character[i] > 93 &&
character[i] < 93 || character[i] > 95 && character[i] < 95 ||
character[i] > 95 && character[i] < 97 || character[i] > 122 || character[i] == '=') return 0;
}
return 1;
}
Re: Valid Chars -
Brawl - 11.03.2010
doesnt work :S
Re: Valid Chars -
pen_theGun - 11.03.2010
weird, I've tested it and it had worked: |
Re: Valid Chars -
Brawl - 27.03.2010
i need still help ...