Crate ambient_api
source ·Expand description
The Ambient Rust API
Welcome to the Ambient Rust API! This API allows you to write logic for Ambient, the multiplayer game engine, in Rust.
The Ambient Book can be found here.
Ambient has first-class support for Rust. Please report any issues you encounter to the repository.
Re-exports
pub use ambient_cb as cb;
pub use ambient_editor_derive as editor_derive;
pub use ambient_element as element;
pub use ambient_ui as ui;
pub use anyhow;
pub use futures;
pub use glam;
pub use once_cell;
pub use rand;
Modules
- Animation functions
- Animation Element module
- Retrieval of assets and where to find them.
- audio
client
[Client-only] Audio functionality, including loading sounds and playback. - Helper functions for the camera.
- clipboard
client
[Client-only] Manipulating the operating system’s clipboard. - ECS-related functionality not directly related to entities.
- Manipulation, creation, removal, search and more for entities.
- Global functions and types for your convenience.
- http
server
[Server-only] HTTP-related functionality, including sending requests and receiving responses. - input
client
[Client-only] Input retrieval and manipulation. - material
client
[Client-only] Procedural material generation. - mesh
client
[Client-only] Procedural mesh generation. - Messaging to other packages and to the other side of the network boundary.
- Package-related functionality.
- physics
server
[Server-only] Physics-related functionality, including applying forces, changing physical properties, and more. - Player-specific functionality.
- sampler
client
[Client-only] Procedural sampler generation. - texture
client
[Client-only] Procedural texture generation. - window
client
[Client-only] Window-specific functionality.
Attribute Macros
- Makes your
main()
function accessible to the WASM host, and generates apackages
module that contain all packages visible to your package, including itself.