More work for 1.14
This commit is contained in:
@@ -6,7 +6,7 @@ Subject: [PATCH] Use a Shared Random for Entities
|
||||
Reduces memory usage and provides ensures more randomness, Especially since a lot of garbage entity objects get created.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||
index c7f83d4343..cbbb243d1c 100644
|
||||
index 9ad8893943..5744760acc 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -0,0 +0,0 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -31,9 +31,9 @@ index c7f83d4343..cbbb243d1c 100644
|
||||
return tag.hasKey("Bukkit.updateLevel") && tag.getInt("Bukkit.updateLevel") >= level;
|
||||
}
|
||||
@@ -0,0 +0,0 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
this.length = 1.8F;
|
||||
this.aA = 1.0F;
|
||||
this.aB = 1.0F;
|
||||
this.B = Vec3D.a;
|
||||
this.av = 1.0F;
|
||||
this.aw = 1.0F;
|
||||
- this.random = new Random();
|
||||
+ this.random = SHARED_RANDOM; // Paper
|
||||
this.fireTicks = -this.getMaxFireTicks();
|
||||
|
||||
Reference in New Issue
Block a user