SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 28/02/2014, 09:32 AM   #1
alishvasis
Huge Clucker
 
alishvasis's Avatar
 
Join Date: Jan 2014
Location: Netherlands
Posts: 311
Reputation: 5
Default Admins Can Read Pm Of Players

hOw To Use Admins Can Read Pm Of Players whith This Cmd /Chatlog

+ Rep TnX
alishvasis is offline   Reply With Quote
Old 28/02/2014, 09:34 AM   #2
BroZeus
High-roller
 
BroZeus's Avatar
 
Join Date: Jan 2014
Location: India
Posts: 1,411
Reputation: 173
Default Re: Admins Can Read Pm Of Players

do u want admin to read only pms or all chats in chat logs?
__________________


"Be the change that you wish to see in the world."

Check out my Github profile!
BroZeus is offline   Reply With Quote
Old 28/02/2014, 09:35 AM   #3
[WSF]ThA_Devil
Gangsta
 
[WSF]ThA_Devil's Avatar
 
Join Date: Sep 2010
Location: United Kingdom
Posts: 721
Reputation: 55
Default Re: Admins Can Read Pm Of Players

you could try adding print(string); in PM function, it would log PM's to console.
[WSF]ThA_Devil is offline   Reply With Quote
Old 28/02/2014, 09:36 AM   #4
alishvasis
Huge Clucker
 
alishvasis's Avatar
 
Join Date: Jan 2014
Location: Netherlands
Posts: 311
Reputation: 5
Default Re: Admins Can Read Pm Of Players

Quote:
Originally Posted by BroZeus View Post
do u want admin to read only pms or all chats in chat logs?
Read Pm and All Use Cmds
alishvasis is offline   Reply With Quote
Old 28/02/2014, 09:41 AM   #5
BroZeus
High-roller
 
BroZeus's Avatar
 
Join Date: Jan 2014
Location: India
Posts: 1,411
Reputation: 173
Default Re: Admins Can Read Pm Of Players

show the pm script u are using i will edit it and make the thing u want
__________________


"Be the change that you wish to see in the world."

Check out my Github profile!
BroZeus is offline   Reply With Quote
Old 28/02/2014, 09:43 AM   #6
alishvasis
Huge Clucker
 
alishvasis's Avatar
 
Join Date: Jan 2014
Location: Netherlands
Posts: 311
Reputation: 5
Default Re: Admins Can Read Pm Of Players

Follow Me On This Post TNX


http://forum.sa-mp.com/showthread.ph...86#post2933286
alishvasis is offline   Reply With Quote
Old 28/02/2014, 10:19 AM   #7
BroZeus
High-roller
 
BroZeus's Avatar
 
Join Date: Jan 2014
Location: India
Posts: 1,411
Reputation: 173
Default Re: Admins Can Read Pm Of Players

ok this one i made this it will show all pms not tested it though
Code:
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;
}
__________________


"Be the change that you wish to see in the world."

Check out my Github profile!
BroZeus is offline   Reply With Quote
Old 28/02/2014, 10:27 AM   #8
alishvasis
Huge Clucker
 
alishvasis's Avatar
 
Join Date: Jan 2014
Location: Netherlands
Posts: 311
Reputation: 5
Default Re: Admins Can Read Pm Of Players

Tnx Very Much + Rep
alishvasis is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
PlayerPlaySound to admins when new report is up. and level 4 admins can read it only zrelly Scripting Help 12 07/09/2013 09:26 AM
Let admins read players' PM's selectively without players number limitation WellDone Scripting Help 6 15/05/2013 09:34 AM
Admins who can read pms [Ha]Lommo Help Archive 2 04/09/2010 09:03 AM
MOVED: Players can ban admins and other players dugi Server Support 0 06/04/2010 09:01 AM


All times are GMT. The time now is 11:48 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.