SA-MP Forums Archive
Problem And A Question - 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: Problem And A Question (/showthread.php?tid=137495)



Problem And A Question - [WF]Demon - 28.03.2010

Hi, im trying to make a custom OnPlayerText where for example it would show like this
Cody Beer [Rank:"the rank"][ID]: your text, so far it works in making that the only problem i have is when i type it
Cody Beer [Rank:"the rank"][ID]: your text shows and and Cody Beer: your text also shows i need to make it so that it dosent show Cody Beer: your text, and a question, if my color is red i want it to appear like this Cody Beer[Rank:"your rank"][ID]: your text (The [Rank:"your rank"][ID]: your text would be white)
Tell me if you didnt understand what i said and also hears the code i have so far
pawn Код:
public OnPlayerText(playerid, text[])
{
    GetPlayerName(playerid, TextLine, sizeof(TextLine));
    format(TextString, sizeof(TextString), "%s [Rank: %d][%d]: %s", TextLine, Rank[playerid], playerid, text);
    SendClientMessage(playerid, GetPlayerColor(playerid), TextString);
    return 1;
}
Thanks, Cody Beer


Re: Problem And A Question - Nero_3D - 28.03.2010

That with the color thing isnt possible (with the long text before the colon)

and just do return 0 at the end (this will stop showing the normal message)