01.01.2011, 12:30
Hi, my command doesnt work when i try it in the SAMP Server... it comes back "Error: Unknown command"
Thats the code im haveing trouble with
Thanks
Wilko
Код:
dcmd_land(playerid, params[])
{
new ap, string[40], pName[MAX_PLAYER_NAME], lv, ls, sf;
if(sscanf(params, "s", ap)) return SendClientMessage(playerid, 0xFF0000AA, "USAGE: /land [ls/lv/sf]");
{
sf = strval("sf");
ls = strval("ls");
lv = strval("lv");
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
if(ap == lv)
{
format(string, sizeof(string), "%d is landing at Las Venturas International Airport, Clear the Runway", pName);
SendClientMessageToAll(0xFF00FFAA, string);
return 1;
}
else if (ap == ls)
{
format(string, sizeof(string), "%d is landing at Los Santos Airport, Clear the Runway", pName);
SendClientMessageToAll(0xFF00FFAA, string);
return 1;
}
else if (ap == sf)
{
format(string, sizeof(string), "%d is landing at San Fierro/Easter Basin Airport, Clear the Runway", pName);
SendClientMessageToAll(0xFF00FFAA, string);
return 1;
}
}
return 0;
}
Thanks
Wilko

