-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Resources as Components Tracking Issue #19731
Copy link
Copy link
Open
Labels
A-ECSEntities, components, systems, and eventsEntities, components, systems, and eventsC-Tracking-IssueAn issue that collects information about a broad development initiativeAn issue that collects information about a broad development initiativeX-BlessedHas a large architectural impact or tradeoffs, but the design has been endorsed by decision makersHas a large architectural impact or tradeoffs, but the design has been endorsed by decision makers
Metadata
Metadata
Assignees
Labels
A-ECSEntities, components, systems, and eventsEntities, components, systems, and eventsC-Tracking-IssueAn issue that collects information about a broad development initiativeAn issue that collects information about a broad development initiativeX-BlessedHas a large architectural impact or tradeoffs, but the design has been endorsed by decision makersHas a large architectural impact or tradeoffs, but the design has been endorsed by decision makers
This issue does not exist to argue the merits of Resources as Components, for some of the rationale we refer to this HackMD (this really should've been an RFC, huh?). This issue exists to track the progress on implementation and to reference in code when it is only partially working. If there are steps you feel like should be added, or if there are problems with this approach, please let me know.
Implementation Plan
This is a tracking issue for the Resources as Components. This outline is roughly copied from #17485.
world.iter_entities()andworld._iter_entities_mut()as part of that effort Deprecateiter_entitiesanditer_entities_mut#20260.iter_entities()Reviveiter_entities()when you only have immutableWorldaccess ❤️🩹 #22864.#[derive(Resource)]macro Store Resources as components on singleton entities #20934.ReflectResourceStore Resources as components on singleton entities #20934.clear_allto also remove non-send dataclear_all()clears all (non-send data) #22911 .resourcesfromAccess, Remove resources fromAccess#22910 .bevy_sceneRemove resources from scenes #22968 .component_scope/resource_scopeimplementation.