Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-09-08 22:02:50 +02:00
Fix spawn tracker mapping data check
Dieser Commit ist enthalten in:
Ursprung
cb073405b7
Commit
c358245c0b
@ -45,8 +45,6 @@ import com.viaversion.viaversion.data.entity.DimensionDataImpl;
|
|||||||
import com.viaversion.viaversion.rewriter.meta.MetaFilter;
|
import com.viaversion.viaversion.rewriter.meta.MetaFilter;
|
||||||
import com.viaversion.viaversion.rewriter.meta.MetaHandlerEvent;
|
import com.viaversion.viaversion.rewriter.meta.MetaHandlerEvent;
|
||||||
import com.viaversion.viaversion.rewriter.meta.MetaHandlerEventImpl;
|
import com.viaversion.viaversion.rewriter.meta.MetaHandlerEventImpl;
|
||||||
import org.checkerframework.checker.nullness.qual.Nullable;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Comparator;
|
import java.util.Comparator;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
@ -54,6 +52,7 @@ import java.util.List;
|
|||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
import org.checkerframework.checker.nullness.qual.Nullable;
|
||||||
|
|
||||||
public abstract class EntityRewriter<C extends ClientboundPacketType, T extends Protocol<C, ?, ?, ?>>
|
public abstract class EntityRewriter<C extends ClientboundPacketType, T extends Protocol<C, ?, ?, ?>>
|
||||||
extends RewriterBase<T> implements com.viaversion.viaversion.api.rewriter.EntityRewriter<T> {
|
extends RewriterBase<T> implements com.viaversion.viaversion.api.rewriter.EntityRewriter<T> {
|
||||||
@ -312,6 +311,10 @@ public abstract class EntityRewriter<C extends ClientboundPacketType, T extends
|
|||||||
map(Type.VAR_INT); // Data
|
map(Type.VAR_INT); // Data
|
||||||
handler(trackerHandler());
|
handler(trackerHandler());
|
||||||
handler(wrapper -> {
|
handler(wrapper -> {
|
||||||
|
if (protocol.getMappingData() == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
int entityId = wrapper.get(Type.VAR_INT, 0);
|
int entityId = wrapper.get(Type.VAR_INT, 0);
|
||||||
EntityType entityType = tracker(wrapper.user()).entityType(entityId);
|
EntityType entityType = tracker(wrapper.user()).entityType(entityId);
|
||||||
if (entityType == fallingBlockType) {
|
if (entityType == fallingBlockType) {
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren