From 2a82003d6a75522128dbe4495f38dfce30d9d2f5 Mon Sep 17 00:00:00 2001 From: DmitriyMX Date: Sun, 15 Apr 2018 11:17:36 +0300 Subject: [PATCH] add docs --- .../proto_125/netty/PacketHandler.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/src/main/java/mc/core/network/proto_125/netty/PacketHandler.java b/src/main/java/mc/core/network/proto_125/netty/PacketHandler.java index 47ef38a..15753d3 100644 --- a/src/main/java/mc/core/network/proto_125/netty/PacketHandler.java +++ b/src/main/java/mc/core/network/proto_125/netty/PacketHandler.java @@ -2,6 +2,25 @@ * DmitriyMX * 2018-04-10 */ + +/* +http://wiki.vg/index.php?title=Protocol_FAQ&oldid=76 +-- -- -- +C - Client +S - Server +-- -- -- +C -> S : Connects +C -> S : Sends handshake +S -> C : Sends handshake response +C -> S : After authenticating (if needed), sends the login packet +S -> C : Either kicks (invalid login) or sends a login response +S -> C : Sends pre-chunks and chunks and entities +S -> C : Sends spawn position +S -> C : Sends inventory [Need to verify this since inventory changed] (beta 1.1_02: looks like Window items with type=0, then a Set slot with window id = -1 and slot = -1) +S -> C : Tell the client they're ready to spawn by sending a position + look packet. Note: The stance and Y should be swapped when the server sends it to the client +C -> S : Sends a position + look packet to confirm the spawn position, with the stance and Y swapped back to the correct positions +*/ + package mc.core.network.proto_125.netty; import io.netty.channel.Channel;