SphereCommunity
Forchars miscount - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: Script Help (/Forum-Script-Help)
+--- Thread: Forchars miscount (/Thread-Forchars-miscount)



Forchars miscount - Mordaunt - 10-03-2012 05:50 AM

Code:
[function p_count]
forclients 18
   local.count +=1
   serv.b <local.count>
endfor

I always get 1 more returned than is actually present. Can anyone tell me why the person calling the function is counted twice?


RE: Forchars miscount - Extreme - 10-03-2012 06:42 AM

This happen with forchars too lol
Thats nice =D


RE: Forchars miscount - Mordaunt - 10-03-2012 07:37 AM

Yeah.. I know


RE: Forchars miscount - htid4life - 10-03-2012 07:06 PM

so knowin the problem just take 1 off from the result lol


RE: Forchars miscount - Mordaunt - 10-03-2012 11:57 PM

Yes that is what I am presently doing but the point is... it shouldn't do that....


RE: Forchars miscount - darksun84 - 10-04-2012 02:14 AM

With forchars i get the right number Shock


RE: Forchars miscount - Mordaunt - 10-04-2012 04:27 AM

You know, strangely I am now getting the right numbers, and I didn't change a thing since yesterday.


RE: Forchars miscount - Shaklaban - 10-04-2012 12:18 PM

don't put function into sub-subfolder, there is a bug with subfolders and for loops but i can't reproduce it all times Big Grin

http://tracker.sphere.torfo.org/bugs/view.php?id=2043