Skip to content

Commit

Permalink
Remove development things
Browse files Browse the repository at this point in the history
  • Loading branch information
lukas0008 committed Aug 12, 2024
1 parent 7a59849 commit 435cd3b
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 25 deletions.
2 changes: 1 addition & 1 deletion pumpkin-world/src/chunk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ struct PaletteEntry {

#[derive(serde::Deserialize, Debug, Clone)]
struct ChunkSectionBlockStates {
data: Option<LongArray>, // TODO: see if you can use u32 here
data: Option<LongArray>,
palette: Vec<PaletteEntry>,
}

Expand Down
2 changes: 1 addition & 1 deletion pumpkin-world/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
pub mod chunk;
pub mod dimension;
pub const WORLD_HEIGHT: usize = 384;
pub const WORLD_Y_START_AT: i32 = -64; // TODO: make sure where it actually starts at (i think its at -64 but not sure)
pub const WORLD_Y_START_AT: i32 = -64;
pub const DIRECT_PALETTE_BITS: u32 = 15;
mod world;
mod block_registry;
22 changes: 0 additions & 22 deletions pumpkin-world/src/world.rs
Original file line number Diff line number Diff line change
Expand Up @@ -209,13 +209,6 @@ impl Level {
return ((old_chunk_x, old_chunk_z), Err(WorldError::ZlibError(err)))
}
}
// TODO: remove
// File::create_new(format!("./test-{}.{}.nbt", old_chunk_x, old_chunk_z))
// .await
// .unwrap()
// .write_all(&chunk_data)
// .await
// .unwrap();

(
(old_chunk_x, old_chunk_z),
Expand All @@ -228,18 +221,3 @@ impl Level {
.collect_vec()
}
}

#[test]
fn wawa() {
tokio::runtime::Runtime::new().unwrap().block_on(async {
Dimension::OverWorld
.into_level(
"C:\\Users\\lukza\\Desktop\\code\\rust\\vanilla_mc_server\\world"
.parse()
.unwrap(),
)
.read_chunk((0, 0))
.await
.unwrap();
});
}
Binary file removed pumpkin-world/test.nbt
Binary file not shown.
3 changes: 2 additions & 1 deletion pumpkin/src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,8 @@ impl Server {
}
let chunks = Dimension::OverWorld
.into_level(
"C:\\Users\\lukza\\Desktop\\code\\rust\\vanilla_mc_server\\world"
// TODO: load form config
"./world"
.parse()
.unwrap(),
)
Expand Down

0 comments on commit 435cd3b

Please sign in to comment.