Function component_clone_via_reflect

Source
pub fn component_clone_via_reflect(
    source: &SourceComponent<'_>,
    ctx: &mut ComponentCloneCtx<'_, '_>,
)
Available on crate feature bevy_reflect only.
Expand description

Component clone handler function implemented using reflect. Can be set as clone handler for any registered component, but only reflected components will be cloned.

To clone a component using this handler, the following must be true:

If any of the conditions is not satisfied, the component will be skipped.

See EntityClonerBuilder for details.