05.07.2009, 18:25
ok I have a problem. Client Text doesn't send for a player at a point, dunno what's wrong ;/
here's the code. I've comented the lines where it doesn't send it.
What the heck is wrong? This is not the first time it doesn't print the way it should ;//
here's the code. I've comented the lines where it doesn't send it.
pawn Код:
if(regStep[playerid] > 0)
{
switch(regStep[playerid])
{
case 1:
{
switch(text[0])
{
case 'm':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Ok, so you're a guy. How old are you? \n (input age 16-72) ");
PlayerInfo[playerid][pSex] = 1;
regStep[playerid] = 2;
}
case 'f':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Ok, so you're a girl. How old are you? \n (input age 16-72) ");
PlayerInfo[playerid][pSex] = 2;
regStep[playerid] = 2;
}
default:
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Are you a guy or a girl? (input [m]ale or [f]emale) ");
}
}
}
case 2:
{
switch(strval(text))
{
case 16 .. 72:
{
new tmp_text[128];
format(tmp_text, 128, "* [SYSTEM] I see, so you're %d years old. Where do you come from? \n([e]urope, [a]sia or [u]sa) ", strval(text));
SendClientMessage(playerid, COLOR_LIGHTBLUE, tmp_text);
PlayerInfo[playerid][pAge] = strval(text);
regStep[playerid] = 3;
}
default:
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] How old are you? (input age 16-72) ");
}
}
}
case 3:
{
switch(text[0])
{
case 'e':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Ok, so you're from europe. What tan do you have? \n([l]ight, [m]edium or [d]ark) ");
PlayerInfo[playerid][pOrigin] = 1;
regStep[playerid] = 4;
}
case 'a':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Ok, so you're from asia. What tan do you have? \n([l]ight, [m]edium or [d]ark) ");
PlayerInfo[playerid][pOrigin] = 2;
regStep[playerid] = 4;
}
case 'u':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Ok, so you're from the USA. What tan do you have? \n([l]ight, [m]edium or [d]ark) ");
PlayerInfo[playerid][pOrigin] = 3;
regStep[playerid] = 4;
}
default:
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Where do you come from? \n([e]urope, [a]sia or [u]sa) ");
}
}
}
case 4:
{
switch(text[0])
{
/* case 'l':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] Ahh, you're pale, huh? Ok... What accent do you have? \n([i]talian, [a]merican, [b]ritish, [g]erman, [r]ussian, [j]apanese or [c]hinese) ");
PlayerInfo[playerid][pTan] = 1;
SkinSlot[playerid][0] = rand_skins[PlayerInfo[playerid][pSex]-1][PlayerInfo[playerid][pTan]-1]
SkinSlot[playerid][1] = rand_swimwear[PlayerInfo[playerid][pSex]-1][PlayerInfo[playerid][pTan]-1];
SkinWearing[playerid] = 0;
regStep[playerid] = 5;
}
case 'm':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] You're so tanned it's almost criminal... What your accent? \n([i]talian, [a]merican, [b]ritish, [g]erman, [r]ussian, [j]apanese or [c]hinese) ");
PlayerInfo[playerid][pTan] = 2;
SkinSlot[playerid][0] = rand_skins[PlayerInfo[playerid][pSex]-1][PlayerInfo[playerid][pTan]-1];
SkinSlot[playerid][1] = rand_swimwear[PlayerInfo[playerid][pSex]-1][PlayerInfo[playerid][pTan]-1];
SkinWearing[playerid] = 0;
regStep[playerid] = 5;
}
case 'd':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you're black, huh? Ok... What accent do you have? \n([i]talian, [a]merican, [b]ritish, [g]erman, [r]ussian, [j]apanese or [c]hinese) ");
PlayerInfo[playerid][pTan] = 3;
SkinSlot[playerid][0] = rand_skins[PlayerInfo[playerid][pSex]-1][PlayerInfo[playerid][pTan]-1];
SkinSlot[playerid][1] = rand_swimwear[PlayerInfo[playerid][pSex]-1][PlayerInfo[playerid][pTan]-1];
SkinWearing[playerid] = 0;
regStep[playerid] = 5;
}*/
default:
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] What tan do you have? \n([l]ight, [m]edium or [d]ark) ");
}
}
}
case 5:
{
switch(text[0])
{
case 'i':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you have italian accent. Great... ");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "* [TUT] Tutoria will be initiated in 3 seconds. Please pay attention. ");
PlayerInfo[playerid][pAccent] = 1;
regStep[playerid] = 100;
}
case 'a':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you have american accent. Great... ");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "* [TUT] Tutoria will be initiated in 3 seconds. Please pay attention. ");
PlayerInfo[playerid][pAccent] = 2;
regStep[playerid] = 100;
}
case 'b':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you have british accent. Great... ");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "* [TUT] Tutoria will be initiated in 3 seconds. Please pay attention. ");
PlayerInfo[playerid][pAccent] = 3;
regStep[playerid] = 100;
}
case 'g':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you have german accent. Great... ");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "* [TUT] Tutoria will be initiated in 3 seconds. Please pay attention. ");
PlayerInfo[playerid][pAccent] = 4;
regStep[playerid] = 100;
}
case 'r':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you have russian accent. Great... ");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "* [TUT] Tutoria will be initiated in 3 seconds. Please pay attention. ");
PlayerInfo[playerid][pAccent] = 5;
regStep[playerid] = 100;
}
case 'j':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you have japanese accent. Great... ");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "* [TUT] Tutoria will be initiated in 3 seconds. Please pay attention. ");
PlayerInfo[playerid][pAccent] = 6;
regStep[playerid] = 100;
}
case 'c':
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] So you have chinese accent. Great... ");
SendClientMessage(playerid, COLOR_LIGHTGREEN, "* [TUT] Tutoria will be initiated in 3 seconds. Please pay attention. ");
PlayerInfo[playerid][pAccent] = 7;
regStep[playerid] = 100;
}
default:
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* [SYSTEM] What accent do you have? \n([i]talian, [a]merican, [b]ritish, [g]erman, [r]ussian, [j]apanese or [c]hinese) ");
}
}
}
}
return 0;
}