diff --git a/README.md b/README.md index 92ef43a3..0c1d41a4 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # FastLogin +![A shield-shaped emblem with a bold lightning bolt on the left, resembling Minecraft blocks. To the right, "FastLogin" is written in teal, with the tagline: "Automatically detect and login premium Minecraft players"](https://github.com/user-attachments/assets/0788ef69-029b-465e-83a2-b8e7bccc6295 "FastLogin project logo.avif") + Checks if a Minecraft player has a paid account (premium). If so, they can skip offline authentication (auth plugins). So they don't need to enter passwords. This is also called auto login (auto-login). diff --git a/core/src/main/java/com/github/games647/fastlogin/core/message/LoginActionMessage.java b/core/src/main/java/com/github/games647/fastlogin/core/message/LoginActionMessage.java index 85bb24e5..c191cb2d 100644 --- a/core/src/main/java/com/github/games647/fastlogin/core/message/LoginActionMessage.java +++ b/core/src/main/java/com/github/games647/fastlogin/core/message/LoginActionMessage.java @@ -63,7 +63,7 @@ public class LoginActionMessage implements ChannelMessage { @Override public void readFrom(ByteArrayDataInput input) { - this.type = Type.values()[input.readInt()]; + this.type = Type.values()[input.readByte()]; this.playerName = input.readUTF(); @@ -75,7 +75,7 @@ public class LoginActionMessage implements ChannelMessage { @Override public void writeTo(ByteArrayDataOutput output) { - output.writeInt(type.ordinal()); + output.writeByte(type.ordinal()); //Data is sent through a random player. We have to tell the Bukkit version of this plugin the target output.writeUTF(playerName);