Raised This Month: $ Target: $400
 0% 

[REQ] Plugin Block Say Text


Post New Thread Reply   
 
Thread Tools Display Modes
morteza_m2n
Member
Join Date: Apr 2011
Old 06-12-2011 , 09:09   Re: [REQ] Plugin Block Say Text
Reply With Quote #21

Quote:
Originally Posted by drekes View Post
Edited code above with cvar
tnx

this plugin make spam .

can u edit that like wrecked_ plugin ?

her plugins say is diffrent it show a different say just who want typ see that

i want that plugin with cvar and not block for admins

ty again

Last edited by morteza_m2n; 06-12-2011 at 09:33.
morteza_m2n is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 06-12-2011 , 10:51   Re: [REQ] Plugin Block Say Text
Reply With Quote #22

Without spam:
PHP Code:
#include <amxmodx>
#include <amxmisc>

new cOn;

public 
plugin_init()
{
    
register_plugin"Text Chat Stop""0.1""wrecked_" )

    
register_clcmd"say""stop_say" )

    
cOn register_cvar("block_chat""1");
}

public 
stop_sayid )
{
    if(!
get_pcvar_num(cOn) || is_user_admin(id))
        return 
PLUGIN_CONTINUE;

    return 
PLUGIN_HANDLED_MAIN

__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
morteza_m2n
Member
Join Date: Apr 2011
Old 06-12-2011 , 17:04   Re: [REQ] Plugin Block Say Text
Reply With Quote #23

hey thank u again

i am sry for request again.

i sayd i want when a player want typ show a say like wrecked plugin

just edit below plugin for me : admins can say

#include <amxmodx>

new enabled

public plugin_init()
{
register_plugin( "Text Chat Stop", "0.1", "wrecked_" )

enabled = register_cvar( "tc_enabled", "1" )

register_clcmd( "say", "stop_say" )
}

public
stop_say( id )
{
if(
get_pcvar_num( enabled ) == 0 )
return
PLUGIN_CONTINUE;

else {
client_print( id, print_chat, "[AMXX] Command not allowed on this server!" )

return
PLUGIN_HANDLED_MAIN;
}
}




tnx
morteza_m2n is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 06-12-2011 , 17:34   Re: [REQ] Plugin Block Say Text
Reply With Quote #24

Here:

PHP Code:
#include <amxmodx>
#include <amxmisc>

new enabled

public plugin_init()
{
    
register_plugin"Text Chat Stop""0.1""wrecked_" )

    
enabled register_cvar"tc_enabled""1" )

    
register_clcmd"say""stop_say" )
}

public 
stop_sayid )
{
    if( 
get_pcvar_numenabled ) == || is_user_adminid ) )
        return 
PLUGIN_CONTINUE;

    
client_printidprint_chat"[AMXX] Command not allowed on this server!" )
    return 
PLUGIN_HANDLED_MAIN;

__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
roh1r1m
New Member
Join Date: Oct 2010
Location: Ankara
Old 07-16-2011 , 12:10   Re: [REQ] Plugin Block Say Text
Reply With Quote #25

I need a plugin that when admin type /sayoff only teammates can write and with /sayon command everybody can write and read each other.

I thanks Drekes he sent me a untested code but it didn't work like i meant to.
Could Any one fix it ?
PHP Code:
#include <amxmodx>
#include <amxmisc>

#define ADMIN_SAY    ADMIN_CHAT


new cOn;

public 
plugin_init()
{
    
register_plugin"Text Chat Stop""0.1""wrecked_" )

    
register_clcmd"say""stop_say" )

    
cOn register_cvar("block_chat""1");
}

public 
stop_sayid )
{
    if(
get_user_flags(id) & ADMIN_SAY)
    {    
        new 
szArg[10];
        
read_args(szArgcharsmax(szArg));
        
remove_quotes(szArg);
        
        if(
equali(szArg"/sayon"))
            
SetSay(idtrue);
        
        else if(
equali(szArg"/sayoff"))
            
SetSay(idfalse);
            
        return 
PLUGIN_HANDLED;
    }
    
    if(!
get_pcvar_num(cOn) || is_user_admin(id))
        return 
PLUGIN_CONTINUE;
    
    
    return 
PLUGIN_HANDLED_MAIN
}  


SetSay(idboolbOn)
{
    new 
szName[32];
    
get_user_name(idszNamecharsmax(szName));
    
    if(
bOn)
        
set_pcvar_num(cOn1);
        
    else
        
set_pcvar_num(cOn0);
    
    
client_print(0print_chat"[AMXX] ADMIN %s %sabled public chat!"szNamebOn "en" "dis");

Thats what he sent me.
roh1r1m is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 19:41.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode