aboutsummaryrefslogtreecommitdiff
path: root/azalea-client/src
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-client/src')
-rw-r--r--azalea-client/src/connect.rs35
1 files changed, 18 insertions, 17 deletions
diff --git a/azalea-client/src/connect.rs b/azalea-client/src/connect.rs
index 94c800f6..d3702874 100644
--- a/azalea-client/src/connect.rs
+++ b/azalea-client/src/connect.rs
@@ -2,6 +2,7 @@
use azalea_protocol::{
connect::HandshakeConnection,
packets::{
+ game::GamePacket,
handshake::client_intention_packet::ClientIntentionPacket,
login::{serverbound_hello_packet::ServerboundHelloPacket, LoginPacket},
ConnectionProtocol, PROTOCOL_VERSION,
@@ -56,23 +57,23 @@ pub async fn join_server(address: &ServerAddress) -> Result<(), String> {
};
// game
- loop {
- let packet_result = conn.read().await;
- match packet_result {
- Ok(packet) => match packet {
- GamePacket::ClientboundKeepAlivePacket(p) => {
- println!("Got keep alive packet {:?}", p.keep_alive_id);
- }
- GamePacket::ClientboundChatMessagePacket(p) => {
- println!("Got chat message packet {:?}", p.message);
- }
- _ => panic!("unhandled packet"),
- },
- Err(e) => {
- println!("Error: {:?}", e);
- }
- }
- }
+ // loop {
+ // let packet_result = conn.read().await;
+ // match packet_result {
+ // Ok(packet) => match packet {
+ // GamePacket::ClientboundKeepAlivePacket(p) => {
+ // println!("Got keep alive packet {:?}", p.keep_alive_id);
+ // }
+ // GamePacket::ClientboundChatMessagePacket(p) => {
+ // println!("Got chat message packet {:?}", p.message);
+ // }
+ // _ => panic!("unhandled packet"),
+ // },
+ // Err(e) => {
+ // println!("Error: {:?}", e);
+ // }
+ // }
+ // }
Ok(())
}