Raised This Month: $51 Target: $400
 12% 

Block team changing NEW


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
helpme13
Member
Join Date: Apr 2008
Location: denmark
Old 07-05-2008 , 14:14   Block team changing NEW
Reply With Quote #1

Eny there can make me a plugin there do u cant blocks team from ct to t and t to ct and i shall in chat when one do write with green color i have try the other Block team i it does work u can try my server it dont work plz make me at today i need it
helpme13 is offline
Send a message via MSN to helpme13
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 07-05-2008 , 17:21   Re: Block team changing NEW
Reply With Quote #2

PHP Code:
#include <amxmodx>


#define PLUGIN_NAME "Block Team Change"
#define PLUGIN_VERSION "0.1"
#define PLUGIN_AUTHOR "Exolent"


#pragma semicolon 1


new g_msgSayText;
new 
g_MaxPlayers;

public 
plugin_init()
{
    
register_plugin(PLUGIN_NAMEPLUGIN_VERSIONPLUGIN_AUTHOR);
    
    
g_msgSayText get_user_msgid("SayText");
    
g_MaxPlayers get_maxplayers();
    
    return 
PLUGIN_CONTINUE;
}

public 
client_command(plr)
{
    new 
sArg[12];
    
read_argv(1sArg11);
    
    if( 
equali(sArg"choosteam"0) && get_user_team(plr""0) )
    {
        
green_print(plr"You cannot change teams!");
        
        return 
PLUGIN_HANDLED;
    }
    
    return 
PLUGIN_CONTINUE;
}

green_print(plr, const sFmt[], any:...)
{
    new 
plr plr get_player();
    if( !
)
    {
        return 
0;
    }
    
    new 
sMessage[256];
    new 
len copy(sMessage255"^x04");
    
vformat(sMessage[len], 255-lensFmt3);
    
sMessage[192] = '^0';
    
    
make_SayText(plrisMessage);
    
    return 
1;
}

get_player()
{
    for( new 
plr 1plr <= g_MaxPlayersplr++ )
    {
        if( 
is_user_connected(plr) )
        {
            return 
plr;
        }
    }
    
    return 
0;
}

make_SayText(receiversendersMessage[])
{
    
message_begin(receiver MSG_ONE MSG_ALLg_msgSayText, {000}, receiver);
    
write_byte(sender);
    
write_string(sMessage);
    
message_end();
    
    return 
1;

__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
Old 07-18-2008, 16:14
DaKo
This message has been deleted by DaKo.
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 16:15.


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