Splitting message doesn't work
#9

Because you didn't code it right
Modify it to:
PHP код:
    if(strcmp(cmd"/me"true) == 0
    { 
        new 
strmsg[128]; 
        new 
strmsgex[128]; 
        
GetPlayerName(playeridsendernamesizeof(sendername)); 
        new 
length strlen(cmdtext); 
        while ((
idx length) && (cmdtext[idx] <= ' ')){idx++;} 
        new 
offset idx,result[64]; 
        while ((
idx length) && ((idx offset) < (sizeof(result) - 1))){result[idx offset] = cmdtext[idx];idx++;} 
        
result[idx offset] = EOS
        if(!
strlen(result))return SendClientMessage(playeridred"USAGE: /me [action]"); 
        
format(strmsgsizeof(strmsg), "%s %s"sendernameresult); 
        if(
SplittedMessage(strmsgstrmsgexsizeof strmsgsizeof strmsgex)) 
        { 
        
ProxDetector(15.0playeridstrmsgCOLOR_EMOTECOLOR_EMOTECOLOR_EMOTECOLOR_EMOTECOLOR_EMOTE); 
        
ProxDetector(15.0playeridstrmsgexCOLOR_EMOTECOLOR_EMOTECOLOR_EMOTECOLOR_EMOTECOLOR_EMOTE); 
        return 
1
        } 
        else 
        {
        
ProxDetector(15.0playeridstrmsg,COLOR_EMOTE,COLOR_EMOTE,COLOR_EMOTE,COLOR_EMOTE,COLOR_EMOTE); 
        
printf("%s"rpstring); 
        return 
1
        } 
    } 
Reply


Messages In This Thread
Splitting message doesn't work - by cs_waller - 23.11.2016, 21:37
Re: Splitting message doesn't work - by OneDay - 23.11.2016, 21:47
Re: Splitting message doesn't work - by SickAttack - 23.11.2016, 21:53
Re: Splitting message doesn't work - by cs_waller - 23.11.2016, 22:01
Re: Splitting message doesn't work - by Aliassassin123456 - 23.11.2016, 23:30
Re: Splitting message doesn't work - by cs_waller - 23.11.2016, 23:43
Re: Splitting message doesn't work - by Aliassassin123456 - 23.11.2016, 23:50
Re: Splitting message doesn't work - by cs_waller - 24.11.2016, 00:12
Re: Splitting message doesn't work - by Aliassassin123456 - 24.11.2016, 00:16
Re: Splitting message doesn't work - by cs_waller - 24.11.2016, 09:25

Forum Jump:


Users browsing this thread: 1 Guest(s)