mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-20 07:57:34 +01:00
cab333b217
Don't send requests of every player was found in the global api cache SpigotMC/Spigot@841270ff1e Correctly set the response code for the cached lookups and return the ... SpigotMC/Spigot@f170b7899c Don't try and re-set the global api cache on reload SpigotMC/Spigot@b410a00a66 Use a compile time sneaky throw hack. SpigotMC/Spigot@508462b96b Fix a missed rename in WorldGenGroundBush SpigotMC/Spigot@0614d8fae9
32 lines
1.2 KiB
Diff
32 lines
1.2 KiB
Diff
From 4b235a101141d1b82eeca1187c71d3d9fb37a184 Mon Sep 17 00:00:00 2001
|
|
From: md_5 <md_5@live.com.au>
|
|
Date: Mon, 5 Aug 2013 20:17:20 +1000
|
|
Subject: [PATCH] Cap Minimum Player Speed
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
|
index 62d237d..6ac6520 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
|
@@ -1165,7 +1165,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
|
public void setFlySpeed(float value) {
|
|
validateSpeed(value);
|
|
EntityPlayer player = getHandle();
|
|
- player.abilities.flySpeed = value / 2f;
|
|
+ player.abilities.flySpeed = Math.max( value, 0.0001f ) / 2f; // Spigot
|
|
player.updateAbilities();
|
|
|
|
}
|
|
@@ -1173,7 +1173,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
|
public void setWalkSpeed(float value) {
|
|
validateSpeed(value);
|
|
EntityPlayer player = getHandle();
|
|
- player.abilities.walkSpeed = value / 2f;
|
|
+ player.abilities.walkSpeed = Math.max( value, 0.0001f ) / 2f; // Spigot
|
|
player.updateAbilities();
|
|
}
|
|
|
|
--
|
|
1.9.1
|
|
|