Class BedrockSetPlayerGameTypeTranslator

java.lang.Object
org.geysermc.connector.network.translators.PacketTranslator<com.nukkitx.protocol.bedrock.packet.SetPlayerGameTypePacket>
org.geysermc.connector.network.translators.bedrock.entity.player.BedrockSetPlayerGameTypeTranslator

public class BedrockSetPlayerGameTypeTranslator extends PacketTranslator<com.nukkitx.protocol.bedrock.packet.SetPlayerGameTypePacket>
In vanilla Bedrock, if you have operator status, this sets the player's gamemode without confirmation from the server. Since we have a custom server option to request the gamemode, we just reset the gamemode and ignore this.
  • Constructor Details

    • BedrockSetPlayerGameTypeTranslator

      public BedrockSetPlayerGameTypeTranslator()
  • Method Details

    • translate

      public void translate(GeyserSession session, com.nukkitx.protocol.bedrock.packet.SetPlayerGameTypePacket packet)
      Specified by:
      translate in class PacketTranslator<com.nukkitx.protocol.bedrock.packet.SetPlayerGameTypePacket>