From 536ef0ed82c451ec99dcc280934d161f02100339 Mon Sep 17 00:00:00 2001 From: Thierry Berger Date: Mon, 2 Dec 2024 16:55:18 +0100 Subject: [PATCH] fix annotations + uncomment ui example chooser --- bevy_rapier2d/examples/testbed2.rs | 7 +++---- bevy_rapier3d/examples/testbed3.rs | 7 +++---- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/bevy_rapier2d/examples/testbed2.rs b/bevy_rapier2d/examples/testbed2.rs index debfc0f0..8a433e22 100644 --- a/bevy_rapier2d/examples/testbed2.rs +++ b/bevy_rapier2d/examples/testbed2.rs @@ -13,7 +13,7 @@ mod player_movement2; mod rope_joint2; use bevy::prelude::*; -use bevy_egui::EguiPlugin; +use bevy_egui::{egui, EguiContexts, EguiPlugin}; use bevy_inspector_egui::quick::WorldInspectorPlugin; use bevy_rapier2d::prelude::*; @@ -224,7 +224,7 @@ fn main() { .add_systems( Update, ( - //ui_example_system, + ui_example_system, change_example.run_if(resource_changed::), ) .chain(), @@ -260,7 +260,7 @@ fn change_example( ) { next_state.set(examples_available.0[example_selected.0].state); } -/* + fn ui_example_system( mut contexts: EguiContexts, mut current_example: ResMut, @@ -284,4 +284,3 @@ fn ui_example_system( } }); } -*/ diff --git a/bevy_rapier3d/examples/testbed3.rs b/bevy_rapier3d/examples/testbed3.rs index 5358ca0a..9ef38786 100644 --- a/bevy_rapier3d/examples/testbed3.rs +++ b/bevy_rapier3d/examples/testbed3.rs @@ -12,7 +12,7 @@ mod ray_casting3; mod static_trimesh3; use bevy::prelude::*; -use bevy_egui::EguiPlugin; +use bevy_egui::{egui, EguiContexts, EguiPlugin}; use bevy_inspector_egui::quick::WorldInspectorPlugin; use bevy_rapier3d::prelude::*; @@ -209,7 +209,7 @@ fn main() { .add_systems( Update, ( - //ui_example_system, + ui_example_system, change_example.run_if(resource_changed::), ) .chain(), @@ -245,7 +245,7 @@ fn change_example( ) { next_state.set(examples_available.0[example_selected.0].state); } -/* + fn ui_example_system( mut contexts: EguiContexts, mut current_example: ResMut, @@ -269,4 +269,3 @@ fn ui_example_system( } }); } - */