Paper 1.9
This commit is contained in:
@@ -1,37 +1,37 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Zach Brown <1254957+zachbr@users.noreply.github.com>
|
||||
Date: Sat, 7 Mar 2015 21:00:13 -0600
|
||||
Date: Tue, 1 Mar 2016 13:14:11 -0600
|
||||
Subject: [PATCH] Configurable fishing time ranges
|
||||
|
||||
|
||||
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
@@ -0,0 +0,0 @@ public class PaperWorldConfig {
|
||||
babyZombieMovementSpeed = getDouble("baby-zombie-movement-speed", 0.5D); // Player moves at 0.1F, for reference
|
||||
log("Baby zombies will move at the speed of " + babyZombieMovementSpeed);
|
||||
}
|
||||
+
|
||||
+ public int fishingMinTicks;
|
||||
+ public int fishingMaxTicks;
|
||||
+ private void fishingTickRange() {
|
||||
+ fishingMinTicks = getInt("fishing-time-range.MinimumTicks", 100);
|
||||
+ fishingMaxTicks = getInt("fishing-time-range.MaximumTicks", 900);
|
||||
+ log("Fishing time ranges are between " + fishingMinTicks +" and " + fishingMaxTicks + " ticks");
|
||||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityFishingHook.java b/src/main/java/net/minecraft/server/EntityFishingHook.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityFishingHook.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityFishingHook.java
|
||||
@@ -0,0 +0,0 @@ public class EntityFishingHook extends Entity {
|
||||
this.ax = MathHelper.nextInt(this.random, 20, 80);
|
||||
this.aw = MathHelper.nextInt(this.random, 20, 80);
|
||||
}
|
||||
} else {
|
||||
- this.aw = MathHelper.nextInt(this.random, 100, 900);
|
||||
+ this.aw = MathHelper.nextInt(this.random, this.world.paperSpigotConfig.fishingMinTicks, this.world.paperSpigotConfig.fishingMaxTicks); // PaperSpigot - Configurable fishing tick range
|
||||
this.aw -= EnchantmentManager.h(this.owner) * 20 * 5;
|
||||
- this.av = MathHelper.nextInt(this.random, 100, 900);
|
||||
+ this.av = MathHelper.nextInt(this.random, world.paperConfig.fishingMinTicks, world.paperConfig.fishingMaxTicks); // Paper - Configurable fishing time range
|
||||
this.av -= EnchantmentManager.g(this.owner) * 20 * 5;
|
||||
}
|
||||
}
|
||||
diff --git a/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java b/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
|
||||
+++ b/src/main/java/org/github/paperspigot/PaperSpigotWorldConfig.java
|
||||
@@ -0,0 +0,0 @@ public class PaperSpigotWorldConfig
|
||||
reedMaxHeight = getInt( "max-growth-height.reeds", 3 );
|
||||
log( "Max height for cactus growth " + cactusMaxHeight + ". Max height for reed growth " + reedMaxHeight );
|
||||
}
|
||||
+
|
||||
+ public int fishingMinTicks;
|
||||
+ public int fishingMaxTicks;
|
||||
+ private void fishingTickRange()
|
||||
+ {
|
||||
+ fishingMinTicks = getInt( "fishing-time-range.MinimumTicks", 100 );
|
||||
+ fishingMaxTicks = getInt( "fishing-time-range.MaximumTicks", 900 );
|
||||
+ }
|
||||
}
|
||||
--
|
||||
Reference in New Issue
Block a user