13.10.2012, 18:55
make sure u do this:
#include < YSI\y_ini >
CASE SENSITIVE !
and for the rest, here u go fixed one!
tried compiling works fine!
#include < YSI\y_ini >
CASE SENSITIVE !
and for the rest, here u go fixed one!

pawn Код:
CMD:unban(playerid,params[])
{
new aname[MAX_PLAYER_NAME];
if(sscanf(params,"s[MAX_PLAYER_NAME]",aname)) return SendClientMessage(playerid, -1, "Usage: /unban [player name]");
if(strlen(aname) > 24) return SendClientMessage(playerid, -1, "The Player Name Must Be Less Than 60 Characters Long.");
new string[98];
format(string,sizeof(string),"/Users/%s.ini",aname);
new IsBanned;
new INI:File = INI_Open(UserPath(playerid));
{
INI_Int("Banned");
}
if(IsBanned == 0) return SendClientMessage(playerid, -1, "This player account is not banned.");
if(!fexist(string)) return SendClientMessage(playerid, -1, "Player account not found, please note the files are CASE SENSITIVE.");
INI_WriteInt(File,"Banned",0);
INI_Close(File);
format(string,sizeof(string),"Player account %s has been unbanned.",aname);
SendClientMessage(playerid, -1, string);
format(string,sizeof(string),"Admin %s has unbanned the player account: %s.",aname[playerid],aname);
return 1;
}