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

Switch on client connect


Post New Thread Reply   
 
Thread Tools Display Modes
Lord Canistra
Senior Member
Join Date: Mar 2009
Location: Tallinn, Estonia
Old 12-26-2009 , 06:12   Re: Switch on client connect
Reply With Quote #11

Use CS_SwitchTeam() and try to change EventHookMode_Pre to EventHookMode_Post.
__________________
Lord Canistra is offline
Dragonshadow
BANNED
Join Date: Jun 2008
Old 12-26-2009 , 09:55   Re: Switch on client connect
Reply With Quote #12

Quote:
Originally Posted by SelaX View Post
PHP Code:
public Event_PlayerTeam(Handle:event, const String:name[], bool:dontBroadcast)
{
    new 
client GetClientOfUserId(GetEventInt(event,"userid"));
    
ChangeClientTeam(clientCS_TEAM_CT);

This crash server too
Don't do it in the event, create a .1 sec timer that does it for you.
And take off the pre hook mode, you don't need it because you aren't modifying the event data.
Dragonshadow 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 17:20.


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