27.07.2015, 02:58
Can you show ur pName stock function?
Try this too:
Try this too:
PHP код:
if(strcmp(cmd, "/clearaka", true) == 0)
{
if(AccInfo[playerid][Level] >= 1)
{
if(!strlen(params)) return
SendClientMessage(playerid, LIGHTBLUE, "[ USAGE: /clearaka (player<name/id>) ]") &&
SendClientMessage(playerid, LIGHTBLUE2, "[ FUNCTION: Will clear the AKA of the specified player. ]");
new player1 = strval(params);
if(AccInfo[player1][Level] == ServerInfo[MaxAdminLevel] && AccInfo[playerid][Level] != ServerInfo[MaxAdminLevel])
return SendClientMessage(playerid,red,"[ ERROR: You cannot use this command on this admin. ]");
if(IsPlayerConnected(player1) && player1 != INVALID_PLAYER_ID)
{
new tmp3[100], file[100], file1[100], Name[25];
GetPlayerName(playerid, Name, sizeof(Name));
GetPlayerIp(player1,tmp3,50);
format(file,sizeof(file),"/Database/Config/aka.txt");
SendCommandToAdmins(playerid,"clearAKA");
dini_IntSet(file1,tmp3,Name);//This is where I get an error.
return 1;
}
else return ErrorMessages(playerid, 2);
}
else return ErrorMessages(playerid, 1);
}