[Ajuda] Ajuda comando pm
#1

Eu queria que na frente de quem mandou o pm fica-se com o id tipo assim **Recebido de Thiago (ID:%i) e >>Recebida de Thiago (ID:%i) (no lugar do %i o id da pessoa)

Код HTML:
// This commands allows the player to send a private message to another player
COMMAND:pm(playerid, params[])//OK
{
	new OtherPlayer, Message[128], Msg1[128], Msg2[128], YourName[24], OtherPlayerName[24];
	SendAdminText(playerid, "/pm", params);
	if (APlayerData[playerid][LoggedIn] == true)
	{
		if (sscanf(params, "us[128]", OtherPlayer, Message)) SendClientMessage(playerid, 0xFF0000AA, "{FF0000}Use: /pm [id] [menssagem]");
		else
		{
			if (IsPlayerConnected(OtherPlayer))
			{
			    if (APlayerData[playerid][Muted] == false)
			    {
					GetPlayerName(playerid, YourName, sizeof(YourName));
					GetPlayerName(OtherPlayer, OtherPlayerName, sizeof(OtherPlayerName));
					format(Msg1, 128, "{FFFF00}>> Enviada Para %s: %s", OtherPlayerName, Message);
					format(Msg2, 128, "{FFFF00}** Recebida De %s: %s", YourName, Message);
			        GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~r~Menssagem privada ~y~enviada~y~!", 3000, 3);
			        GameTextForPlayer(OtherPlayer, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~y~ Menssagem privada ~r~recebida~r~!", 3000, 3);
					SendClientMessage(playerid, 0xFFFFFFFF, Msg1);
					SendClientMessage(OtherPlayer, 0xFFFFFFFF, Msg2);
				}
				else
				    SendClientMessage(playerid, 0xFF0000FF, "{FF0000}Vocк ainda estб mudo!");
			}
			else
			    SendClientMessage(playerid, 0xFF0000FF, "{FF0000}O jogador nгo estб online.");
		}
	}
	else
	 return 0;
	return 1;
}
Reply


Messages In This Thread
Ajuda comando pm - by ThiagoMK - 29.05.2013, 16:07
Re: Ajuda comando pm - by ProKillerpa - 29.05.2013, 16:14
Re : Ajuda comando pm - by ThiagoMK - 29.05.2013, 16:28
Re : Ajuda comando pm - by ThiagoMK - 29.05.2013, 16:43

Forum Jump:


Users browsing this thread: 1 Guest(s)