From 6379035b852f1b619565d27f5cee3b93042c2312 Mon Sep 17 00:00:00 2001 From: EightFactorial <29801334+EightFactorial@users.noreply.github.com> Date: Wed, 4 Dec 2024 16:31:22 -0800 Subject: Update Bevy and migrate to workspace dependencies and package attributes (#181) * Use workspace `Cargo.toml` for dependencies and package atributes * Fix a couple clippy warnings * Update bevy, update build script, move deps to workspace, and fix clippy warnings * Remove carrots from crate versions The default behavior is the same * Remove unused dependencies Compiles and all tests pass, so it should be fine * Update codegen to use `std::sync::LazyLock` instead of `once_cell::sync::Lazy` * Update Bevy to `0.15.0-rc.3` Surprisingly little needed to be changed * Update to bevy 0.15.0 * Fix leftover merge issues * Clarify the reason the swarm can't connect * Fix duplicate lint, remove `log` dependency --- codegen/lib/code/shapes.py | 3 ++- codegen/lib/code/tags.py | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'codegen/lib') diff --git a/codegen/lib/code/shapes.py b/codegen/lib/code/shapes.py index c4964fa6..a7dd58fb 100755 --- a/codegen/lib/code/shapes.py +++ b/codegen/lib/code/shapes.py @@ -119,10 +119,11 @@ def generate_block_shapes_code(blocks: dict, shapes: dict, block_states_report): #![allow(clippy::explicit_auto_deref)] #![allow(clippy::redundant_closure)] +use std::sync::LazyLock; + use super::VoxelShape; use crate::collision::{{self, Shapes}}; use azalea_block::*; -use std::sync::LazyLock; pub trait BlockWithShape {{ fn shape(&self) -> &'static VoxelShape; diff --git a/codegen/lib/code/tags.py b/codegen/lib/code/tags.py index d43b0071..51b41f50 100644 --- a/codegen/lib/code/tags.py +++ b/codegen/lib/code/tags.py @@ -8,8 +8,8 @@ def generate_tags(registries: dict, file_name: str, struct_name: str): generated = f'''// This file was generated by codegen/lib/code/tags.py, don't edit it manually! -use std::collections::HashSet; -use std::sync::LazyLock; +use std::{collections::HashSet, sync::LazyLock}; + use crate::{struct_name}; -- cgit v1.2.3