mirror of
https://github.com/italicsjenga/valence.git
synced 2024-12-23 14:31:30 +11:00
81044440dd
## Description Created a new CollisionShape struct for blocks (was previously an [f64; 6]). ## Test Plan Explain the steps necessary to test your changes. If you used a playground, include the code in the details below. Steps: 1. Run the following code <details> <summary>Playground</summary> ```rust use valence_block; fn main() { let shapes = valence_block::BlockState::STONE.collision_shapes(); println!("{:?}", shapes.collect::<Vec<_>>()); // [CollisionShape { min_x: 0.0, min_y: 0.0, min_z: 0.0, max_x: 1.0, max_y: 1.0, max_z: 1.0 }] let shapes = valence_block::BlockState::OAK_STAIRS.collision_shapes(); println!("{:?}", shapes.collect::<Vec<_>>()); // [CollisionShape { min_x: 0.0, min_y: 0.0, min_z: 0.0, max_x: 1.0, max_y: 0.5, max_z: 1.0 }, CollisionShape { min_x: 0.0, min_y: 0.5, min_z: 0.0, max_x: 1.0, max_y: 1.0, max_z: 0.5 }] } ``` </details>
20 lines
442 B
TOML
20 lines
442 B
TOML
[package]
|
|
name = "valence_block"
|
|
version.workspace = true
|
|
edition.workspace = true
|
|
|
|
[dependencies]
|
|
valence_core.workspace = true
|
|
anyhow.workspace = true
|
|
glam.workspace = true
|
|
|
|
[build-dependencies]
|
|
anyhow.workspace = true
|
|
heck.workspace = true
|
|
proc-macro2.workspace = true
|
|
quote.workspace = true
|
|
serde = { workspace = true, features = ["derive"] }
|
|
serde_json.workspace = true
|
|
valence_build_utils.workspace = true
|
|
valence_core.workspace = true
|