05.07.2009, 12:10
Hey guyz ,
for this two commands it says unknown command :
but all my other commands work!
for this two commands it says unknown command :
Код:
if (strcmp("/yes", cmdtext, true, 10) == 0)
{
if(porter[player[playerid]] == -1)
{
SendClientMessage(player[playerid],0xFFFFFFFF,"[ERROR]There is noone who wants to teleport to you!");
}
else{
new name[MAX_PLAYER_NAME+1];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s (ID:%i) has accepted your teleport inquiry.", name,playerid);
SendClientMessage(porter[playerid],0xFFFFFFFF,string);
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
if(IsPlayerInAnyVehicle(player[playerid])){
SetVehiclePos(GetPlayerVehicleID(player[playerid]),x+5,y,z+2);
}else{
SetPlayerPos(player[playerid],x+3,y,z+2);
}
}
porter[playerid] = -1;
}
return 1;
}
if(!strcmp(cmdtext,"/cancel",true,9))
{
new name[MAX_PLAYER_NAME+1];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s (ID:%i) has canceled the teleport inquiry.", name,playerid);
SendClientMessage(porter[playerid],0xFFFFFFFF,string);
porter[playerid] = -1;
player[porter[playerid]] = -1;
return 1;
}

