diff options
| author | mat <github@matdoes.dev> | 2021-12-10 00:54:58 -0600 |
|---|---|---|
| committer | mat <github@matdoes.dev> | 2021-12-10 00:54:58 -0600 |
| commit | be762fc5d37ba48386996afb4c5ba0c94aaf5883 (patch) | |
| tree | a7c96227c51e291e4e59eab7a66c6bc223973e06 /minecraft-protocol/src/connection.rs | |
| parent | f64750afdd9b18379f706df66c32806b6d21bbe8 (diff) | |
| download | azalea-drasl-be762fc5d37ba48386996afb4c5ba0c94aaf5883.tar.xz | |
rust is driving me insane
Diffstat (limited to 'minecraft-protocol/src/connection.rs')
| -rw-r--r-- | minecraft-protocol/src/connection.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/minecraft-protocol/src/connection.rs b/minecraft-protocol/src/connection.rs index e5784eb6..ba27cdad 100644 --- a/minecraft-protocol/src/connection.rs +++ b/minecraft-protocol/src/connection.rs @@ -35,7 +35,7 @@ impl Connection { .expect("Error enabling tcp_nodelay"); Ok(Connection { - state: ConnectionProtocol::Handshaking, + state: ConnectionProtocol::Handshake, flow: PacketFlow::ClientToServer, stream, }) @@ -80,7 +80,7 @@ impl Connection { // write the packet id let mut id_and_data_buf = vec![]; - mc_buf::write_varint(&mut id_and_data_buf, packet.get_id() as i32); + mc_buf::write_varint(&mut id_and_data_buf, packet.id() as i32); packet.write(&mut id_and_data_buf); // write the packet data |
