22.02.2009, 08:46
You can use this function to return a random letter:
pawn Код:
stock randomchar()
{
new rand; rand = random(26);
new chr[200];
switch(rand)
{
case 0: format(chr,200,"%s","A");
case 1: format(chr,200,"%s","B");
case 2: format(chr,200,"%s","C");
case 3: format(chr,200,"%s","D");
case 4: format(chr,200,"%s","E");
case 5: format(chr,200,"%s","F");
case 6: format(chr,200,"%s","G");
case 7: format(chr,200,"%s","H");
case 8: format(chr,200,"%s","I");
case 9: format(chr,200,"%s","J");
case 10: format(chr,200,"%s","K");
case 11: format(chr,200,"%s","L");
case 12: format(chr,200,"%s","M");
case 13: format(chr,200,"%s","N");
case 14: format(chr,200,"%s","O");
case 15: format(chr,200,"%s","P");
case 16: format(chr,200,"%s","Q");
case 17: format(chr,200,"%s","R");
case 18: format(chr,200,"%s","S");
case 19: format(chr,200,"%s","T");
case 20: format(chr,200,"%s","U");
case 21: format(chr,200,"%s","V");
case 22: format(chr,200,"%s","W");
case 23: format(chr,200,"%s","X");
case 24: format(chr,200,"%s","Y");
case 25: format(chr,200,"%s","Z");
}
return chr;
}