Skip to content

Commit caeff7e

Browse files
N40: Add Sparsey v0.10 (#1212)
1 parent 8cc031f commit caeff7e

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

content/news/040/index.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -335,6 +335,32 @@ commands
335335
[seq-actions-docs]: https://docs.rs/bevy-sequential-actions
336336
[bevy]: https://bevyengine.org
337337

338+
### [Sparsey] v0.10
339+
340+
[Sparsey] by [@LechintanTudor] is an Entity Component System focused on
341+
flexibility, conciseness and providing features exclusive to its sparse
342+
set-based implementation.
343+
344+
The latest release takes advantage of the newly added Generic Associated Types
345+
to provide a uniform interface for running systems, functions and closures that
346+
borrow data from World and Resources, via the "run", "run_locally" and
347+
"run_exclusive" functions.
348+
349+
Example:
350+
351+
```rust
352+
let heaviest = sparsey::run(&world, &resources, |weights: Comp<Weight>| {
353+
(&weights)
354+
.iter()
355+
.with_entity()
356+
.max_by_key(|(_entity, &weight)| weight)
357+
.map(|(entity, _weight)| entity)
358+
});
359+
```
360+
361+
[Sparsey]: https://github.com/LechintanTudor/sparsey
362+
[@LechintanTudor]: https://github.com/LechintanTudor
363+
338364
## Popular Workgroup Issues in Github
339365

340366
<!-- Up to 10 links to interesting issues -->

0 commit comments

Comments
 (0)