Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-09-17 00:33:47 +02:00
Enderchest and Invisible Players fix. (#506)
* Fix EnderChests not showing on legacy servers (Hypixel) Fix NPCs/Players sometimes being invisible * Remove unused import * Fix standard
Dieser Commit ist enthalten in:
Ursprung
f11bae0bf0
Commit
2355c503c9
@ -63,8 +63,9 @@ public class JavaPlayerListEntryTranslator extends PacketTranslator<ServerPlayer
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
session.getEntityCache().addPlayerEntity(playerEntity);
|
|
||||||
playerEntity.setPlayerList(true);
|
playerEntity.setPlayerList(true);
|
||||||
|
playerEntity.setValid(true);
|
||||||
|
session.getEntityCache().addPlayerEntity(playerEntity);
|
||||||
|
|
||||||
translate.getEntries().add(SkinUtils.buildCachedEntry(entry.getProfile(), playerEntity.getGeyserId()));
|
translate.getEntries().add(SkinUtils.buildCachedEntry(entry.getProfile(), playerEntity.getGeyserId()));
|
||||||
} else {
|
} else {
|
||||||
|
@ -3,7 +3,6 @@ package org.geysermc.connector.utils;
|
|||||||
import com.github.steveice10.mc.protocol.data.game.entity.metadata.Position;
|
import com.github.steveice10.mc.protocol.data.game.entity.metadata.Position;
|
||||||
import com.nukkitx.math.vector.Vector3i;
|
import com.nukkitx.math.vector.Vector3i;
|
||||||
import com.nukkitx.protocol.bedrock.packet.BlockEntityDataPacket;
|
import com.nukkitx.protocol.bedrock.packet.BlockEntityDataPacket;
|
||||||
|
|
||||||
import org.geysermc.connector.network.session.GeyserSession;
|
import org.geysermc.connector.network.session.GeyserSession;
|
||||||
import org.geysermc.connector.network.translators.Translators;
|
import org.geysermc.connector.network.translators.Translators;
|
||||||
import org.geysermc.connector.network.translators.world.block.entity.BlockEntityTranslator;
|
import org.geysermc.connector.network.translators.world.block.entity.BlockEntityTranslator;
|
||||||
@ -13,13 +12,16 @@ public class BlockEntityUtils {
|
|||||||
private static final BlockEntityTranslator EMPTY_TRANSLATOR = Translators.getBlockEntityTranslators().get("Empty");
|
private static final BlockEntityTranslator EMPTY_TRANSLATOR = Translators.getBlockEntityTranslators().get("Empty");
|
||||||
|
|
||||||
public static String getBedrockBlockEntityId(String id) {
|
public static String getBedrockBlockEntityId(String id) {
|
||||||
// This is the only exception when it comes to block entity ids
|
// These are the only exceptions when it comes to block entity ids
|
||||||
if (id.contains("piston_head"))
|
if (id.contains("piston_head"))
|
||||||
return "PistonArm";
|
return "PistonArm";
|
||||||
|
|
||||||
if (id.contains("trapped_chest"))
|
if (id.contains("trapped_chest"))
|
||||||
return "Chest";
|
return "Chest";
|
||||||
|
|
||||||
|
if (id.contains("EnderChest"))
|
||||||
|
return "EnderChest";
|
||||||
|
|
||||||
id = id.toLowerCase()
|
id = id.toLowerCase()
|
||||||
.replace("minecraft:", "")
|
.replace("minecraft:", "")
|
||||||
.replace("_", " ");
|
.replace("_", " ");
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren