Replies: 1 comment 2 replies
-
You can use thread local variables(each thread will get its own value to work with). I am using them for my pathfinding alogrithms and they work very well. https://doc.rust-lang.org/std/macro.thread_local.html (it's a general Rust feature) |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am iterating on parallel on some entities, i need some buffers to save some information.
For now i'm allocating and de-allocating memory each time. But i see that is something really stupid to do.
I don't need to re-allocate each time this buffer.
I need only to have a different buffer of memory for each thread and make a clear each time on it.
Is it possible to do something like that in Bevy?
Beta Was this translation helpful? Give feedback.
All reactions