https://github.com/foxzool/bevy_remote_asset
A Bevy plugin to load asset from web
https://github.com/foxzool/bevy_remote_asset
Last synced: 5 months ago
JSON representation
A Bevy plugin to load asset from web
- Host: GitHub
- URL: https://github.com/foxzool/bevy_remote_asset
- Owner: foxzool
- License: apache-2.0
- Created: 2023-08-27T03:01:24.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2023-08-30T02:24:57.000Z (almost 3 years ago)
- Last Synced: 2025-04-13T21:45:05.580Z (over 1 year ago)
- Language: Rust
- Homepage:
- Size: 10.7 KB
- Stars: 1
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE-APACHE
Awesome Lists containing this project
README
# bevy_remote_asset
[](https://crates.io/crates/bevy_remote_asset)
[](https://crates.io/crates/bevy_cronjob)
[](https://docs.rs/bevy_remote_asset)
[](https://github.com/Seldom-SE/seldom_pixel#license)
A Bevy plugin to load asset from web. It is based on the [ehttp](https://github.com/emilk/ehttp)
## Example
```rust
use bevy::prelude::*;
use bevy_remote_asset::RemoteAssetPlugin;
fn main() {
App::new()
.add_plugins(RemoteAssetPlugin)
.add_plugins(DefaultPlugins)
.add_systems(Startup, setup)
.run()
}
fn setup(mut commands: Commands, asset_server: Res) {
commands.spawn(Camera2dBundle::default());
commands.spawn(SpriteBundle {
texture: asset_server
.load("https://seeklogo.com/images/B/bevy-engine-logo-25F6DD58BF-seeklogo.com.png"),
..default()
});
}
```