Referenced mutable resource with AppState #4165
Unanswered
EvoTeamDevelop
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi! I am new to the Rust and Bevy and I have stuck on case.
I am trying to create a separate plugin for my application, which will be responsible for menu creation using egui.
I have created in such way that I pass Vector with Buttons structure, which have handler (I am passing it as mutable closure).
But the problem is that loose state_machine ownership, when I am trying to add 2nd handler.
As I got it, I need to use reference, but I am not sure if it is possible in Bevy to get reference for mutable resource with state machine.
Can somebody advice how to solve it? Thank you!
Beta Was this translation helpful? Give feedback.
All reactions