How to make text Wrap?
#10

pawn Код:
SendCustomPlayerMessage(playerid, color, text[])
{
    if(strlen(text) > 64)
    {
        new text1[65],
            text2[65];
           
        strmid(text2, text, 64, 128);
        strmid(text1, text, 0, 64);
               
        format(string, 128, "%s...", text1);
        SendClientMessage(playerid, color, string);
       
        format(string, 128, "...%s", text2);
        SendClientMessage(playerid, color, string);
    }
    else SendClientMessage(playerid, color, text);
}
Ex:
SendCustomPlayerMessage(0, 0xAA3333AA, "Sam says: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaa");

Will output

Sam says: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaa...
...aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaa
Reply


Messages In This Thread
How to make text Wrap? - by Deal-or-die - 14.03.2011, 13:14
Re: How to make text Wrap? - by CyNiC - 14.03.2011, 13:36
Re: How to make text Wrap? - by Deal-or-die - 14.03.2011, 13:38
Re: How to make text Wrap? - by Pz - 14.03.2011, 13:41
Re: How to make text Wrap? - by Deal-or-die - 14.03.2011, 14:07
Re: How to make text Wrap? - by Pz - 14.03.2011, 14:08
Re: How to make text Wrap? - by Deal-or-die - 14.03.2011, 14:37
Re: How to make text Wrap? - by Tee - 14.03.2011, 14:39
Re: How to make text Wrap? - by Jeffry - 14.03.2011, 14:46
Re: How to make text Wrap? - by Macluawn - 14.03.2011, 15:17

Forum Jump:


Users browsing this thread: 4 Guest(s)