geforkt von Mirrors/Paper
SPIGOT-709: Extend the block place limit to arm swings
Dieser Commit ist enthalten in:
Ursprung
98750ee399
Commit
68c9a6e117
@ -61,4 +61,24 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
}
|
||||
|
||||
flag = true;
|
||||
@@ -0,0 +0,0 @@ public class PlayerConnection implements PacketListenerPlayIn, IUpdatePlayerList
|
||||
public void a(PacketPlayInArmAnimation packetplayinarmanimation) {
|
||||
if (this.player.dead) return; // CraftBukkit
|
||||
PlayerConnectionUtils.ensureMainThread(packetplayinarmanimation, this, this.player.u());
|
||||
+ // Spigot start
|
||||
+ boolean throttled = false;
|
||||
+ if (lastPlace != -1 && packetplayinarmanimation.timestamp - lastPlace < 30 && packets++ >= 4) {
|
||||
+ throttled = true;
|
||||
+ } else if ( packetplayinarmanimation.timestamp - lastPlace >= 30 || lastPlace == -1 )
|
||||
+ {
|
||||
+ lastPlace = packetplayinarmanimation.timestamp;
|
||||
+ packets = 0;
|
||||
+ }
|
||||
+ if (throttled) {
|
||||
+ return;
|
||||
+ }
|
||||
+ // Spigot end
|
||||
this.player.z();
|
||||
// CraftBukkit start - Raytrace to look for 'rogue armswings'
|
||||
float f1 = this.player.pitch;
|
||||
--
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren