SA-MP Forums Archive
Scripting Help? - 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: Scripting Help? (/showthread.php?tid=188228)



Scripting Help? - Colton - 06.11.2010

Alright Guy's I have a Question, Lets say I wanted to make a welcome message I would put this into pawno compile into .amx and put it into my filterscript folder on my server.
Is there anything I need to add onto this to make it work?

Код:
#include <a_samp>

#define RED 0xAA3333AA
#if define FILTERSCRIPT
public OnPlayerConnect(playerid)
{

	 new string[85],pname[24];
        GetPlayerName(playerid,pname,24);
        format(string,sizeof(string),"*** %s Has Joined The Server! (ID:%d)",pname,playerid);
        SendClientMessageToAll(RED,string);



	SendClientMessage(playerid, RED, "Welcome");
#endif



Re: Scripting Help? - Haydz - 06.11.2010

Just put this into your gamemode,

pawn Код:
//search for OnPlayerConnect
{

    new string[85],pname[24];
    GetPlayerName(playerid,pname,24);
    format(string,sizeof(string),"*** %s Has Joined The Server! (ID:%d)",pname,playerid);
    SendClientMessageToAll(RED,string);

    SendClientMessage(playerid, RED, "Welcome");

//then if you don't have red defined just put
#define RED 0xAA3333AA

at the top of your script