diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index a567a1e..a0ae137 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -11,7 +11,7 @@ jobs: uses: actions-rs/toolchain@v1 with: # TODO: refactor toolchain version - toolchain: 1.55.0 + toolchain: 1.57.0 components: clippy, rustfmt default: true - name: Install dependencies @@ -49,7 +49,7 @@ jobs: - name: Install Rust uses: actions-rs/toolchain@v1 with: - toolchain: 1.55.0 + toolchain: 1.57.0 components: clippy, rustfmt default: true - name: Build binary @@ -83,7 +83,7 @@ jobs: - name: Install Rust uses: actions-rs/toolchain@v1 with: - toolchain: 1.55.0 + toolchain: 1.57.0 components: clippy, rustfmt default: true - name: Build binary @@ -128,7 +128,7 @@ jobs: uses: actions-rs/toolchain@v1 with: # TODO: refactor toolchain version - toolchain: 1.55.0 + toolchain: 1.57.0 components: clippy, rustfmt default: true - name: Install wasm-pack diff --git a/Cargo.toml b/Cargo.toml index 089e855..dd581be 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,7 +2,8 @@ name = "stevenarella" version = "0.0.1" authors = [ "Thinkofdeath ", "iceiix " ] -edition = "2018" +edition = "2021" +rust_version = "1.57" resolver = "2" description = "Multi-protocol multi-platform Minecraft-compatible client" repository = "https://github.com/iceiix/stevenarella" diff --git a/README.md b/README.md index 9d535c5..6baeb56 100644 --- a/README.md +++ b/README.md @@ -68,7 +68,7 @@ from [GitHub Actions](https://actions-badge.atrox.dev/iceiix/stevenarella/goto?r ## Dependencies -Requires Rust stable version 1.55.0 or newer. +Requires Rust stable version 1.57.0 or newer. **Debian/Ubuntu** diff --git a/blocks/Cargo.toml b/blocks/Cargo.toml index c14dac8..f9f1b4b 100644 --- a/blocks/Cargo.toml +++ b/blocks/Cargo.toml @@ -2,7 +2,7 @@ name = "steven_blocks" version = "0.0.1" authors = [ "Thinkofdeath " ] -edition = "2018" +edition = "2021" [dependencies] lazy_static = "1.4.0" diff --git a/protocol/Cargo.toml b/protocol/Cargo.toml index 548572c..ce52bef 100644 --- a/protocol/Cargo.toml +++ b/protocol/Cargo.toml @@ -2,7 +2,7 @@ name = "steven_protocol" version = "0.0.1" authors = [ "Thinkofdeath ", "iceiix " ] -edition = "2018" +edition = "2021" [dependencies] serde = "1.0.132" diff --git a/protocol/src/types/metadata.rs b/protocol/src/types/metadata.rs index 4020418..1c8cec9 100644 --- a/protocol/src/types/metadata.rs +++ b/protocol/src/types/metadata.rs @@ -656,6 +656,7 @@ impl Serializable for ParticleData { } #[derive(Debug)] +#[allow(dead_code)] pub struct VillagerData { villager_type: protocol::VarInt, profession: protocol::VarInt, diff --git a/resources/Cargo.toml b/resources/Cargo.toml index aea6370..2e5ad62 100644 --- a/resources/Cargo.toml +++ b/resources/Cargo.toml @@ -2,5 +2,5 @@ name = "steven_resources" version = "0.1.0" authors = [ "Thinkofdeath " ] -edition = "2018" +edition = "2021" build = "build.rs" diff --git a/shared/Cargo.toml b/shared/Cargo.toml index d79e8ae..2f766df 100644 --- a/shared/Cargo.toml +++ b/shared/Cargo.toml @@ -2,6 +2,6 @@ name = "steven_shared" version = "0.0.1" authors = [ "Thinkofdeath " ] -edition = "2018" +edition = "2021" [dependencies] diff --git a/src/main.rs b/src/main.rs index ce2a175..32770bb 100644 --- a/src/main.rs +++ b/src/main.rs @@ -540,9 +540,9 @@ fn main2() { fn tick_all( window: &winit::window::Window, game: &mut Game, - mut ui_container: &mut ui::Container, + ui_container: &mut ui::Container, last_frame: &mut Instant, - mut resui: &mut resources::ManagerUI, + resui: &mut resources::ManagerUI, last_resource_version: &mut usize, vsync: &mut bool, ) { @@ -558,7 +558,7 @@ fn tick_all( let version = { let try_res = game.resource_manager.try_write(); if let Ok(mut res) = try_res { - res.tick(&mut resui, &mut ui_container, delta); + res.tick(resui, ui_container, delta); res.version() } else { // TODO: why does game.resource_manager.write() sometimes deadlock? @@ -591,7 +591,7 @@ fn tick_all( .tick(&mut game.server.world, &mut game.renderer, version); game.screen_sys - .tick(delta, &mut game.renderer, &mut ui_container); + .tick(delta, &mut game.renderer, ui_container); /* TODO: open console for chat messages if let Some(received_chat_at) = game.server.received_chat_at { if Instant::now().duration_since(received_chat_at).as_secs() < 5 { @@ -603,7 +603,7 @@ fn tick_all( game.console .lock() .unwrap() - .tick(&mut ui_container, &game.renderer, delta, width); + .tick(ui_container, &game.renderer, delta, width); ui_container.tick(&mut game.renderer, delta, width, height); game.renderer.tick( &mut game.server.world, diff --git a/src/model/mod.rs b/src/model/mod.rs index e0a7099..0b2fa02 100644 --- a/src/model/mod.rs +++ b/src/model/mod.rs @@ -880,7 +880,9 @@ struct RawModel { uvlock: bool, weight: f64, + #[allow(dead_code)] display: HashMap>, + #[allow(dead_code)] builtin: BuiltinType, } @@ -899,6 +901,7 @@ impl RawModel { } #[derive(Debug)] +#[allow(dead_code)] struct ModelDisplay { rotation: [f64; 3], translation: [f64; 3], @@ -935,6 +938,7 @@ struct BlockFace { struct Model { faces: Vec, ambient_occlusion: bool, + #[allow(dead_code)] weight: f64, } @@ -945,6 +949,7 @@ struct Face { vertices: Vec, vertices_texture: Vec, indices: usize, + #[allow(dead_code)] shade: bool, tint_index: i32, } diff --git a/std_or_web/Cargo.toml b/std_or_web/Cargo.toml index c672204..2f589e1 100644 --- a/std_or_web/Cargo.toml +++ b/std_or_web/Cargo.toml @@ -2,7 +2,7 @@ name = "std_or_web" version = "0.0.1" authors = [ "iceiix " ] -edition = "2018" +edition = "2021" [dependencies] cfg-if = "1.0.0"