pawn Код:
#include < a_samp >
new rFlood [ MAX_PLAYERS ] ;
public OnPlayerText ( playerid , text [ ] )
{
//onplayertext
new pvar [ 128 ] ;
GetPVarString ( playerid , "UltimoTexto" , pvar , sizeof ( pvar ) ) ;
if ( strlen ( pvar ) && !strcmp ( pvar , text ) ) {
SendClientMessage ( playerid , -1 , "Pare de repetir no chat!" ) , rFlood [ playerid ] ++ ;
return 0 ;
}
SetPVarString ( playerid , "UltimoTexto" , text ) ;
if ( rFlood [ playerid ] == 3 ) return rFlood [ playerid ] = 0 , Kick ( playerid ) ;
return 0 ;
}