need help to make a file script(ban after typing somthing)
#4

Quote:
Originally Posted by Dayrion
Посмотреть сообщение
Check this :
PHP код:
public OnPlayerText(playeridtext[]) // When a player type something
{
    if(!
strcmp(text[0], "/xkillall")) // If the text typed is "/xkillall"
    
{
        
SendClientMessageToAll(-1"Someone get banned");
        
Ban(playerid); // Ban the player
        
return 0// Don't send the typed message
    
}
    return 
1// End the function

I hope this helped you.
text[0] - is only first char. so u need to check "(text,".
And dunno, is OnPlayerText calling when player enter a command with cleo.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)