Skip to content

Conversation

@ecoskey
Copy link
Contributor

@ecoskey ecoskey commented Nov 24, 2025

Objective

Solution

  • Add BuilderSystem, a wrapper which defers state construction until the first run
  • in addition to (...params).build_state(&mut world).build_system(|| {}), now you can also call (...params).build_system(|| {}) directly

Testing

  • compiles

(will add more tests while fixing review nits)

@ecoskey ecoskey requested a review from chescock November 24, 2025 00:33
@ecoskey ecoskey added A-ECS Entities, components, systems, and events S-Blocked This cannot move forward until something else changes D-Modest A "normal" level of difficulty; suitable for simple features or challenging fixes C-Feature A new feature, making something new possible labels Nov 24, 2025
@ecoskey ecoskey force-pushed the feature/builder_system branch 2 times, most recently from 167c983 to 83844ac Compare November 28, 2025 05:29
@ecoskey ecoskey added this to the 0.18 milestone Dec 1, 2025
@ecoskey ecoskey force-pushed the feature/builder_system branch 2 times, most recently from 8a9da46 to 2981ffa Compare December 9, 2025 02:11
@alice-i-cecile alice-i-cecile removed this from the 0.18 milestone Dec 10, 2025
@pablo-lua
Copy link
Contributor

Linked PR merged, no more blocks

@pablo-lua pablo-lua removed the S-Blocked This cannot move forward until something else changes label Dec 13, 2025
@pablo-lua
Copy link
Contributor

I'm certain this is useful, but is it possible to elaborate on some use cases or examples maybe? (Not necessarily on the code, more like in the pr description)

@ecoskey
Copy link
Contributor Author

ecoskey commented Dec 13, 2025

I'm certain this is useful, but is it possible to elaborate on some use cases or examples maybe? (Not necessarily on the code, more like in the pr description)

good point. It's mostly motivated by #21811, since it requires constructing systems in-place without world access. I'll update the pr description 🙂

@ecoskey ecoskey added the S-Needs-Review Needs reviewer attention (from anyone!) to move forward label Dec 13, 2025
@ecoskey ecoskey force-pushed the feature/builder_system branch from da64cf7 to b7a0e30 Compare December 14, 2025 02:43
@ecoskey ecoskey force-pushed the feature/builder_system branch from 9fb514b to c1adb04 Compare December 23, 2025 02:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-ECS Entities, components, systems, and events C-Feature A new feature, making something new possible D-Modest A "normal" level of difficulty; suitable for simple features or challenging fixes S-Needs-Review Needs reviewer attention (from anyone!) to move forward

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants