code help +rep - 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: code help +rep (
/showthread.php?tid=556672)
code help +rep -
SampAsia - 11.01.2015
Код HTML:
public OnPlayerConnect(playerid)
{
new pmess[256],IP[256], name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
GetPlayerIp(playerid,IP,sizeof(IP));
printf("%s has joined the server. Country: %s | IP Address: %s",name, GetPlayerCountryName(playerid),IP);
format(pmess,sizeof(pmess),"COL_RED%s"COL_WHITE" has joined the server from "COL_RED"%s.", name, GetPlayerCountryName(playerid));
SendClientMessageToAll(-1, pmess);
GameTextForPlayer(playerid, "~g~Welcome ~r~to ~p~Samp~y~Drifting ~b~Community", 5001, 6);
return 1;
}
Код HTML:
See its showing Col_RED
Re: code help +rep -
]Rafaellos[ - 11.01.2015
pawn Код:
format(pmess, sizeof(pmess), ""COL_RED"%s"COL_WHITE" has joined the server from "COL_RED"%s.", name, GetPlayerCountryName(playerid));
Re: code help +rep -
SampAsia - 11.01.2015
thanx rep added!
Re: code help +rep -
SampAsia - 11.01.2015
Still its showing COL_RED
Re: code help +rep -
bgedition - 11.01.2015
try:
pawn Код:
format(pmess,sizeof(pmess),"{FF0000}%s {FFFFFF}has joined the server from {FF0000}%s.", name, GetPlayerCountryName(playerid));
Re: code help +rep -
Ironboy - 11.01.2015
Or you could just add this on the top of the script.
pawn Код:
#if !defined COL_RED
#define COL_RED "{FF0000}"
#endif