Raised This Month: $ Target: $400
 0% 

getting max number of teams?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
RedRobster
Veteran Member
Join Date: Apr 2010
Location: Your Closet
Old 07-06-2010 , 23:43   Re: getting max number of teams?
Reply With Quote #7

Well, when looping through the players, make sure to do
PHP Code:
new players[32], pnum
get_players
(playerspnum)
for(new 
ipnumi++)
{
        new 
tempid players[i]

The way you are doing it, it will loop through 33 times instead of just 32 as well.

Also, when doing this:
PHP Code:
        if((team1 team2) && (team1 team2+1))
        {
            
//team1 has too many people, do something about it.
        

There is no need for the first check because if the second one is true, the first one has to be true.
RedRobster 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 07:10.


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