I used to be able to prevent a bot from foading the network by using the sleep() function. Sins I have updated php this does not seem to work any more. Could also be they changed some thing on quakenet as I took a brake of 3 months on this project.
It used to wait for 1sec between all messages but now it seems like it just counts all the seconds to gethere and then sends all messages without a delay between them. So it foads the server and get kickt.
How would you prevent flooding ?
Or should I just try to make the info send out by every request smaller ? That would be the easy way out I gues
Are you running this as a standalone script via php -q start.php, or running it through an apache module by putting the script in webspace and accessing it from a browser?
You should be using it as a standalone script, but if you're running it through a browser, that might explain the behavior you're seeing if there's output buffering occurring. If you're trying to run through a webserver module, then try to flush() before the sleep() call.
I can't verify that it will fix the problem but it might. Otherwise, the code seems simple enough, and I can't offer much help.