Skip to content

Commit

Permalink
Simplify plane mesh creation
Browse files Browse the repository at this point in the history
Co-authored-by: Rob Parrett <robparrett@gmail.com>
  • Loading branch information
tim-blackbird and rparrett committed Sep 9, 2023
1 parent c64e3e3 commit e2b4bd4
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions examples/3d/3d_viewport_to_world.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,7 @@ fn setup(
// plane
commands.spawn((
PbrBundle {
mesh: meshes.add(Mesh::from(shape::Plane {
size: 20.0,
subdivisions: 0,
})),
mesh: meshes.add(shape::Plane::from_size(20.).into()),
material: materials.add(Color::rgb(0.3, 0.5, 0.3).into()),
..default()
},
Expand Down

0 comments on commit e2b4bd4

Please sign in to comment.