Skip to content

Commit ec072d8

Browse files
reflect rendertarget (#22113)
RenderTarget was a Component that derived Reflect but did not Reflect Component as of this merge today: 67633b3 Without this fix, spawning a scene with a camera (such as from a Blender export) causes a panic: > scene contains the unregistered component `bevy_camera::camera::RenderTarget`. consider adding `#[reflect(Component)]` to your type
1 parent c18838f commit ec072d8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/bevy_camera/src/camera.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -811,7 +811,7 @@ impl Default for CameraOutputMode {
811811
/// The "target" that a [`Camera`] will render to. For example, this could be a `Window`
812812
/// swapchain or an [`Image`].
813813
#[derive(Component, Debug, Clone, Reflect, From)]
814-
#[reflect(Clone)]
814+
#[reflect(Clone, Component)]
815815
pub enum RenderTarget {
816816
/// Window to which the camera's view is rendered.
817817
Window(WindowRef),

0 commit comments

Comments
 (0)