Derive FromReflect for Aabb (#7396)

# Objective

Add a `FromReflect` derive to the `Aabb` type, like all other math types, so we can reflect `Vec<Aabb>`.

## Solution

Just add it :)

---

## Changelog

### Added

- Implemented `FromReflect` for `Aabb`.
This commit is contained in:
Jerome Humbert 2023-01-30 03:54:52 +00:00
parent c673343e05
commit a61bf35c97

View File

@ -1,10 +1,10 @@
use bevy_ecs::{component::Component, prelude::Entity, reflect::ReflectComponent};
use bevy_math::{Mat4, Vec3, Vec3A, Vec4, Vec4Swizzles};
use bevy_reflect::Reflect;
use bevy_reflect::{FromReflect, Reflect};
use bevy_utils::HashMap;
/// An Axis-Aligned Bounding Box
#[derive(Component, Clone, Debug, Default, Reflect)]
#[derive(Component, Clone, Debug, Default, Reflect, FromReflect)]
#[reflect(Component)]
pub struct Aabb {
pub center: Vec3A,