Raised This Month: $ Target: $400
 0% 

[L4D & L4D2] Meteor Shower


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
panxiaohai
Senior Member
Join Date: Mar 2010
Old 09-03-2010 , 20:41   Re: [L4D & L4D2] Meteor Shower
Reply With Quote #11

Quote:
Originally Posted by Skorpion1976 View Post
26 compile warnings o_O
what happens here? you use "i" in 2 loops.
Code:
if(!left && over)
    {
        Rain[userid][0]=0;
        for(new i=1; i<=c && i<150; i++)
        {
            new ent=Rain[userid][i];
            for(new i=1; i<=c && i<150; i++)
            {
                new ent=Rain[userid][i];
                if(IsRock(ent))
                {
                    
                    RemoveEdict(ent);
                }
                Rain[userid][i]=0;
            }
        }
Thank you, It 's a very serious error caused by copy and paste operation.
It is should be :
Code:
if(!left && over)
    {
        Rain[userid][0]=0;
        for(new i=1; i<=c && i<150; i++)
        {            
            new ent=Rain[userid][i];
            if(IsRock(ent))
            {
                
                RemoveEdict(ent);
            }
            Rain[userid][i]=0;
             
        }
        CloseHandle(h);
    
        return Plugin_Stop;
    }
panxiaohai 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 09:35.


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