mirror of
https://github.com/ViaVersion/ViaVersion.git
synced 2024-11-23 10:35:12 +01:00
This branch would be better here as it won't be applicable if elsewhere.
This commit is contained in:
parent
6198dbfe70
commit
a496b2d3a8
@ -483,10 +483,11 @@ public class ViaVersionPlugin extends JavaPlugin implements ViaVersionAPI, ViaVe
|
|||||||
if (info.getPacketsPerSecond() >= getWarningPPS()) {
|
if (info.getPacketsPerSecond() >= getWarningPPS()) {
|
||||||
info.setWarnings(info.getWarnings() + 1);
|
info.setWarnings(info.getWarnings() + 1);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (info.getWarnings() >= getMaxWarnings()) {
|
if (info.getWarnings() >= getMaxWarnings()) {
|
||||||
info.disconnect(getMaxWarningsKickMessage());
|
info.disconnect(getMaxWarningsKickMessage());
|
||||||
return true; // don't send current packet
|
return true; // don't send current packet
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user