I managed to get bevy-inspector-egui to play nicely with mouse interaction outside of the GUI, by checking CtxRef::wants_mouse_input() and disabling mouse interactivity for the camera, picker etc. Like this:
// system
fn data_ui(
egui: Res<bevy_egui::EguiContext>,
mut cameras: Query<&mut CameraRig>,
) {
for mut c in cameras.iter_mut() {
c.disable = egui.ctx.wants_mouse_input();
}
}
The problem is that bevy-inspector-egui does not re-export bevy_egui::EguiContext, so I have to import the crate manually. This means that there are potentially two versions of bevy_egui which can get out of sync.
To support this use-case, could this crate re-export bevy_egui::EguiContext ? I see it already re-exports bevy_egui::egui;
Hi!
I managed to get bevy-inspector-egui to play nicely with mouse interaction outside of the GUI, by checking
CtxRef::wants_mouse_input()
and disabling mouse interactivity for the camera, picker etc. Like this:The problem is that bevy-inspector-egui does not re-export
bevy_egui::EguiContext
, so I have to import the crate manually. This means that there are potentially two versions ofbevy_egui
which can get out of sync.To support this use-case, could this crate re-export
bevy_egui::EguiContext
? I see it already re-exportsbevy_egui::egui;
Thanks! Tom