[FilterScript] [FS]Welcome Message
#1

Hello
it's simple System
When player connect it Says Welcome to : <player name>
here is the Pastbin :
http://pastebin.com/xrtXFQZw
I hope you gone like it.
Best regards.
Reply
#2

Nice filterscript for a first script. (I just guess that this is your first filterscript, am I right?)
But please note that now only the connected player will see: "Welcome to : PLAYERNAME"
To send an message to ALL the players, use "SendClientMessageToAll(color, message[])", so "SendClientMessageToAll(COLOR_GREEN, string)"
Reply
#3

Sorta looks like an edited version of the demo here:

https://sampwiki.blast.hk/wiki/OnPlayerConnect
Reply
#4

true, but anyways if its your first release fw good work
its easy let me write it
new pName[MAX_PLAYERS_NAME],string[100];
format(string,sizeof(string),"welcome to %s",pName);
SendClientMessageToAll(anycolor,string);
just wrote it my self
but...
Reply
#5

If you used the one that they just made (the poster not dark_clown) it wouldn't format the text to EVERYONE but only the person that just joined because they used SendClientMessage instead of SendClientMessageToAll
Reply
#6

uhhm put this


Код:
#define COLOR_GREEN 0x228B22FF

and
Код:
public OnPlayerConnect(playerid)
{
        new string[256];
        new playerName[24];
        GetPlayerName(playerid,playerName,24);
        format(string,sizeof(string),"Welcome to : %s",playerName);
        SendClientMessage(playerid,COLOR_GREEN,string);
      return 1;
}
Reply
#7

WTF string 256 for this? lawl.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)