How can I script a /me CMD? | Beginner Scripter
#8

I recommend using sscanf and zcmd. The way you could do this with these is....
PHP код:
CMD:me(playeridparams[])
{
    new 
action[256], string[256], name[24], Float:xFloat:yFloat:z;
    if(
sscanf(params"s[256]"action))
    {
        
SendClientMessage(playeridCOLOR"USAGE: /me [action]");
    }
    else
    {
        
GetPlayerName(playeridname24);
        
GetPlayerPos(playeridxyz);
        
format(string256"* %s %s *"nameaction);
        for(new 
0MAX_PLAYERSi++)
        {
            if(
IsPlayerInRangeOfPoint(i10xyz))
            {
                
SendClientMessage(iCOLORstring);
            }
        }
    }
    return 
1;

Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)