[HELP] How to do this? [Unsolved]
#3

Quote:
Originally Posted by Μαστερμινδ
I made it with space detection, so it would be:
Код:
(( [8] Uniqueee: hello all the people ... ))
(( [8] Uniqueee: ... in the world! ))
instead of:
Код:
(( [8] Uniqueee: hello all the peo ... ))
(( [8] Uniqueee: ... ple in the world! ))
Код:
#define MAXLEN 30
pawn Код:
OnPlayerText

new str[128];
if(strlen(text) > MAXLEN)
{
  new pos = MAXLEN+10;
  while(text[--pos] > ' ') {}
  if(pos < MAXLEN-10) pos = MAXLEN;
  format(str, sizeof(str), "(( [%d] %s: %.*s ... ))", playerid, PlayerName(playerid), pos, text);
  SendClientrMessageToAll(WHITE, str);
  format(str, sizeof(str), "(( [%d] %s: ... %s ))", playerid, PlayerName(playerid), text[pos+1]);
  SendClientMessageToAll(WHITE, str);
  return 0;
}
It works but i meant if a player writes something that is bigger than the chat limit,
there is a limit like 50 chracters,i want it to write the text after the limit.
Reply


Messages In This Thread
[HELP] How to do this? [Unsolved] - by Nakash - 22.12.2009, 12:40
Re: [HELP] How to do this? - by M4S7ERMIND - 22.12.2009, 13:34
Re: [HELP] How to do this? - by Nakash - 22.12.2009, 14:15
Re: [HELP] How to do this? - by M4S7ERMIND - 22.12.2009, 16:34
Re: [HELP] How to do this? - by JoeDaDude - 22.12.2009, 16:55
Re: [HELP] How to do this? - by Kurence - 22.12.2009, 17:06
Re: [HELP] How to do this? - by kmzr - 22.12.2009, 17:16
Re: [HELP] How to do this? - by Nakash - 22.12.2009, 19:20
Re: [HELP] How to do this? - by Zamaroht - 22.12.2009, 19:31
Re: [HELP] How to do this? - by Nakash - 22.12.2009, 20:35

Forum Jump:


Users browsing this thread: 1 Guest(s)