From 51033cd9638f971e7cc96770c0f6501a0d0f6978 Mon Sep 17 00:00:00 2001 From: Zach Brown <1254957+zachbr@users.noreply.github.com> Date: Sun, 22 Jun 2014 15:41:01 -0500 Subject: [PATCH] Configurable baby zombie movement speed --- ...figurable-baby-zombie-movement-speed.patch | 41 +++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 CraftBukkit-Patches/0158-Configurable-baby-zombie-movement-speed.patch diff --git a/CraftBukkit-Patches/0158-Configurable-baby-zombie-movement-speed.patch b/CraftBukkit-Patches/0158-Configurable-baby-zombie-movement-speed.patch new file mode 100644 index 0000000000..2cd5922704 --- /dev/null +++ b/CraftBukkit-Patches/0158-Configurable-baby-zombie-movement-speed.patch @@ -0,0 +1,41 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Zach Brown <1254957+zachbr@users.noreply.github.com> +Date: Wed, 21 May 2014 15:35:12 -0500 +Subject: [PATCH] Configurable baby zombie movement speed + + +diff --git a/src/main/java/net/minecraft/server/EntityZombie.java b/src/main/java/net/minecraft/server/EntityZombie.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/net/minecraft/server/EntityZombie.java ++++ b/src/main/java/net/minecraft/server/EntityZombie.java +@@ -0,0 +0,0 @@ import org.bukkit.event.entity.EntityCombustEvent; + import org.bukkit.event.entity.EntityTargetEvent; + //CraftBukkit end + ++import org.spigotmc.SpigotWorldConfig; // PaperSpigot ++ + public class EntityZombie extends EntityMonster { + + protected static final IAttribute bp = (new AttributeRanged("zombie.spawnReinforcements", 0.0D, 0.0D, 1.0D)).a("Spawn Reinforcements Chance"); + private static final UUID bq = UUID.fromString("B9766B59-9566-4402-BC1F-2EE2A276D836"); +- private static final AttributeModifier br = new AttributeModifier(bq, "Baby speed boost", 0.5D, 1); ++ private static final AttributeModifier br = new AttributeModifier(bq, "Baby speed boost", SpigotWorldConfig.babyZombieMovementSpeed, 1); // PaperSpigot - Make baby zombie movement speed configurable + private final PathfinderGoalBreakDoor bs = new PathfinderGoalBreakDoor(this); + private int bt; + private boolean bu = false; +diff --git a/src/main/java/org/spigotmc/SpigotWorldConfig.java b/src/main/java/org/spigotmc/SpigotWorldConfig.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/org/spigotmc/SpigotWorldConfig.java ++++ b/src/main/java/org/spigotmc/SpigotWorldConfig.java +@@ -0,0 +0,0 @@ public class SpigotWorldConfig + { + playerBlockingDamageMultiplier = getFloat( "player-blocking-damage-multiplier", 0.5F ); + } ++ ++ public static double babyZombieMovementSpeed; ++ private void setBabyZombieMovementSpeed() ++ { ++ babyZombieMovementSpeed = getDouble( "baby-zombie-movement-speed", 0.5D ); ++ } + } +-- \ No newline at end of file