Remove hardcore bit in JoinGamePacket

This commit is contained in:
themode 2020-10-07 22:26:26 +02:00
parent f811f1efef
commit ec33478cc3

View File

@ -23,15 +23,11 @@ public class JoinGamePacket implements ServerPacket {
@Override @Override
public void write(BinaryWriter writer) { public void write(BinaryWriter writer) {
int gameModeId = gameMode.getId();
if (gameMode.isHardcore())
gameModeId |= 8;
writer.writeInt(entityId); writer.writeInt(entityId);
writer.writeBoolean(MinecraftServer.isHardcoreLook()); writer.writeBoolean(MinecraftServer.isHardcoreLook());
writer.writeByte((byte) gameModeId); writer.writeByte(gameMode.getId());
//Previous Gamemode //Previous Gamemode
writer.writeByte((byte) gameModeId); writer.writeByte(gameMode.getId());
//array of worlds //array of worlds
writer.writeVarInt(1); writer.writeVarInt(1);