you could try adding print(string); in PM function, it would log PM's to console.
Код:
dcmd_pm(playerid,params[])
{
new string[128];
new ID;
new cmdreason[100];
if(sscanf(params, "us[100]", ID, cmdreason))
{
SendClientMessage(playerid,COLOR_RED,"Tarighe: /pm (Player Name/ID) (Message)");
return 1;
}
if(IsMuted[playerid] == 1)
{
SendClientMessage(playerid,COLOR_RED,"You are Muted. You Cannot Use This Command");
return 1;
}
if(udb_Exists(PlayerName(playerid)) && !PLAYERLIST_authed[playerid])
{
SendClientMessage(playerid,COLOR_RED,"You must login before you can talk");
return 1;
}
if(!IsPlayerConnected(ID))
{
format(string, sizeof(string), "The Player ID (%d) is not connected to the server.",ID);
SendClientMessage(playerid,COLOR_RED,string);
return 1;
}
format(string, sizeof(string), "PM Sent to: %s(%d): %s",PlayerName(ID),ID,cmdreason);
SendClientMessage(playerid,COLOR_YELLOW,string);
format(string, sizeof(string), "PM From: %s(%d) %s",PlayerName(playerid),playerid,cmdreason);
SendClientMessage(ID,COLOR_YELLOW,string);
format(string, sizeof(string), "3[PM] From %s(%d) to %s(%d): %s",PlayerName(playerid),playerid,PlayerName(ID),ID,cmdreason); // [0] <jacob> hi
IRC_GroupSay(gGroupAdminID,IRC_ADMINCHANNEL,string);
new FIle:chat=fopen("pms.txt",io_append);
format(string,sizeof(string),"%s sended PM to %s : %s",PlayerName(playerid),Playrname(ID),cmdreason);
fwrite(chat,string);
fclose(chat);
SpamStrings[playerid] ++;
PlayerPlaySound(ID,1085,0.0,0.0,0.0);
return 1;
}
dcmd_readpm(playerid,parmas[])
{
new shpm[100],ppm[999],len=0;
if(!IsPlayerAdmin(playerid))return SendClientMessage(playerid,-1,"{ff0000}You are not authorized to use this command.");
new File:pm= fopen("pms,txt",io_read);
while(fread(pm, shpm))
{
strins(ppm, shpm, len+1);
len=strlen(ppm);
strins(ppm, "\n", len+1);
len=strlen(ppm);
}
ShowPlayerDialog(playerid,dialogpm,DIALOG_STYLE_MSGBOX,"{f0f000}Private {00f0f0}Messages",ppm,"OK","");
fclose(pm);
return 1;
}