OnPlayerText
#10

Quote:
Originally Posted by ♣ ⓐⓢⓢ
Quote:
Originally Posted by Luka™
I think it will not work but try xD

pawn Код:
public OnPlayerText(playerid,text[])
{
    for(new i;i < strlen(text) < i++;)
    {
        if(i == 1 && !strcmp(text[i],"(",false))
        {
            text[i] = ' ';
            // Your code for sending message here
        }
    }
}
Man you got the chance to win the "the most ineffective code ever award"

here would be another solution instead of changing an array element

pawn Код:
if(text[0] == '(')
{
    new string[(136 + MAX_PLAYER_NAME)];
    GetPlayerName(playerid, string, MAX_PLAYER_NAME);
    format(string, sizeof string, "%s : (( %s ))", string, text[1]);
    ProxDetector(20.0, playerid, string, COLOR_FADE1, COLOR_FADE2, COLOR_FADE3, COLOR_FADE4, COLOR_FADE5);
    return print(string);
}
Thank you, but I have few "The Most Ineffective Code" awards already !
Reply


Messages In This Thread
OnPlayerText - by Naruto4 - 28.11.2009, 17:21
Re: OnPlayerText - by miokie - 28.11.2009, 17:24
Re: OnPlayerText - by Naruto4 - 28.11.2009, 17:31
Re: OnPlayerText - by miokie - 28.11.2009, 17:33
Re: OnPlayerText - by UsaBoy91 - 28.11.2009, 17:38
Re: OnPlayerText - by Luka P. - 28.11.2009, 17:46
Re: OnPlayerText - by Naruto4 - 28.11.2009, 17:50
Re: OnPlayerText - by Luka P. - 28.11.2009, 17:58
Re: OnPlayerText - by Nero_3D - 28.11.2009, 18:05
Re: OnPlayerText - by Luka P. - 28.11.2009, 18:15

Forum Jump:


Users browsing this thread: 5 Guest(s)