mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-30 16:19:03 +01:00
Remove the "Entity already removed" warning unless debug entities is on
This commit is contained in:
parent
b457bf2c57
commit
789ee71ee8
5 changed files with 13 additions and 16 deletions
|
@ -18,7 +18,7 @@ index 42c1c47c58..3606c78843 100644
|
||||||
if (bukkitEntity == null) {
|
if (bukkitEntity == null) {
|
||||||
bukkitEntity = CraftEntity.getEntity(world.getServer(), this);
|
bukkitEntity = CraftEntity.getEntity(world.getServer(), this);
|
||||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
index b76b8dbf5d..709f3e525c 100644
|
index 27278078e4..f6becaae43 100644
|
||||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||||
|
@ -33,10 +33,16 @@ index b76b8dbf5d..709f3e525c 100644
|
||||||
// Add env and gen to constructor
|
// Add env and gen to constructor
|
||||||
public WorldServer(MinecraftServer minecraftserver, IDataManager idatamanager, PersistentCollection persistentcollection, WorldData worlddata, DimensionManager dimensionmanager, MethodProfiler methodprofiler, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen) {
|
public WorldServer(MinecraftServer minecraftserver, IDataManager idatamanager, PersistentCollection persistentcollection, WorldData worlddata, DimensionManager dimensionmanager, MethodProfiler methodprofiler, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen) {
|
||||||
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||||
|
|
||||||
private boolean j(Entity entity) {
|
private boolean j(Entity entity) {
|
||||||
if (entity.dead) {
|
if (entity.dead) {
|
||||||
WorldServer.a.warn("Tried to add entity {} but it was marked as removed already: " + entity); // CraftBukkit // Paper
|
- // WorldServer.a.warn("Tried to add entity {} but it was marked as removed already", EntityTypes.getName(entity.P())); // CraftBukkit
|
||||||
+ if (DEBUG_ENTITIES) getAddToWorldStackTrace(entity).printStackTrace();
|
+ // Paper start
|
||||||
|
+ if (DEBUG_ENTITIES) {
|
||||||
|
+ new Throwable("Tried to add entity " + entity + " but it was marked as removed already").printStackTrace(); // CraftBukkit
|
||||||
|
+ getAddToWorldStackTrace(entity).printStackTrace();
|
||||||
|
+ }
|
||||||
|
+ // Paper end
|
||||||
return false;
|
return false;
|
||||||
} else {
|
} else {
|
||||||
UUID uuid = entity.getUniqueID();
|
UUID uuid = entity.getUniqueID();
|
||||||
|
|
|
@ -193,7 +193,7 @@ index ee2cdb897c..956eabd7dc 100644
|
||||||
public final List<TileEntity> tileEntityListTick = Lists.newArrayList();
|
public final List<TileEntity> tileEntityListTick = Lists.newArrayList();
|
||||||
private final List<TileEntity> c = Lists.newArrayList();
|
private final List<TileEntity> c = Lists.newArrayList();
|
||||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
index 709f3e525c..2692d0a1b6 100644
|
index f6becaae43..f7078ded5c 100644
|
||||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||||
|
|
|
@ -68,7 +68,7 @@ index aa94e399af..85570e4a5d 100644
|
||||||
this.b(entity);
|
this.b(entity);
|
||||||
});
|
});
|
||||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
index 2692d0a1b6..911d03c70b 100644
|
index f7078ded5c..9cba1822bf 100644
|
||||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||||
|
|
|
@ -8,18 +8,9 @@ These are a critical sign that somethin went wrong, and you've lost some data...
|
||||||
We should kind of know about these things you know.
|
We should kind of know about these things you know.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
index b939c31b23..b76b8dbf5d 100644
|
index b939c31b23..27278078e4 100644
|
||||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
|
||||||
|
|
||||||
private boolean j(Entity entity) {
|
|
||||||
if (entity.dead) {
|
|
||||||
- // WorldServer.a.warn("Tried to add entity {} but it was marked as removed already", EntityTypes.getName(entity.P())); // CraftBukkit
|
|
||||||
+ WorldServer.a.warn("Tried to add entity {} but it was marked as removed already: " + entity); // CraftBukkit // Paper
|
|
||||||
return false;
|
|
||||||
} else {
|
|
||||||
UUID uuid = entity.getUniqueID();
|
|
||||||
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||||
this.g.remove(entity1);
|
this.g.remove(entity1);
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -95,7 +95,7 @@ index e26405d341..23f390c221 100644
|
||||||
if (entityplayer != null && entityplayer.world == this.world && entityplayer.getId() != i) {
|
if (entityplayer != null && entityplayer.world == this.world && entityplayer.getId() != i) {
|
||||||
double d0 = (double) blockposition.getX() - entityplayer.locX;
|
double d0 = (double) blockposition.getX() - entityplayer.locX;
|
||||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
index 911d03c70b..f837e6c36c 100644
|
index 9cba1822bf..14905fceb0 100644
|
||||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
@@ -0,0 +0,0 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||||
|
|
Loading…
Reference in a new issue