/say Problem
#2

Why are you using strtok inside dcmd ? dcmd was made for you to not use slow and unefficient strtok

pawn Код:
dcmd_say(playerid,params[])
{
  if(IsPlayerAdmin(playerid))
  {
  if(!strlen(params))
  {
   SendClientMessage(playerid,COLOR_GREY,"|| Usage: /say (text) ||");
   SendClientMessage(playerid,COLOR_GREY,"|| Function: Announces a adminґs text global. ||");
   return true;
  }
  new pname2[MAX_PLAYER_NAME], string[256];
  GetPlayerName(playerid, pname2, sizeof(pname2));
  format(string, sizeof(string), "|| Administrator %s: %s ||", pname2, params);
  SendClientMessageToAll(COLOR_ORANGE, string);
  return true;
  }
  else return SendClientMessage(playerid, COLOR_RED, "[!] You are not logged into RCON.");
}
Reply


Messages In This Thread
/say Problem - by Striker_Moe - 12.09.2009, 12:07
Re: /say Problem - by dice7 - 12.09.2009, 12:19
Re: /say Problem - by Striker_Moe - 12.09.2009, 12:23
Re: /say Problem - by Striker_Moe - 12.09.2009, 13:27
Re: /say Problem - by Calgon - 12.09.2009, 13:28
Re: /say Problem - by Striker_Moe - 12.09.2009, 13:43
Re: /say Problem - by Striker_Moe - 12.09.2009, 14:27
Re: /say Problem - by Calgon - 12.09.2009, 14:37
Re: /say Problem - by Striker_Moe - 12.09.2009, 14:42
Re: /say Problem - by Calgon - 12.09.2009, 14:49

Forum Jump:


Users browsing this thread: 4 Guest(s)