OnPlayerText, need advice. +pictures
#4

Is this above your other if statement? You have multiple don't you?


Here's an example;

pawn Код:
public OnPlayerText(playerid, text[])
{
    if(Muted[playerid]) {
        SendClientMessage(playerid, 0xCC0000AA, "You're muted, wait until you're unmuted.");
        return 0;
    }
    if(Showing[playerid]) {
        //...
        return 0;
    }
    if(AnotherTextInputNeeded[playerid]) {
        //Same as above, it needs to be before our client messages to stop it from sending.
        return 0;
    }
    //We put this above because we don't want our new custom text below to show when they type something.
   
    new string[128], name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, name, sizeof(name));
    format(string, sizeof(string), "%s says, \"%s\"", name, text);
    SendClientMessageToAll(0xCCCCCCAA, string);
    return 0;
}
Reply


Messages In This Thread
OnPlayerText, need advice. +pictures - by AdamCooper - 20.06.2013, 23:51
Respuesta: OnPlayerText, need advice. +pictures - by JustBored - 21.06.2013, 00:29
Re: OnPlayerText, need advice. +pictures - by AdamCooper - 21.06.2013, 01:00
Re: OnPlayerText, need advice. +pictures - by [ABK]Antonio - 21.06.2013, 01:03

Forum Jump:


Users browsing this thread: 1 Guest(s)