Archiviert
13
0
Dieses Repository wurde am 2024-12-25 archiviert. Du kannst Dateien ansehen und es klonen, aber nicht pushen oder Issues/Pull-Requests öffnen.
Paper-Old/nms-patches/EntitySlice.patch

30 Zeilen
1001 B
Diff

2015-05-25 12:37:24 +02:00
--- a/net/minecraft/server/EntitySlice.java
+++ b/net/minecraft/server/EntitySlice.java
2017-05-14 04:00:00 +02:00
@@ -13,7 +13,7 @@
public class EntitySlice<T> extends AbstractSet<T> {
- private static final Set<Class<?>> a = Sets.newHashSet();
+ private static final Set<Class<?>> a = Sets.newConcurrentHashSet(); // CraftBukkit
private final Map<Class<?>, List<T>> b = Maps.newHashMap();
private final Set<Class<?>> c = Sets.newIdentityHashSet();
private final Class<T> d;
2017-05-14 04:00:00 +02:00
@@ -41,7 +41,7 @@
Object object = iterator.next();
if (oclass.isAssignableFrom(object.getClass())) {
- this.a(object, oclass);
+ this.a((T) object, oclass);
}
}
2017-05-14 04:00:00 +02:00
@@ -78,7 +78,7 @@
List list = (List) this.b.get(oclass);
if (list == null) {
- this.b.put(oclass, Lists.newArrayList(new Object[] { t0}));
+ this.b.put(oclass, Lists.newArrayList(t0));
} else {
list.add(t0);
}