SA-MP Forums Archive
On player connect it comes up with a message saying they connected - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: On player connect it comes up with a message saying they connected (/showthread.php?tid=129814)



On player connect it comes up with a message saying they connected - cssbart - 23.02.2010

On player connect it comes up with a message saying they connected
so when some one connect its say "[name] Has Connected" [name] is there name in game
and when some on disconnects it say "[name] Has Disconnected" [name] is there name in game

please help


Re: On player connect it comes up with a message saying they connected - Torran - 23.02.2010

Do you want that to happen?
If so go here:

https://sampwiki.blast.hk/wiki/Creating_...Leave_Messages


Re: On player connect it comes up with a message saying they connected - bajskorv123 - 23.02.2010

pawn Код:
//OnPlayerConnect(playerid)
new string[128], pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, sizeof(pName));
format(string, sizeof(string), "%s has joined the server!", pName);
SendClientMessageToAll(color, string);

//OnPlayerDisconnect(playerid, reason)
new string[128], pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, sizeof(pName));
switch(reason)
{
  case 0: format(string, sizeof(string), "%s has left the server. [Timeout]", pName);
  case 1: format(string, sizeof(string), "%s has left the server. [Leaving]", pName);
  case 2: format(string, sizeof(string), "%s has left the server. [Kicked/Banned]", pName);
}
SendClientMessageToAll(color, string);
Just replace the "color" in SendClientMessageToAll to your color



Re: On player connect it comes up with a message saying they connected - cssbart - 26.02.2010

thanks