You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following code allow to reproduce the issue. If I uncomment the add_stage_before line, the enter_system is not called anymore.
use bevy::prelude::*;#[derive(Clone)]pubenumAppState{Loading,}fnmain(){App::build().add_plugins(DefaultPlugins).add_resource(State::new(AppState::Loading))// uncomment the next line and 'enter_system' is not called// .add_stage_before(stage::UPDATE, "STAGE_1", StateStage::<AppState>::default()).add_stage_after(stage::UPDATE,"STAGE_2",StateStage::<AppState>::default().with_enter_stage(AppState::Loading,SystemStage::parallel().with_system(enter_system.system()),).with_update_stage(AppState::Loading,SystemStage::parallel().with_system(update_system.system()),)).run();}pubfnenter_system(){println!("enter_system");}pubfnupdate_system(){println!("update_system");}
What you expected to happen
The 'enter' should be called.
What actually happened
The 'enter' is not called.
The text was updated successfully, but these errors were encountered:
DJMcNab
added a commit
to DJMcNab/bevy
that referenced
this issue
Dec 21, 2020
use bevy::prelude::*;#[derive(Clone)]pubenumAppState{Loading,Loaded,}fnmain(){App::build().add_plugins(DefaultPlugins).add_resource(State::new(AppState::Loading))// uncomment the next line and 'enter_system' is not called// .add_stage_before(stage::UPDATE, "STAGE_1", StateStage::<AppState>::default()).add_stage_after(
stage::UPDATE,"STAGE_2",StateStage::<AppState>::default().with_enter_stage(AppState::Loading,SystemStage::single(enter_system.system()),).with_update_stage(AppState::Loading,SystemStage::single(update_system.system()),).with_exit_stage(AppState::Loading,SystemStage::single(exit_system.system())),).run();}pubfnenter_system(){println!("enter_system");}pubfnupdate_system(mutstate:ResMut<State<AppState>>){println!("update_system");
state.set_next(AppState::Loaded).unwrap();}pubfnexit_system(){println!("exit_system");}
Bevy version
bevy 0.4.0
Operating system & version
Windows 10
What you did
The following code allow to reproduce the issue. If I uncomment the
add_stage_before
line, theenter_system
is not called anymore.What you expected to happen
The 'enter' should be called.
What actually happened
The 'enter' is not called.
The text was updated successfully, but these errors were encountered: