Plonq / bevy_rts_camera

RTS-style camera controls plugin for Bevy Engine
Apache License 2.0
53 stars 5 forks source link

Window grab mode isn't restored properly #20

Closed TeamDman closed 3 months ago

TeamDman commented 4 months ago

Setting the window grab mode to Confined a la


    app.add_plugins(DefaultPlugins.set(WindowPlugin {
        primary_window: Some(Window {
            cursor: Cursor {
                grab_mode: bevy::window::CursorGrabMode::Confined,
                ..default()
            },
            ..default()
        }),
        ..default()
    }));

storing it somewhere to be used during restoration instead of None should fix it

https://github.com/Plonq/bevy_rts_camera/blob/2136b0b7d8660c3b4964b6fc178d929b5f987cc0/src/controller.rs#L250 https://github.com/Plonq/bevy_rts_camera/blob/2136b0b7d8660c3b4964b6fc178d929b5f987cc0/src/controller.rs#L319

Plonq commented 3 months ago

Fixed in 0.7.1