Skip to content

Commit 53d6995

Browse files
authored
Merge pull request #21 from PaperMC/dev/3.0.0
[pull] main from PaperMC:dev/3.0.0
2 parents dbdb758 + c72a3ee commit 53d6995

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

proxy/src/main/java/com/velocitypowered/proxy/protocol/packet/chat/RateLimitedCommandHandler.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ protected RateLimitedCommandHandler(Player player, VelocityServer velocityServer
3838
public boolean handlePlayerCommand(MinecraftPacket packet) {
3939
if (packetClass().isInstance(packet)) {
4040
if (!velocityServer.getCommandRateLimiter().attempt(player.getUniqueId())) {
41-
if (failedAttempts++ >= velocityServer.getConfiguration().getKickAfterRateLimitedCommands()) {
41+
if (velocityServer.getConfiguration().isKickOnCommandRateLimit() && failedAttempts++ >= velocityServer.getConfiguration().getKickAfterRateLimitedCommands()) {
4242
player.disconnect(Component.translatable("velocity.kick.command-rate-limit"));
4343
}
4444

proxy/src/main/resources/default-velocity.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ enable-reuse-port = false
158158

159159
# How fast (in milliseconds) are clients allowed to send commands after the last command
160160
# By default this is 50ms (20 commands per second)
161-
command-rate-limit = 25
161+
command-rate-limit = 50
162162

163163
# Should we forward commands to the backend upon being rate limited?
164164
# This will forward the command to the server instead of processing it on the proxy.

0 commit comments

Comments
 (0)