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

disable change team


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Ghostery
Junior Member
Join Date: Apr 2019
Old 06-18-2021 , 11:55   disable change team
Reply With Quote #1

ok so... basicly i want to disable the team changing for players.

PHP Code:
#pragma semicolon 1

#include <sourcemod>

public Plugin:myinfo = {
    
name        "",
    
author      "",
    
description "",
    
version     = ,
    
url         ""
};

public 
OnPluginStart()
{
    
RegConsoleCmd("teammenu"cmd_teammenu);
}

public 
Action:cmd_teammenu(clientargs) {
    
PrintToChat(client"\x03[DR] %t""You are not allowed to change your team");
    return 
Plugin_Handled;

"teammenu" is the default command for team changing in csgo. so i thought i can block it just like killl or explode but it isnt working ... any other idea?
Ghostery is offline
FAQU
Member
Join Date: Sep 2020
Location: Romania
Old 06-18-2021 , 12:38   Re: disable change team
Reply With Quote #2

PHP Code:
public void OnPluginStart()
{
    
AddCommandListener(Command_Jointeam"jointeam");
}

public 
Action Command_Jointeam(int client, const char[] commandint args)
{
    
// PrintToChat(client, "message");
    
return Plugin_Handled;

__________________
FAQU is offline
Ghostery
Junior Member
Join Date: Apr 2019
Old 06-18-2021 , 12:52   Re: disable change team
Reply With Quote #3

Quote:
Originally Posted by FAQU View Post
PHP Code:
public void OnPluginStart()
{
    
AddCommandListener(Command_Jointeam"jointeam");
}

public 
Action Command_Jointeam(int client, const char[] commandint args)
{
    
// PrintToChat(client, "message");
    
return Plugin_Handled;

thanks!!
Ghostery 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 04:37.


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