Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bevy_reflect: Register Hash for glam types #6736

Closed
MrGVSV opened this issue Nov 23, 2022 · 0 comments
Closed

bevy_reflect: Register Hash for glam types #6736

MrGVSV opened this issue Nov 23, 2022 · 0 comments
Labels
A-Reflection Runtime information about types C-Usability A targeted quality-of-life change that makes Bevy easier to use D-Trivial Nice and easy! A great choice to get started with Bevy

Comments

@MrGVSV
Copy link
Member

MrGVSV commented Nov 23, 2022

The integer vector types (e.g. IVec2, Uvec3, etc.) should register Hash with #[reflect(Hash)] so that they can be used with DynamicMap and serialization.

For example, here is UVec3's impl definition, and it does not include Hash in the list of traits to register:

impl_reflect_struct!(
#[reflect(Debug, PartialEq, Default)]
struct UVec3 {
x: u32,
y: u32,
z: u32,
}
);

The fix: Register Hash on all of glam's reflected integer vector types.

@MrGVSV MrGVSV added D-Trivial Nice and easy! A great choice to get started with Bevy C-Usability A targeted quality-of-life change that makes Bevy easier to use A-Reflection Runtime information about types labels Nov 23, 2022
@bors bors bot closed this as completed in 0d833a3 Nov 28, 2022
taiyoungjang pushed a commit to taiyoungjang/bevy that referenced this issue Dec 15, 2022
# Objective

- fixes bevyengine#6736

## Solution

- Register `Hash` on all of glam's reflected integer vector types.
alradish pushed a commit to alradish/bevy that referenced this issue Jan 22, 2023
# Objective

- fixes bevyengine#6736

## Solution

- Register `Hash` on all of glam's reflected integer vector types.
ItsDoot pushed a commit to ItsDoot/bevy that referenced this issue Feb 1, 2023
# Objective

- fixes bevyengine#6736

## Solution

- Register `Hash` on all of glam's reflected integer vector types.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Reflection Runtime information about types C-Usability A targeted quality-of-life change that makes Bevy easier to use D-Trivial Nice and easy! A great choice to get started with Bevy
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant