[HELP]Creating commands that use '!' instead of '/'
#3

pawn Код:
public OnPlayerText(playerid,text[])
{
    if(text[0] == '!')
    {
        text[0] = '/';
        OnPlayerCommandText(playerid,text);
        return 0;
    }
    //your onplayertext code
}
I got up right now, making my vreakfast, so there could be errors..

or:
pawn Код:
public OnPlayerText(playerid,text[])
{
    if(text[0] == '!')
    {
        text[0] = '/';
        CallLocalFunction("OnPlayerCommandText","is",playerid,text);
//or
//     CallRemoteFunction("OnPlayerCommandText","is",playerid,text);
        return 0;
    }
    //your onplayertext code
}
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)