how to script /me?
#2

pawn Код:
if(!strcmp("/me", cmdtext, true))
{
  new str[218],name[24]; // creating variables: str and name for the text-string and the name of the player
  GetPlayerName(playerid, name, 24); // getting the playername and storing it in the variable name
  format(str, 218, "%s: %s", name, cmdtext[3]); // formatting the string with the name and the message behind the command /me
  SendClientMessageToAll(0xFF0000AA, str); // sending the text
  return 1;
}
Needs perfectioning but it is standard without checking for empty stuff..
Reply


Messages In This Thread
how to script /me? - by Badandy - 10.07.2009, 19:51
Re: how to script /me? - by mamorunl - 10.07.2009, 19:56
Re: how to script /me? - by Badandy - 10.07.2009, 19:57
Re: how to script /me? - by Badandy - 10.07.2009, 20:23
Re: how to script /me? - by Grim_ - 10.07.2009, 20:26
Re: how to script /me? - by Anarkien - 10.07.2009, 20:31
Re: how to script /me? - by Grim_ - 10.07.2009, 20:38
Re: how to script /me? - by Correlli - 10.07.2009, 20:40
Re: how to script /me? - by Anarkien - 10.07.2009, 20:41
Re: how to script /me? - by Grim_ - 10.07.2009, 20:45

Forum Jump:


Users browsing this thread: 1 Guest(s)