mirror of
https://github.com/bevyengine/bevy
synced 2024-11-24 21:53:07 +00:00
d7cb781977
# Objective - Fixes #14655 ## Solution Rotation should happen first as this is more easier to conceptualize in the mind: We rotate around the coordinate origin `Vec3::ZERO` and then we just shift the geometry so that its center is exactly on the specified position ## Testing && Showcase Code: ```rust gizmos.grid( Vec3::ONE * 10.0, Quat::from_rotation_x(PI / 3. * 2.), UVec2::splat(20), Vec2::new(2., 2.), PURPLE, ); gizmos.sphere(Vec3::ONE * 10.0, Quat::default(), 1.0, PURPLE); ``` Before picture: ![image](https://github.com/user-attachments/assets/7fea2e71-e62b-4763-9f9f-7a1ecd630ada) After picture: ![image](https://github.com/user-attachments/assets/899dad64-010a-4e4b-86ae-53b85fef0bbc) ## Migration Guide - Users might have to double check their already existing calls to all the `grid` methods. It should be more intuitive now though. |
||
---|---|---|
.. | ||
macros | ||
src | ||
Cargo.toml | ||
README.md |