SA-MP Forums Archive
[REQ] an info if player join your server - 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)
+--- Thread: [REQ] an info if player join your server (/showthread.php?tid=498400)



[REQ] an info if player join your server - ChristianIvann09 - 03.03.2014

Hi i want an script that

if player joins the server an junior admin up will see this message

PLAYERNAME(IPADRESS) has joined American Streets Roleplay....

like that.. thanks in advance

i need also an script..

if player register.. and if they spawn they will see this text
Welcome to American Streets Roleplay
Refund Info:
Cash= 20k
Car= 2
More


like that


Re: [REQ] an info if player join your server - kbalor - 03.03.2014

Код:
public OnPlayerConnect(playerid)
{
        new Country[256];
        new mess[256],IP[256];
        GetPlayerIp(playerid,IP,sizeof(IP));
        format(mess,sizeof(mess),"%s(%s) has joined American Streets Roleplay Sucks",GetPName(playerid),IP);
        printf(mess);
        SendClientMessageToAll(COLOR_JOIN,mess);
        return 1;
}
Full script with IP and Country
GEO-IP



Re: [REQ] an info if player join your server - ChristianIvann09 - 03.03.2014

Quote:
Originally Posted by kbalor
Посмотреть сообщение
Код:
public OnPlayerConnect(playerid)
{
        new Country[256];
        new mess[256],IP[256];
        GetPlayerIp(playerid,IP,sizeof(IP));
        format(mess,sizeof(mess),"%s(%s) has joined American Streets Roleplay Sucks",GetPName(playerid),IP);
        printf(mess);
        SendClientMessageToAll(COLOR_JOIN,mess);
        return 1;
}
Full script with IP and Country
GEO-IP
Is that only see if Junior Admin?

I need also an script that when player register and if they spawn they will see this text:

Refund Info:
Test
Test
Te
st


Re: [REQ] an info if player join your server - kbalor - 03.03.2014

Quote:
Originally Posted by ChristianIvann09
Посмотреть сообщение
Is that only see if Junior Admin?

I need also an script that when player register and if they spawn they will see this text:

Refund Info:
Test
Test
Te
st
If you want to only junior member too see the message. It will look like this

Код:
public OnPlayerConnect(playerid)
{
       if(PlayerInfo[playerid][JuniorAdmin] >= 1)
       {
                  new Country[256];
                  new mess[256],IP[256];
                  GetPlayerIp(playerid,IP,sizeof(IP));
                  format(mess,sizeof(mess),"%s(%s) has joined American Streets Roleplay Sucks",GetPName(playerid),IP);
                  printf(mess);
                  SendClientMessageToAll(COLOR_JOIN,mess);
                  return 1;
        }
        return 1;
}
Under OnPlayerSpawn

Код:
SendClientMessage(playerid,COLOR,"Test");
SendClientMessage(playerid,COLOR,"Test");
SendClientMessage(playerid,COLOR,"TE");
SendClientMessage(playerid,COLOR,"st");
or

Код:
if(PlayerInfo[playerid][JuniorAdmin] >= 1)
{
       {
           SendClientMessage(playerid,COLOR,"Test");
           SendClientMessage(playerid,COLOR,"Test");
           SendClientMessage(playerid,COLOR,"TE");
           SendClientMessage(playerid,COLOR,"st");
       }
       return 1;
}