/sms command bugged
#1

Quote:

if(strcmp(cmd, "/sms", true) == 0)
{
if(gPlayerLogged[playerid] != 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREY, "USAGE: /sms [phonenumber]");
SendClientMessage(playerid, COLOR_GREY, "USAGE: /sms 411 (for a list for short numbers)");
return 1;
}
new phonenumb = strval(tmp);
if(phonenumb == 311)
{
if(PlayerInfo[playerid][pJob] == 0)
{
tmp = strtok(cmdtext, idx);
if( !strcmp( tmp, "", true ) )
{
SendClientMessage(playerid, COLOR_PINK, "[ ! ] [SMS] Great, I have a job for you! Come to the job house.");
SendClientMessage(playerid, COLOR_WHITE, "[ ! ] [HINT] Follow the red maker to the job house!");
SetPlayerCheckpoint(playerid, 2352.0979,-1167.8988,27.7965, 3.0);
}
if( !strcmp( tmp, "mechanic", true ) )
{
SendClientMessage(playerid, COLOR_PINK, "[ ! ] [SMS] Great, you have been accepted into your choosen job!");
SendClientMessage(playerid, COLOR_WHITE, "[ ! ] [HINT] Follow the red maker to your new job!");
}
}
else if(PlayerInfo[playerid][pJob] != 0)
{
SendClientMessage(playerid, COLOR_PINK, "[ ! ] [SMS] Sorry , you already have a job!");
}
}
return 1;
}
else
{
SendClientMessage(playerid, COLOR_ERROR, "[ ! ] You are not logged in!");
return 0;
}
}

But when i type /sms 311 it shows both when i type in /sms 311 mechanic it just shows mechanic.
Reply


Messages In This Thread
/sms command bugged - by bubka3 - 05.09.2009, 03:36
Re: /sms command bugged - by TMasters - 05.09.2009, 09:11
Re: /sms command bugged - by Darkstar94 - 05.09.2009, 09:48
Re: /sms command bugged - by MenaceX^ - 05.09.2009, 12:26
Re: /sms command bugged - by bubka3 - 05.09.2009, 15:02
Re: /sms command bugged - by Lonka - 05.09.2009, 18:19
Re: /sms command bugged - by RaFsTar - 05.09.2009, 18:24

Forum Jump:


Users browsing this thread: 1 Guest(s)