The debug renderer included in rapier2d/3d uses an outdated version of bevy.
This means we can't use the debug renderer with newer versions of Bevy.
This problem is especially unforgiving when trying to use some library that doesn't have optional dependency on the rapier features that pull bevy, like https://docs.rs/salva3d/latest/salva3d/
This problem also extends to bevy_rapier plugin that lists bevy = 0.11 in its own dependencies, but the optional debug-renderer feature pulls in rapier/debug-renderer which pulls in bevy=0.9 instead.
I started upgrading the code and have a branch that successfully compiles.
The only thing left is a panic involving the render app (DebugDrawLines plugin).
Here is the output of the error:
2023-10-23T16:43:14.689382Z INFO bevy_winit::system: Creating new window "Rapier: 3D demos" (0v0)
thread 'main' panicked at 'DrawFunctions<bevy_core_pipeline::core_3d::Opaque3d> must be added to the world as a resource before adding render commands to it
In the codebase, bevy_core_pipeline::core_3d::Opaque3d is aliased as dim::Phase. I tried adding the resource as it asks:
Above fails with same error. I also tried adding the resource to the World app (instead of the resource app).
I also tried removing the DebugLinesPlugin and all related plugins from the main file, but it still errors out with the above error. Also tried cargo clean and recompiling - same error.
The debug renderer included in rapier2d/3d uses an outdated version of bevy.
This means we can't use the debug renderer with newer versions of Bevy.
This problem is especially unforgiving when trying to use some library that doesn't have optional dependency on the rapier features that pull bevy, like https://docs.rs/salva3d/latest/salva3d/
This problem also extends to
bevy_rapier
plugin that listsbevy = 0.11
in its own dependencies, but the optionaldebug-renderer
feature pulls in rapier/debug-renderer which pulls inbevy=0.9
instead.I started upgrading the code and have a branch that successfully compiles.
The only thing left is a panic involving the render app (DebugDrawLines plugin).
Here is the output of the error:
In the codebase,
bevy_core_pipeline::core_3d::Opaque3d
is aliased asdim::Phase
. I tried adding the resource as it asks:Above fails with same error. I also tried adding the resource to the World app (instead of the resource app).
I also tried removing the
DebugLinesPlugin
and all related plugins from the main file, but it still errors out with the above error. Also triedcargo clean
and recompiling - same error.Here is the PR: https://github.com/dimforge/rapier/pull/540
Any idea how to fix this and finish the upgrade?