diff --git a/crates/bevy_app/src/app.rs b/crates/bevy_app/src/app.rs index 04024d794a4d3..6fc2efb3e71cc 100644 --- a/crates/bevy_app/src/app.rs +++ b/crates/bevy_app/src/app.rs @@ -353,6 +353,10 @@ impl App { stage_label: impl StageLabel, system: impl IntoSystemDescriptor, ) -> &mut Self { + use std::any::TypeId; + if stage_label.type_id() == TypeId::of::() { + panic!("add systems to a startup stage using App::add_startup_system_to_stage"); + } self.schedule.add_system_to_stage(stage_label, system); self } @@ -383,6 +387,10 @@ impl App { stage_label: impl StageLabel, system_set: SystemSet, ) -> &mut Self { + use std::any::TypeId; + if stage_label.type_id() == TypeId::of::() { + panic!("add system sets to a startup stage using App::add_startup_system_set_to_stage"); + } self.schedule .add_system_set_to_stage(stage_label, system_set); self