aboutsummaryrefslogtreecommitdiff
path: root/azalea-protocol/src/packets/game/clientbound_explode_packet.rs
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-protocol/src/packets/game/clientbound_explode_packet.rs')
-rwxr-xr-xazalea-protocol/src/packets/game/clientbound_explode_packet.rs15
1 files changed, 8 insertions, 7 deletions
diff --git a/azalea-protocol/src/packets/game/clientbound_explode_packet.rs b/azalea-protocol/src/packets/game/clientbound_explode_packet.rs
index 10a9e9a9..58070769 100755
--- a/azalea-protocol/src/packets/game/clientbound_explode_packet.rs
+++ b/azalea-protocol/src/packets/game/clientbound_explode_packet.rs
@@ -1,13 +1,14 @@
+use std::io::{Cursor, Write};
+
use azalea_buf::{BufReadError, McBufReadable, McBufVarReadable, McBufVarWritable, McBufWritable};
use azalea_core::BlockPos;
use azalea_protocol_macros::ClientboundGamePacket;
-use std::io::{Cursor, Write};
#[derive(Clone, Debug, PartialEq, ClientboundGamePacket)]
pub struct ClientboundExplodePacket {
- pub x: f32,
- pub y: f32,
- pub z: f32,
+ pub x: f64,
+ pub y: f64,
+ pub z: f64,
pub power: f32,
pub to_blow: Vec<BlockPos>,
pub knockback_x: f32,
@@ -17,9 +18,9 @@ pub struct ClientboundExplodePacket {
impl McBufReadable for ClientboundExplodePacket {
fn read_from(buf: &mut Cursor<&[u8]>) -> Result<Self, BufReadError> {
- let x = f32::read_from(buf)?;
- let y = f32::read_from(buf)?;
- let z = f32::read_from(buf)?;
+ let x = f64::read_from(buf)?;
+ let y = f64::read_from(buf)?;
+ let z = f64::read_from(buf)?;
let power = f32::read_from(buf)?;
let x_floor = x.floor() as i32;