From feefeecec6c6050635b2c016452dfa1529575987 Mon Sep 17 00:00:00 2001 From: Kai Stevenson Date: Thu, 13 Aug 2026 01:56:09 -0700 Subject: big refactor for board --- src/ui.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/ui.rs') diff --git a/src/ui.rs b/src/ui.rs index e55aff1..9c8f6c3 100644 --- a/src/ui.rs +++ b/src/ui.rs @@ -9,6 +9,7 @@ pub fn draw_egui<'a>( diagnostics: &Diagnostics, input: &Input, ) { + puffin::profile_function!(); ui.heading("Config"); ui.add(egui::Slider::new(&mut config.brush_radius, 1..=100).text("Brush radius")); @@ -25,7 +26,7 @@ pub fn draw_egui<'a>( center: rect.center(), radius: rect.width() / 2.5, stroke: Stroke::NONE, - fill: Color32::from_rgb(material.color[0], material.color[1], material.color[2]), + fill: Color32::from_rgb(material.color.0, material.color.1, material.color.2), })); }) .show_ui(ui, |ui| { @@ -59,4 +60,8 @@ pub fn draw_egui<'a>( input .last_mouse_pos_on_board .map(|p| ui.label(format!("Mouse (board): x,y=({x}, {y})", x = p.0, y = p.1,))); + + input + .last_mouse_pos_on_board + .map(|p| ui.label(format!("Mouse (chunk): x,y=({x}, {y})", x = p.0, y = p.1,))); } -- cgit v1.3.1