diff --git a/pom.xml b/pom.xml index 34452cec6..9727aba3d 100644 --- a/pom.xml +++ b/pom.xml @@ -1,7 +1,7 @@ 4.0.0 proxy - 0.3.1 + 0.3.2 DragonProxy org.dragonet.proxy diff --git a/src/main/java/org/dragonet/proxy/data/entity/meta/EntityMetaData.java b/src/main/java/org/dragonet/proxy/data/entity/meta/EntityMetaData.java index 87dd458ac..78c990614 100644 --- a/src/main/java/org/dragonet/proxy/data/entity/meta/EntityMetaData.java +++ b/src/main/java/org/dragonet/proxy/data/entity/meta/EntityMetaData.java @@ -185,7 +185,7 @@ public static EntityMetaData createDefault() { data.setGenericFlag(Constants.DATA_FLAG_CAN_CLIMB, true); data.set(Constants.DATA_AIR, new ShortMeta((short) 400)); data.set(Constants.DATA_MAX_AIR, new ShortMeta((short) 400)); - data.set(Constants.DATA_NAMETAG, new ByteArrayMeta("")); + // data.set(Constants.DATA_NAMETAG, new ByteArrayMeta("")); data.set(Constants.DATA_LEAD_HOLDER_EID, new LongMeta(-1L)); data.set(Constants.DATA_SCALE, new FloatMeta(1.0f)); // data.set(Constants.DATA_BED_POSITION, new BlockPositionMeta(new BlockPosition(0, 0, 0))); diff --git a/src/main/java/org/dragonet/proxy/network/translator/EntityMetaTranslator.java b/src/main/java/org/dragonet/proxy/network/translator/EntityMetaTranslator.java index c9013c3a3..a51c3a509 100644 --- a/src/main/java/org/dragonet/proxy/network/translator/EntityMetaTranslator.java +++ b/src/main/java/org/dragonet/proxy/network/translator/EntityMetaTranslator.java @@ -64,7 +64,7 @@ public static EntityMetaData translateToPE(UpstreamSession session, EntityMetada peMeta.set(EntityMetaData.Constants.DATA_AIR, new ShortMeta(((Integer) m.getValue()).shortValue())); break; case 2:// Name tag - if ((String) m.getValue() != "") { + if (!m.getValue().equals("")) { peMeta.set(EntityMetaData.Constants.DATA_NAMETAG, new ByteArrayMeta((String) m.getValue())); } break; diff --git a/src/main/java/org/dragonet/proxy/network/translator/pc/PCPlayerPositionRotationPacketTranslator.java b/src/main/java/org/dragonet/proxy/network/translator/pc/PCPlayerPositionRotationPacketTranslator.java index 355158a9c..af5865789 100644 --- a/src/main/java/org/dragonet/proxy/network/translator/pc/PCPlayerPositionRotationPacketTranslator.java +++ b/src/main/java/org/dragonet/proxy/network/translator/pc/PCPlayerPositionRotationPacketTranslator.java @@ -199,7 +199,10 @@ public PEPacket[] translate(UpstreamSession session, ServerPlayerPositionRotatio pkAddPlayer.pitch = entity.pitch; pkAddPlayer.username = playerListEntry.getProfile().getName(); - pkAddPlayer.meta = EntityMetaTranslator.translateToPE(session, entity.pcMeta, EntityType.PLAYER); + // TODO: this does not work well yet + // pkAddPlayer.meta = EntityMetaTranslator.translateToPE(session, entity.pcMeta, EntityType.PLAYER); + + pkAddPlayer.meta = EntityMetaData.createDefault(); pkAddPlayer.meta.set(EntityMetaData.Constants.DATA_NAMETAG, new ByteArrayMeta(playerListEntry.getProfile().getName())); //hacky for now PlayerSkinPacket skin = new PlayerSkinPacket(entity.playerUniqueId); diff --git a/src/main/java/org/dragonet/proxy/utilities/Versioning.java b/src/main/java/org/dragonet/proxy/utilities/Versioning.java index 1b1d05c60..1fa5dedc9 100644 --- a/src/main/java/org/dragonet/proxy/utilities/Versioning.java +++ b/src/main/java/org/dragonet/proxy/utilities/Versioning.java @@ -16,7 +16,7 @@ public class Versioning { - public static final String RELEASE_VERSION = "0.3.1"; + public static final String RELEASE_VERSION = "0.3.2"; public static final String MINECRAFT_PC_VERSION = "1.12.2"; // public static final int MINECRAFT_PC_PROTOCOL = 47; // This is STRICT to MCPE binary's definition, DO NOT CHANGE