Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to bevy 0.14 #33

Merged
merged 3 commits into from
Jul 6, 2024
Merged

Conversation

Vrixyz
Copy link
Contributor

@Vrixyz Vrixyz commented Jun 19, 2024

I'm not sure how to fix the "generate_docs" examples, which swaps out and in the App::world, which is now behind getter/setters.

@kristoff3r
Copy link
Contributor

You can do this (wanted to make a suggestion but I can't suggest over non-changed lines):

fn with_main_world_in_render_app<T>(app: &mut App, f: impl Fn(&mut SubApp) -> T) -> T {
    // temporarily add the app world to the render world as a resource
    let inserted_world = std::mem::take(app.world_mut());
    let mut render_main_world = bevy_render::MainWorld::default();
    *render_main_world = inserted_world;

    let render_app = app.sub_app_mut(RenderApp);
    render_app.world_mut().insert_resource(render_main_world);

    let ret = f(render_app);

    // move the app world back, as if nothing happened.
    let mut inserted_world = render_app
        .world_mut()
        .remove_resource::<bevy_render::MainWorld>()
        .unwrap();
    *app.world_mut() = std::mem::take(&mut *inserted_world);

    ret
}

Co-authored-by: Kristoffer Søholm <[email protected]>
@jakobhellermann
Copy link
Owner

I think something is wrong here, running make I get

lib/pathplan/shortest.c:339: triangulation failed
lib/pathplan/shortest.c:186: source point not in any triangle
Error: in routesplines, Pshortestpath failed
Warning: Unable to reclaim box space in spline routing for edge "node_System(8)" -> "node_System(45)". Something is probably seriously wrong.
Warning: Unable to reclaim box space in spline routing for edge "node_System(56)" -> "node_System(8)". Something is probably seriously wrong.
Warning: set_marker_node_Set(33) -> node_System(34): tail not inside tail cluster clusternode_Set(33)
Warning: set_marker_node_Set(36) -> set_marker_node_Set(37): head not inside head cluster clusternode_Set(37)
Warning: set_marker_node_Set(36) -> set_marker_node_Set(37): tail not inside tail cluster clusternode_Set(36)
Warning: set_marker_node_Set(37) -> set_marker_node_Set(38): head not inside head cluster clusternode_Set(38)
Warning: set_marker_node_Set(37) -> set_marker_node_Set(38): tail not inside tail cluster clusternode_Set(37)
Warning: set_marker_node_Set(38) -> set_marker_node_Set(39): head not inside head cluster clusternode_Set(39)
Warning: set_marker_node_Set(38) -> set_marker_node_Set(39): tail not inside tail cluster clusternode_Set(38)
Warning: node_System(43) -> set_marker_node_Set(49): head not inside head cluster clusternode_Set(49)
Error: lost node_System(29) node_System(32) edge
Error: segment [(-379.88, 3531.3),(-370.92,3540.3)] does not intersect box ll=(-413,2478),ur=(-289,3491.6)
dot: compound.c:68: boxIntersectf: Assertion `0' failed.
xargs: dot: terminated by signal 6
make: *** [Makefile:4: docs] Error 125

@jakobhellermann
Copy link
Owner

actually never mind that, looking through the code I don't see what would cause this, and it seems my setup is broken on main as well

@jakobhellermann jakobhellermann merged commit 840178d into jakobhellermann:main Jul 6, 2024
@Vrixyz Vrixyz deleted the bevy_0.14 branch July 11, 2024 18:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants