Raised This Month: $ Target: $400
 0% 

Client_Cmd Problem:


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
^SmileY
Veteran Member
Join Date: Jan 2010
Location: Brazil [<o>]
Old 04-23-2013 , 12:33   Re: Client_Cmd Problem:
Reply With Quote #1

One second..

EDIT (NOT TESTED):

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

public plugin_init()
{
    
register_plugin("Clear Chat",AMXX_vERSION_STR,"SmileY");
    
    
register_concmd("amx_chat_clear","cmdClearChat",ADMIN_RESERVATION,"- Clear all chat from users");
}

public 
cmdClearChat(id,level,cid)
{
    if(!
cmd_access(id,level,cid,1)) return PLUGIN_HANDLED;
    
    new 
iPlayers[32],iNum,Players;
    
get_players(iPlayers,iNum,"ch");
    
    new 
szName[32];
    
get_user_name(id,szName,charsmax(szName));
    
    for(new 
i;iNum;i++)
    {
        
Players iPlayers[i];
        
        if(
access(Players,ADMIN_RESERVATION)) continue;
        
// ADMIN_RESERVATION FLAG WILL REMOVE THE ADMIN FROM LOOP
        
        
client_print_green(Players,"           ADMINUL %s a curatat chatu!           ",szName);
        
client_print_green(Players,"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        
client_print_green(Players,"         ;(Motiv:Reclama sau Vulgarisme)        ");
        
client_print_green(Players,"              ---=JB.Freakz.Ro=---             "); 
        
client_print_green(Players,"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        
        
client_cmd(Players,"speak misc/antend.wav;wait;clear");
    }
    return 
PLUGIN_HANDLED;

__________________
Projects:

- See my Git Hub: https://github.com/SmileYzn
PHP Code:
set_pcvar_num(pCvar, !get_pcvar_num(pCvar)); 

Last edited by ^SmileY; 04-23-2013 at 15:15. Reason: Code v2
^SmileY is offline
Send a message via MSN to ^SmileY Send a message via Skype™ to ^SmileY
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 10:52.


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