mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 07:20:24 +01:00
Merge branch 'master' into pre/1.13
* master: Fix some false positive warnings printing that shouldnt be
This commit is contained in:
commit
22614dd064
3 changed files with 15 additions and 14 deletions
|
@ -1,4 +1,4 @@
|
|||
From 25ec29d10b01eb5fb85595ca4bb62552210c0778 Mon Sep 17 00:00:00 2001
|
||||
From 412b93e0d85701941c2de34ee4bf4ec1b1492ebe Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Sat, 21 Jul 2018 14:27:34 -0400
|
||||
Subject: [PATCH] Duplicate UUID Resolve Option
|
||||
|
@ -33,7 +33,7 @@ But for those who are ok with leaving this inconsistent behavior, you may use WA
|
|||
It is recommended you regenerate the entities, as these were legit entities, and deserve your love.
|
||||
|
||||
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
index 7bd7aa0d9..37315233e 100644
|
||||
index 7bd7aa0d94..37315233e1 100644
|
||||
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
@@ -430,4 +430,47 @@ public class PaperWorldConfig {
|
||||
|
@ -85,7 +85,7 @@ index 7bd7aa0d9..37315233e 100644
|
|||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
|
||||
index 1997cbdc6..724c1f572 100644
|
||||
index 1997cbdc65..117a3c517a 100644
|
||||
--- a/src/main/java/net/minecraft/server/Chunk.java
|
||||
+++ b/src/main/java/net/minecraft/server/Chunk.java
|
||||
@@ -1,5 +1,10 @@
|
||||
|
@ -115,7 +115,7 @@ index 1997cbdc6..724c1f572 100644
|
|||
}
|
||||
|
||||
int k = MathHelper.floor(entity.locY / 16.0D);
|
||||
@@ -865,6 +872,50 @@ public class Chunk implements IChunkAccess {
|
||||
@@ -865,6 +872,51 @@ public class Chunk implements IChunkAccess {
|
||||
|
||||
for (int j = 0; j < i; ++j) {
|
||||
List entityslice = aentityslice[j]; // Spigot
|
||||
|
@ -138,6 +138,7 @@ index 1997cbdc6..724c1f572 100644
|
|||
+ ) {
|
||||
+ logger.warn("[DUPE-UUID] Duplicate UUID found used by " + other + ", deleted entity " + entity + " because it was near the duplicate and likely an actual duplicate. See https://github.com/PaperMC/Paper/issues/1223 for discussion on what this is about.");
|
||||
+ entity.die();
|
||||
+ iterator.remove();
|
||||
+ continue;
|
||||
+ }
|
||||
+ if (other != null && !other.dead) {
|
||||
|
@ -167,7 +168,7 @@ index 1997cbdc6..724c1f572 100644
|
|||
this.world.a((Collection) entityslice);
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||
index ff22feee4..9ab635058 100644
|
||||
index ff22feee4d..9ab6350587 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -2724,6 +2724,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
|
@ -179,7 +180,7 @@ index ff22feee4..9ab635058 100644
|
|||
this.uniqueID = uuid;
|
||||
this.au = this.uniqueID.toString();
|
||||
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
||||
index fbca97322..064c31c03 100644
|
||||
index fbca973225..064c31c035 100644
|
||||
--- a/src/main/java/net/minecraft/server/World.java
|
||||
+++ b/src/main/java/net/minecraft/server/World.java
|
||||
@@ -72,7 +72,7 @@ public abstract class World implements GeneratorAccess, IIBlockAccess, AutoClose
|
||||
|
@ -192,7 +193,7 @@ index fbca97322..064c31c03 100644
|
|||
public final List<TileEntity> tileEntityListTick = 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
|
||||
index 817915a0c..6b5b2c825 100644
|
||||
index 817915a0c0..6b5b2c8258 100644
|
||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||
@@ -40,7 +40,7 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
From 93bbdd338d77b337b8fca1fe8d65bd45b8f35079 Mon Sep 17 00:00:00 2001
|
||||
From fdf7978f1bbee6b38b095758b84082876ece68a8 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Mon, 23 Jul 2018 22:44:23 -0400
|
||||
Subject: [PATCH] Add some Debug to Chunk Entity slices
|
||||
|
@ -9,7 +9,7 @@ This should hopefully avoid duplicate entities ever being created
|
|||
if the entity was to end up in 2 different chunk slices
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
|
||||
index 67e2158ca1..17f19219f2 100644
|
||||
index abdcf7745a..bd31a7dcab 100644
|
||||
--- a/src/main/java/net/minecraft/server/Chunk.java
|
||||
+++ b/src/main/java/net/minecraft/server/Chunk.java
|
||||
@@ -712,8 +712,34 @@ public class Chunk implements IChunkAccess {
|
||||
|
@ -54,7 +54,7 @@ index 67e2158ca1..17f19219f2 100644
|
|||
// Paper start
|
||||
- if (!this.entitySlices[i].remove(entity)) {
|
||||
- return;
|
||||
+ if (entitySlices[i] == entity.entitySlice) {
|
||||
+ if (entity.entitySlice == null || !entity.entitySlice.contains(entity) || entitySlices[i] == entity.entitySlice) {
|
||||
+ entity.entitySlice = null;
|
||||
+ } else {
|
||||
+ LogManager.getLogger().warn(entity + " was removed from a entitySlice we did not expect. Report this to https://github.com/PaperMC/Paper/issues/1302");
|
||||
|
@ -64,7 +64,7 @@ index 67e2158ca1..17f19219f2 100644
|
|||
this.markDirty();
|
||||
if (entity instanceof EntityItem) {
|
||||
itemCounts[i]--;
|
||||
@@ -979,6 +1009,7 @@ public class Chunk implements IChunkAccess {
|
||||
@@ -980,6 +1010,7 @@ public class Chunk implements IChunkAccess {
|
||||
}
|
||||
// Spigot End
|
||||
entity.setCurrentChunk(null); // Paper
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
From 82217d58cde2b4773bc1e220125a27af2975eb8b Mon Sep 17 00:00:00 2001
|
||||
From c2f6872c419c0bab2865724c87b1badc9ee59ef5 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Fri, 3 Aug 2018 22:47:46 -0400
|
||||
Subject: [PATCH] Entity add to world fixes
|
||||
|
@ -14,7 +14,7 @@ Fix this by differing entity add to world for all entities at the same time
|
|||
the original entity is dead, overwrite it as the logic does for unloaod queued entities.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
|
||||
index 17f19219f2..bb193966b8 100644
|
||||
index bd31a7dcab..8b80830933 100644
|
||||
--- a/src/main/java/net/minecraft/server/Chunk.java
|
||||
+++ b/src/main/java/net/minecraft/server/Chunk.java
|
||||
@@ -901,6 +901,7 @@ public class Chunk implements IChunkAccess {
|
||||
|
@ -25,7 +25,7 @@ index 17f19219f2..bb193966b8 100644
|
|||
|
||||
for (int j = 0; j < i; ++j) {
|
||||
List entityslice = aentityslice[j]; // Spigot
|
||||
@@ -947,10 +948,12 @@ public class Chunk implements IChunkAccess {
|
||||
@@ -948,10 +949,12 @@ public class Chunk implements IChunkAccess {
|
||||
thisChunk.put(entity.uniqueID, entity);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue