@@ -6,6 +6,7 @@ use bevy::{
66 wireframe:: { WireframeConfig , WireframePlugin } ,
77 CascadeShadowConfigBuilder ,
88 } ,
9+ platform:: collections:: HashMap ,
910 prelude:: * ,
1011 render:: {
1112 mesh:: { Indices , VertexAttributeValues } ,
@@ -14,7 +15,6 @@ use bevy::{
1415 settings:: { RenderCreation , WgpuSettings } ,
1516 RenderPlugin ,
1617 } ,
17- utils:: HashMap ,
1818} ;
1919
2020use bevy_voxel_world:: {
@@ -172,7 +172,7 @@ fn main() {
172172 } ) ,
173173 ..default ( )
174174 } ) ,
175- WireframePlugin ,
175+ WireframePlugin :: default ( ) ,
176176 ) )
177177 . add_plugins ( VoxelWorldPlugin :: with_config ( MainWorld ) )
178178 . insert_resource ( WireframeConfig {
@@ -210,6 +210,7 @@ fn setup(mut commands: Commands) {
210210 commands. insert_resource ( AmbientLight {
211211 color : Color :: srgb ( 0.98 , 0.95 , 0.82 ) ,
212212 brightness : 100.0 ,
213+ affects_lightmapped_meshes : true ,
213214 } ) ;
214215}
215216
@@ -258,6 +259,7 @@ fn move_camera(
258259 time : Res < Time > ,
259260 mut cam_transform : Query < & mut Transform , With < VoxelWorldCamera < MainWorld > > > ,
260261) {
261- cam_transform. single_mut ( ) . translation . x += time. delta_secs ( ) * 5.0 ;
262- cam_transform. single_mut ( ) . translation . z += time. delta_secs ( ) * 10.0 ;
262+ let mut transform = cam_transform. single_mut ( ) . unwrap ( ) ;
263+ transform. translation . x += time. delta_secs ( ) * 5.0 ;
264+ transform. translation . z += time. delta_secs ( ) * 10.0 ;
263265}
0 commit comments