Module prelude

Source
Expand description

The asset prelude.

This includes the most common types in this crate, re-exported for your convenience.

Structs§

AssetChanged
Filter that selects entities with an A for an asset that changed after the system last ran, where A is a component that implements AsAssetId.
AssetPlugin
Provides “asset” loading and processing functionality. An Asset is a “runtime value” that is loaded from an AssetSource, which can be something like a filesystem, a network, etc.
AssetServer
Loads and tracks the state of Asset values from a configured AssetReader. This can be used to kick off new asset loads and retrieve their current load states.
Assets
Stores Asset values identified by their AssetId.

Enums§

AssetEvent
Events that occur for a specific loaded Asset, such as “value changed” events and “dependency” events.
AssetId
A unique runtime-only identifier for an Asset. This is cheap to Copy/Clone and is not directly tied to the lifetime of the Asset. This means it can point to an Asset that no longer exists.
AssetMode
Controls whether or not assets are pre-processed before being loaded.
Handle
A handle to a specific Asset of type A. Handles act as abstract “references” to assets, whose data are stored in the Assets<A> resource, avoiding the need to store multiple copies of the same data.
UntypedHandle
An untyped variant of Handle, which internally stores the Asset type information at runtime as a TypeId instead of encoding it in the compile-time type. This allows handles across Asset types to be stored together and compared.

Traits§

Asset
Declares that this type is an asset, which can be loaded and managed by the AssetServer and stored in Assets collections.
AssetApp
Adds asset-related builder methods to App.
DirectAssetAccessExt
An extension trait for methods for working with assets directly from a World.

Derive Macros§

Asset