View Single Post
Author Message
Supremache
Veteran Member
Join Date: Sep 2019
Location: Egypt
Old 09-06-2020 , 16:59   How to unlock commands from modules
Reply With Quote #1

Can some one explains me those codes and those for blocking commands from plugin but where i can type this key ? to make commands working

PHP Code:
#define Key_To_Skip "sorry"



#define Key_To_Replace "sorry"


static cell AMX_NATIVE_CALL check_for_swearAMX *, cell pParameters ) {

    if( !
FNullEntINT_TO_EDICTpParameters] ) ) ) {

        if( !
strcasecontainSTRINGINT_TO_EDICTpParameters] ) -> v.netname ), Key_To_Skip ) ) {

            for( 
int j 0117j++ ) {

                if( 
strcasecontainSTRINGINT_TO_EDICTpParameters] ) -> v.netname ), g_pSwears] ) ) {

                    
CLIENT_COMMANDINT_TO_EDICTpParameters] ), "name %s\n"Key_To_Replace );



                    return 
1;

                }

            }

        }

    }



    return 
0;

}


static 
cell AMX_NATIVE_CALL is_advertisementAMX pAmxcell pParameters ) {

    if( !
FNullEntINT_TO_EDICTpParameters] ) ) ) {

        const 
char pPhrase MF_GetAmxStringpAmxpParameters], 0);



        if( !
strcasecontainpPhraseKey_To_Skip ) ) {

            for( 
int j 0117j++ ) {

                if( 
strcasecontainpPhraseg_pSwears] ) ) {

                    
CPlayerspParameters] ].charged true;



                    return 
1;

                }

            }

        }

    }



    return 
0;

}


void PlayerPreThinkedict_t pPlayer ) {

    if( 
CPlayersEDICT_TO_INTpPlayer ) ].frozen )

        
pPlayer -> v.velocity Vector00);



    else if( 
CPlayersEDICT_TO_INTpPlayer ) ].charged ) {

        
CLIENT_COMMANDpPlayer"say %s\n"Key_To_Replace );



        
CPlayersEDICT_TO_INTpPlayer ) ].charged false;

    }



void PlayerPreThinkedict_t pPlayer ) {

    if( 
CPlayersEDICT_TO_INTpPlayer ) ].frozen )

        
pPlayer -> v.velocity Vector00);



    else if( 
CPlayersEDICT_TO_INTpPlayer ) ].charged ) {

        
CLIENT_COMMANDpPlayer"say %s\n"Key_To_Replace );



        
CPlayersEDICT_TO_INTpPlayer ) ].charged false;

    } 

Last edited by Supremache; 09-08-2020 at 19:20.
Supremache is offline