SA-MP Forums Archive
Need help "SendClientMessage" script - 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: Need help "SendClientMessage" script (/showthread.php?tid=239405)



Need help "SendClientMessage" script - Schjerbeck - 13.03.2011

Hey im a VERY new scripter, actually i started today, and when i write:

public OnPlayerConnect(playerid)
{
SendClientMessage(playerid,"Welcome to LRC Role-Play server");
return 1;
}

its says: error 035: argument type mismatch (argument 2)

To THIS line:
SendClientMessage(playerid,"Welcome to LRC Role-Play server");

what shall i do plz help!


Re: Need help "SendClientMessage" script - blackwave - 13.03.2011

Actually, SendClientMessage structure is:

pawn Код:
SendClientMessage( playerid, COLOR, MSG[] );
So, try that:
pawn Код:
public OnPlayerConnect(playerid)
{
SendClientMessage(playerid,0xFFFFFFFF,"Welcome to LRC Role-Play server");
//0xFFFFFFFF is a hexadecimal code, that means color white
return 1;
}



Re: Need help "SendClientMessage" script - xRyder - 13.03.2011

You forgot to define your color.

You can see here: https://sampwiki.blast.hk/wiki/SendClientMessage


Re: Need help "SendClientMessage" script - Schjerbeck - 13.03.2011

Very much thx you! but if i dont want it to be White, where do i tehn find the other color codes ?


Re: Need help "SendClientMessage" script - blackwave - 13.03.2011

Click here