Make SystemIdMarker reflect-able (#15556)
Make `SystemIdMarker` reflect-able.
This commit is contained in:
parent
22af24aacf
commit
d6cfafdfd4
@ -1,3 +1,5 @@
|
|||||||
|
#[cfg(feature = "bevy_reflect")]
|
||||||
|
use crate::reflect::ReflectComponent;
|
||||||
use crate::{
|
use crate::{
|
||||||
self as bevy_ecs,
|
self as bevy_ecs,
|
||||||
bundle::Bundle,
|
bundle::Bundle,
|
||||||
@ -7,6 +9,8 @@ use crate::{
|
|||||||
world::{Command, World},
|
world::{Command, World},
|
||||||
};
|
};
|
||||||
use bevy_ecs_macros::{Component, Resource};
|
use bevy_ecs_macros::{Component, Resource};
|
||||||
|
#[cfg(feature = "bevy_reflect")]
|
||||||
|
use bevy_reflect::Reflect;
|
||||||
use core::marker::PhantomData;
|
use core::marker::PhantomData;
|
||||||
use thiserror::Error;
|
use thiserror::Error;
|
||||||
|
|
||||||
@ -19,6 +23,8 @@ struct RegisteredSystem<I, O> {
|
|||||||
|
|
||||||
/// Marker [`Component`](bevy_ecs::component::Component) for identifying [`SystemId`] [`Entity`]s.
|
/// Marker [`Component`](bevy_ecs::component::Component) for identifying [`SystemId`] [`Entity`]s.
|
||||||
#[derive(Component)]
|
#[derive(Component)]
|
||||||
|
#[cfg_attr(feature = "bevy_reflect", derive(Reflect))]
|
||||||
|
#[cfg_attr(feature = "bevy_reflect", reflect(Component))]
|
||||||
pub struct SystemIdMarker;
|
pub struct SystemIdMarker;
|
||||||
|
|
||||||
/// A system that has been removed from the registry.
|
/// A system that has been removed from the registry.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user