Closed Protonull closed 3 years ago
I just tested and was able to send 1800 logs in 2 seconds, which is still an issue. Those 2 seconds would take kira 6 minutes to relay in discord
Wait sorry my mistake, this does effectively rate limit thank you! Is it possible to throw a counter on the end of the log, to indicate that it is a ton of logs condensed? Otherwise it seems we wouldn't be able to tell if they are rate limited because they sent a ton, or they really did only trigger once. For example, I generated 1800 logs in my last test, this test I only generated 4 logs. But sometimes a person will trigger a couple logs, which is usually a lag spike, not an actual fastbreak incident and we need to be able to tell the difference
This should fix https://github.com/CivClassic/SimpleAdminHacks/issues/42 by putting console warnings behind a similar rate limiter as the fast-break limiter. If the plugin is in debug mode, every attempt to punish the player will be logged, otherwise it's max-rate limited to once every 10 seconds.