Help problem
#1

Whenever someone write any command or send pm to anyone we can read that on CHAT
Ex: i write /car
and Sparta(3): /Car, i don't like that we must can't read others PM and Commands
Reply
#2

And we're supposed to guess your script? How about you post that part here and maybe then we can all see what the problem is? xD
Reply
#3

Which code? i can fix it if u remember me the CODE name
Reply
#4

i think, just make a variable and make it false in /pm command and go to your function where it sendclientmessage
"%s(%d): %s", name, playerid, command);. put it in a case when you put an statement that the given variable is true, if yes then send it.
Reply
#5

Code:
//==============================================================================
//Private Message (PM)
//==============================================================================
public OnPlayerPrivmsg(playerid, recieverid, text[])
{
	//--------------------------------------------------------------------------
	//Reading PM's
	//--------------------------------------------------------------------------
	new string[220];
	//--------------------------------------------------------------------------
	format(string, 220, "{FF0000}PrivateMessage: {00FF00}%s to %s: %s .*", PlayerName2(playerid), PlayerName2(recieverid), text);
	for(new a = 0; a < MAX_PLAYERS; a++)
	{
		if(IsPlayerConnected(a))
		{
			if(AccInfo[a][Level] >= 8)
			{
				if(AccInfo[a][ReadPM] == 1)
				{
   		SendClientMessage(a, grey, string);
				}
			}
		}
	}
	SaveIn("PMsLog",string);
Reply
#6

can you make me clear.

when you type /pm message. it shows it to all players like "Sparta(3): message" ?
if yes, then just remove the loop and add playerid instead of 'a'.
Reply
#7

yes.
Reply
#8

pawn Code:
//==============================================================================
//Private Message (PM)
//==============================================================================
public OnPlayerPrivmsg(playerid, recieverid, text[])
{
    //--------------------------------------------------------------------------
    //Reading PM's
    //--------------------------------------------------------------------------
    new string[220];
    //--------------------------------------------------------------------------
    format(string, 220, "{FF0000}PrivateMessage: {00FF00}%s to %s: %s .*", PlayerName2(playerid), PlayerName2(recieverid), text);

    if(IsPlayerConnected(playerid))
    {
        if(AccInfo[playerid][Level] >= 8)
        {
            if(AccInfo[playerid][ReadPM] == 1)
            {
        SendClientMessage(playerid, grey, string);
            }
        }
    }
    SaveIn("PMsLog",string);
i guess this gonna work.
Reply
#9

it's won't show when other player type any command we can't see right?
Reply
#10

it will only show them who have greater or equal to level 8 and it has enabled read pm. Otherwise it wont show.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)