Add BlockFace
This commit is contained in:
1 parent
91533c30df
commit
40fe40355f
8 files changed
+25
-7
No files matched your search
@@ -2,8 +2,8 @@ use num_traits::FromPrimitive;
|
||||
use pumpkin_entity::EntityId;
|
||||
use pumpkin_protocol::{
|
||||
client::play::{
|
||||
Animation, CEntityAnimation, CEntityVelocity, CHeadRot, CHurtAnimation,
|
||||
CSystemChatMessge, CUpdateEntityPos, CUpdateEntityPosRot, CUpdateEntityRot,
|
||||
Animation, CEntityAnimation, CEntityVelocity, CHeadRot, CHurtAnimation, CSystemChatMessge,
|
||||
CUpdateEntityPos, CUpdateEntityPosRot, CUpdateEntityRot,
|
||||
},
|
||||
server::play::{
|
||||
Action, SChatCommand, SChatMessage, SClientInformationPlay, SConfirmTeleport, SInteract,
|
||||
|
||||
@@ -339,7 +339,7 @@ impl Server {
|
||||
// TODO: do this in a world
|
||||
async fn spawn_test_chunk(client: &mut Client, distance: u32) {
|
||||
let inst = std::time::Instant::now();
|
||||
let (sender, mut chunk_receiver) = mpsc::channel(1024);
|
||||
let (sender, mut chunk_receiver) = mpsc::channel(distance as usize);
|
||||
tokio::spawn(async move {
|
||||
let level = Dimension::OverWorld.into_level(
|
||||
// TODO: load form config
|
||||
@@ -375,7 +375,7 @@ impl Server {
|
||||
}
|
||||
client.send_packet(&CChunkData(&chunk_data));
|
||||
}
|
||||
let t = std::time::Instant::now().duration_since(inst);
|
||||
let t = inst.elapsed();
|
||||
dbg!("DONE", t);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user