10.04.2015, 10:25
pawn Код:
#include <sscanf2> //At the top of the script.
CMD:sms(playerid, params[])
{
new Number, Message[10];
if(sscanf(params, "is[10]", Number, Message))
if(isnull(params)) SendClientMessage(playerid, -1, "USAGE: /sms <number> <message>");
if(!strcmp(Message, "yes", true, 3))
{
SendClientMessage(playerid,-1 , " Great! We have a Job for you , come to the Job house. ");
SetPlayerCheckpoint(playerid , 2351.8401,-1170.1030,28.0473 , 2.0);
return 1;
}
if(!strcmp(Message, "no", true, 2))
{
SendClientMessage(playerid, -1 , " Sorry! If you need the job anytime , type /sms redo");
return 1;
}
if(!strcmp(Message, "redo", true, 4))
{
SendClientMessage(playerid, -1, "USAGE: /sms <number> <message>");
return 1;
}
if(IsPlayerInRangeOfPoint(playerid,2,2345.8508,-1184.4211,1027.9766))
{
ShowPlayerDialog(playerid, DIALOG_JOB, DIALOG_STYLE_LIST, "Job", "Public Driver Service", "Close", "");
return 1;
}
return 1;
}