Make SystemIdMarker reflect-able (#15556)

Make `SystemIdMarker` reflect-able.
This commit is contained in:
Liam Gallagher 2024-10-02 11:46:44 +13:00 committed by GitHub
parent 22af24aacf
commit d6cfafdfd4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,3 +1,5 @@
#[cfg(feature = "bevy_reflect")]
use crate::reflect::ReflectComponent;
use crate::{
self as bevy_ecs,
bundle::Bundle,
@ -7,6 +9,8 @@ use crate::{
world::{Command, World},
};
use bevy_ecs_macros::{Component, Resource};
#[cfg(feature = "bevy_reflect")]
use bevy_reflect::Reflect;
use core::marker::PhantomData;
use thiserror::Error;
@ -19,6 +23,8 @@ struct RegisteredSystem<I, O> {
/// Marker [`Component`](bevy_ecs::component::Component) for identifying [`SystemId`] [`Entity`]s.
#[derive(Component)]
#[cfg_attr(feature = "bevy_reflect", derive(Reflect))]
#[cfg_attr(feature = "bevy_reflect", reflect(Component))]
pub struct SystemIdMarker;
/// A system that has been removed from the registry.