Crate bevy_scene_hook

source ·
Expand description

Systems to insert components on loaded scenes.

Hooks allow you to run code on a scene after loading it. It provides an API similar to the bevy [SceneBundle], but with the ability to add components to scene entities once they are loaded.

This crate has two hook types:

  1. The very basic SceneHook, it has a hook function field. It will run once per entity within the scene, with the ability to add new components to the entity and read its existing components.
  2. The more advanced reload::Hook. Which works like SceneHook, but is aware of reload state, and also has access to the ECS &World and the root Entity of the scene it is running for.

The the respective documentation of SceneHook and reload::Hook for usage examples.

Modules§

  • Defines reloading Hooks and supporting system.

Structs§

Enums§

Functions§