What to do to chat?
#5

PHP код:
new chatmode 1
PHP код:
stock SendLocalChat(playerid,color,msg[],Float:radius)
{
  new 
Float:x,Float:y,Float:z;
  
GetPlayerPos(playerid,x,y,z);
  for(new 
ply;ply<MAX_PLAYERS;ply++)
  {
    if(
IsPlayerInRangeOfPoint(ply,radius,x,y,z))SendClientMessage(ply,color,msg);
  }
  return 
1;

PHP код:
public OnPlayerText(playeridtext[])
{
    new 
sendername[MAX_PLAYER_NAME];
    new 
string[128];
    if(
chatmode)
    {
        
GetPlayerRPName(playeridsendernamesizeof(sendername));
        
format(stringsizeof(string), "%s says: %s"sendernametext);
        
SendLocalChat(playerid,COLOR_WHITE,string,20.0);
    }
     return 
0;

Reply


Messages In This Thread
What to do to chat? - by samtey - 30.07.2011, 17:32
Re: What to do to chat? - by =WoR=Varth - 30.07.2011, 17:40
AW: What to do to chat? - by samtey - 30.07.2011, 17:42
Re: What to do to chat? - by =WoR=Varth - 30.07.2011, 17:50
Re: What to do to chat? - by Kush - 30.07.2011, 17:52
AW: What to do to chat? - by samtey - 30.07.2011, 18:18
Re: What to do to chat? - by Gazmull - 30.07.2011, 18:44
Re: What to do to chat? - by Kush - 30.07.2011, 18:45

Forum Jump:


Users browsing this thread: 1 Guest(s)