bevy
bevy copied to clipboard
Fix global wireframe behavior not being applied on new meshes
Objective
- Fixes #11782.
Solution
- Remove the run condition for
apply_global_wireframe_material, since it prevent detecting when meshes are added or theNoWireframemarker component is removed from an entity. Alternatively this could be done by using a run condition like "addedHandle<Mesh>or removedNoWireframeorWireframeConfigchanged" but this seems less clear to me than directly letting the queries onapply_global_wireframe_materialdo the filtering.
Putting in draft since there is some potential edge cases with NoWireframe I'd like to fix.
Edit: should now properly handle NoWireframe removal.
@alice-i-cecile may I suggest this PR for your merge train?