Chat tag - 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: Chat tag (
/showthread.php?tid=286158)
Chat tag -
Venice - 27.09.2011
I need chat tag for VIPS example [VIP]Mike : Chat
[VIP] Is yellow color and Name is Playercolor i need anyone give me
Im try but VIp tag show after the name
Re: Chat tag -
Wesley221 - 27.09.2011
pawn Код:
public OnPlayerText(playerid, text[])
{
if( IsPlayerVip(playerid) ) // change this with the variable where you define the vip
{
new String[128];
format( String, sizeof String, ""C_YELLOW"[VIP]%s(%i): %s", GetName(playerid), playerid, text );
SendClientMessageToAll(GetPlayerColor(playerid), String);
}
return 1;
}
Also define C_YELLOW, like this:
#define C_YELLOW "{HEXED YELLOW HERE}"
I dont know the yellow color in hex, you gotta find that
Re: Chat tag -
[MWR]Blood - 27.09.2011
pawn Код:
if(PInfo[playerid][Level] > 1) //Of course replace this with your own variables...
{
GetPlayerName(playerid,pName,24);
format(string,sizeof(string),"{FFF000}[VIP]{%06x}%s: {FFFFFF}",(GetPlayerColor(playerid) >>> 8), pName, text);
SendClientMessageToAll(GetPlayerColor(playerid),string);
}
return 0;
}