question about player name
#1

is there any way , change %s to like %y ?
Reply
#2

why would you want that?
Reply
#3

because if i use;

pawn Code:
new str[128];
    new PR = PInfo[playerid][Rank];
    format(str, 128, "%s Your Rank Is: %d: \"%s\"", PR, RankInfo[PR][RName]);
    SendClientMessage(playerid, 0x7CFC00AA, str);
then it takes 2 time namne -.-
Reply
#4

Post the whole thing because I don't fully understand the format line.

this is how i should do it:

[RANKVARIABLE] Your Rank Is: Enforcer/rankname

pawn Code:
dcmd_myrank(playerid,params[])
{
new str[128];
#pragma unused params
if(PInfo[playerid][Rank] == 1)
{
format(str,sizeof(string),"[Rank number:%d] Your rank is: Enforcer",PInfo[playerid][Rank]);
SendClientMessage(playerid, 0x7CFC00AA, str);
}
else if(..................)
{
..........
}
and so on
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)