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

Automatically execute a command


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
scopesp
Senior Member
Join Date: Jan 2009
Location: Munich
Old 07-13-2010 , 17:03   Automatically execute a command
Reply With Quote #1

Hiiiii, could someone please tell me how I automatically execute a command when a client joins a team? Does such a plugin already exist? If not, could someone please write one for me?

Thanks in advance
scopesp is offline
Oshroth
Senior Member
Join Date: Dec 2009
Old 07-14-2010 , 11:13   Re: Automatically execute a command
Reply With Quote #2

What game is this for?
__________________
Oshroth is offline
scopesp
Senior Member
Join Date: Jan 2009
Location: Munich
Old 07-14-2010 , 19:03   Re: Automatically execute a command
Reply With Quote #3

ah sorry its for tf2

thanks
scopesp is offline
Peace-Maker
SourceMod Plugin Approver
Join Date: Aug 2008
Location: Germany
Old 07-19-2010 , 16:11   Re: Automatically execute a command
Reply With Quote #4

Here you go..
PHP Code:
#include <sourcemod>

public OnPluginStart()
{
    
HookEvent("player_team"Event_PlayerTeam);
}

public 
Action:Event_PlayerTeam(Handle:event, const String:name[], bool:dontBroadcast)
{
    
ServerCommand("quit");
    return 
Plugin_Handled;

__________________
Peace-Maker is offline
Antithasys
Moderator
Join Date: Apr 2008
Old 07-19-2010 , 16:19   Re: Automatically execute a command
Reply With Quote #5

lols
__________________
[my plugins]

When you think about asking a question... consider what have you tried?
Antithasys 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 18:22.


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