Closed simbleau closed 10 months ago
This would require a bevy_reflect
feature and optional dependency for matchbox_protocol
?
This would require a
bevy_reflect
feature and optional dependency formatchbox_protocol
?
Not sure, the docs for Reflect
vs. FromReflect
, etc. are not clear.
Foreign traits can't be implemented on foreign types. So has to go in bevy_reflect or matchbox_protocol.
What's your use case?
I'm using https://github.com/jakobhellermann/bevy-inspector-egui
It allows you to change the values of entities at runtime for debugging. I can't seem to implement Reflect for any type that encompasses a PeerId because you cannot derive Reflect unless all the fields also implement Reflect.
Is it perhaps possible to implement manually? Or #[reflect(ignore)]
those fields?
Having bevy as an optional dependency in a protocol-level crate seems a bit backwards to me. Especially since bevy has breaking releases so often.
Is it perhaps possible to implement manually? Or
#[reflect(ignore)]
those fields?Having bevy as an optional dependency in a protocol-level crate seems a bit backwards to me. Especially since bevy has breaking releases so often.
+1
Seems like maybe it will be possible to define it in bevy_matchbox in bevy 0.13: https://github.com/bevyengine/bevy/pull/6042
Seems like maybe it will be possible to define it in bevy_matchbox in bevy 0.13: bevyengine/bevy#6042
It seems so, but that PR has been bumped through several versions of bevy. If you want this functionality, definitely give that PR a review! It's not an easy one, but it would be really helpful =]
Let's get Reflect derived for PeerId.