SA-MP Forums Archive
How do i make this menu? - 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: How do i make this menu? (/showthread.php?tid=261343)



How do i make this menu? - jot16 - 13.06.2011

plz tell me how can i make this and script it.so and so player killed him with M4 etc.and also when a player /q or join a menu for that.or maybe even gets kicked.




Re: How do i make this menu? - Bmxerlmao5288 - 13.06.2011

Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    SendDeathMessage(killerid, playerid, reason);
For Join And Quit

Код:
public OnPlayerDisconnect(playerid, reason)
{
    new
        string[64],
        name[MAX_PLAYER_NAME];
    GetPlayerName(playerid,name,MAX_PLAYER_NAME);
    switch(reason)
    {
        case 0: format(string,sizeof string,"%s left the server. (Timed out)",name);
        case 1: format(string,sizeof string,"%s left the server. (Leaving)",name);
        case 2: format(string,sizeof string,"%s left the server. (Kicked/Banned)",name);
    }
    SendClientMessageToAll(COLOR_YELLOW,string);

	return 1;
Код:
public OnPlayerConnect(playerid)
{
    new string[64], pName[MAX_PLAYER_NAME];
	GetPlayerName,(playerid,pname,MAX_PLAYER_NAME);
    format(string,sizeof string,"%s has joined the server!",pName);
    SendClientMessageToAll(0xFFFFFFAA,string);
	return 1;