From 072346bb94dd99e60981bad934aa982f44fd2b19 Mon Sep 17 00:00:00 2001 From: Carter Anderson Date: Tue, 3 Dec 2019 22:12:33 -0800 Subject: [PATCH] fix variable name --- src/application.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/application.rs b/src/application.rs index ae67347221..e543cb5534 100644 --- a/src/application.rs +++ b/src/application.rs @@ -147,17 +147,17 @@ impl Application { let temp_buf_data = self.device .create_buffer_mapped(entities_count * size, wgpu::BufferUsage::COPY_SRC); - for ((entity, transform), slot) in entities.iter(&mut self.world) + for ((material, transform), slot) in entities.iter(&mut self.world) .zip(temp_buf_data.data.chunks_exact_mut(size)) { slot.copy_from_slice( MaterialUniforms { model: transform.0.into(), color: [ - entity.color.x as f32, - entity.color.y as f32, - entity.color.z as f32, - entity.color.w as f32, + material.color.x as f32, + material.color.y as f32, + material.color.z as f32, + material.color.w as f32, ], } .as_bytes(),