Raised This Month: $ Target: $400
 0% 

Team_swtich


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
ProIcons
Senior Member
Join Date: Jan 2009
Location: Greece - Salonica
Old 05-09-2011 , 11:39   Re: Team_swtich
Reply With Quote #3

[pawn]
the server will not crash by changing all players teams...

Code:
public roundend() {     roundnumber++;         if( roundnumber >= get_pcvar_num( Atsround ) )     {         new players[32], num;         get_players( players, num, "h");                 for( new i; i < num; i++ )         {             new id=players[i];             switch (get_user_team(id))             {                 case 1: cs_set_user_team(id, CS_TEAM_CT);                 case 2: cs_set_user_team(id, CS_TEAM_T);             }         }     } }

This should work...
__________________
function rb return $regsubex($$1-,/(.)/g,$+($chr(2) $+ $chr(3),$r(2,15),$chr(2),\1))
ProIcons is offline
 



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:25.


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