Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-12-23 23:00:21 +01:00
Merge branch 'master' of https://github.com/GeyserMC/Geyser into server-inventory
Dieser Commit ist enthalten in:
Commit
93726f5818
@ -30,9 +30,9 @@
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.nukkitx.protocol</groupId>
|
||||
<groupId>com.github.CloudburstMC.Protocol</groupId>
|
||||
<artifactId>bedrock-v422</artifactId>
|
||||
<version>2.6.2-20210228.150048-4</version>
|
||||
<version>42da92f</version>
|
||||
<scope>compile</scope>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
|
@ -42,6 +42,7 @@ import com.github.steveice10.mc.protocol.packet.handshake.client.HandshakePacket
|
||||
import com.github.steveice10.mc.protocol.packet.ingame.client.player.ClientPlayerPositionPacket;
|
||||
import com.github.steveice10.mc.protocol.packet.ingame.client.player.ClientPlayerPositionRotationPacket;
|
||||
import com.github.steveice10.mc.protocol.packet.ingame.client.world.ClientTeleportConfirmPacket;
|
||||
import com.github.steveice10.mc.protocol.packet.login.client.LoginPluginResponsePacket;
|
||||
import com.github.steveice10.mc.protocol.packet.login.server.LoginSuccessPacket;
|
||||
import com.github.steveice10.packetlib.BuiltinFlags;
|
||||
import com.github.steveice10.packetlib.Client;
|
||||
@ -1047,7 +1048,7 @@ public class GeyserSession implements CommandSender {
|
||||
* @param packet the java edition packet from MCProtocolLib
|
||||
*/
|
||||
public void sendDownstreamPacket(Packet packet) {
|
||||
if (downstream != null && downstream.getSession() != null && protocol.getSubProtocol().equals(SubProtocol.GAME)) {
|
||||
if (downstream != null && downstream.getSession() != null && (protocol.getSubProtocol().equals(SubProtocol.GAME) || packet.getClass() == LoginPluginResponsePacket.class)) {
|
||||
downstream.getSession().send(packet);
|
||||
} else {
|
||||
connector.getLogger().debug("Tried to send downstream packet " + packet.getClass().getSimpleName() + " before connected to the server");
|
||||
|
@ -33,10 +33,11 @@ import com.github.steveice10.mc.protocol.packet.login.client.LoginPluginResponse
|
||||
import com.github.steveice10.mc.protocol.packet.login.server.LoginPluginRequestPacket;
|
||||
|
||||
@Translator(packet = LoginPluginRequestPacket.class)
|
||||
public class JavaLoginPluginMessageTranslator extends PacketTranslator<LoginPluginRequestPacket> {
|
||||
public class JavaLoginPluginRequestTranslator extends PacketTranslator<LoginPluginRequestPacket> {
|
||||
@Override
|
||||
public void translate(LoginPluginRequestPacket packet, GeyserSession session) {
|
||||
// A vanilla client doesn't know any PluginMessage in the Login state, so we don't know any either.
|
||||
// Note: Fabric Networking API v1 will not let the client log in without sending this
|
||||
session.sendDownstreamPacket(
|
||||
new LoginPluginResponsePacket(packet.getMessageId(), null)
|
||||
);
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren