13
0
geforkt von Mirrors/Paper

fix recipe packet limiter (#9841)

Dieser Commit ist enthalten in:
caramel 2023-10-15 23:11:15 +09:00
Ursprung 6dea0a9f7c
Commit ee307c382a

Datei anzeigen

@ -28,7 +28,6 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
@Override
public void handlePlaceRecipe(ServerboundPlaceRecipePacket packet) {
+ PacketUtils.ensureRunningOnSameThread(packet, this, this.player.serverLevel());
+ // Paper start
+ if (!org.bukkit.Bukkit.isPrimaryThread()) {
+ if (this.recipeSpamPackets.addAndGet(io.papermc.paper.configuration.GlobalConfiguration.get().spamLimiter.recipeSpamIncrement) > io.papermc.paper.configuration.GlobalConfiguration.get().spamLimiter.recipeSpamLimit) {