Skip to content

Commit da2ba8a

Browse files
authored
Add comment to example about coordinate system (#12991)
# Objective When learning about creating meshes in bevy using this example I couldn't tell which coordinate system bevy uses, which caused confusion and having to look it up else where. ## Solution Add a comment that says what coordinate system bevy uses.
1 parent 6003a31 commit da2ba8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/3d/generate_custom_mesh.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ fn create_cube_mesh() -> Mesh {
122122
Mesh::new(PrimitiveTopology::TriangleList, RenderAssetUsages::MAIN_WORLD | RenderAssetUsages::RENDER_WORLD)
123123
.with_inserted_attribute(
124124
Mesh::ATTRIBUTE_POSITION,
125-
// Each array is an [x, y, z] coordinate in local space.
125+
// Each array is an [x, y, z] coordinate in local space. Bevy uses a right-handed Y-up coordinate system.
126126
// Meshes always rotate around their local [0, 0, 0] when a rotation is applied to their Transform.
127127
// By centering our mesh around the origin, rotating the mesh preserves its center of mass.
128128
vec![

0 commit comments

Comments
 (0)