04.12.2012, 04:24
(
Последний раз редактировалось zionx08; 04.12.2012 в 05:57.
Причина: Solved
)
<fixed>
CMD:osuspend(playerid,params[])
{
new string[124], string1[124], string2[124] ,reason[64];
if(!(PlayerInfo[playerid][pAdmin] >= 1)) return SCM(playerid, COLOR_LIGHTRED,"You are not authorized to use this command");
format(string,sizeof(string),"Users/%s.ini",params);
if(fexist(string))
{
new INI:File = INI_Open(string);
INI_SetTag(File,"data");
INI_WriteInt(File,"Ban", 1);
INI_Close(File);
// PlayerInfo[playerid][pBan] = 1; // I don't know why you have this?
format(string1, sizeof(string1), "{FF0000}[Admin-Warning]{FF6347} %s has been o-suspended by %s: %s .", params, GetPlayerNameEx(playerid), reason);
SendClientMessageToAll(playerid,string1);
format(string2, sizeof(string2), "{FFFF33}[Admin-Info]{FF0000}: {FFFFFF}%s has Offline-Suspended %s :%s.", GetPlayerNameEx(playerid), params ,reason);
AdminBroadCast(COLOR_LIGHTRED, string2);
}
else SendClientMessage(playerid,-1,"Account not found");
return 1;
}
CMD:osuspend(playerid,params[])
{
new string[124], string1[124], string2[124] ,reason[64];
if(!(PlayerInfo[playerid][pAdmin] >= 1)) return SCM(playerid, COLOR_LIGHTRED,"You are not authorized to use this command");
format(string,sizeof(string),"Users/%s.ini",params);
if(fexist(string))
{
new INI:File = INI_Open(string);
INI_SetTag(File,"data");
INI_WriteInt(File,"Ban", 1);
INI_Close(File);
format(string1, sizeof(string1), "{FF0000}[Admin-Warning]{FF6347} %s has been o-suspended by %s: %s .", params, GetPlayerNameEx(playerid), reason);
SendClientMessageToAll(playerid,string1);
format(string2, sizeof(string2), "{FFFF33}[Admin-Info]{FF0000}: {FFFFFF}%s has Offline-Suspended %s :%s.", GetPlayerNameEx(playerid), params ,reason);
AdminBroadCast(COLOR_LIGHTRED, string2);
}
else SendClientMessage(playerid,-1,"Account not found");
return 1;
}