-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlib.rs
30 lines (25 loc) · 778 Bytes
/
lib.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
use bevy_app::prelude::*;
use crate::{ani::asset::AnimatedCursorAssetPlugin, cur::asset::StaticCursorAssetPlugin};
pub mod ani;
mod asset_image;
mod builder;
pub mod cur;
pub mod hotspot;
pub mod prelude {
#[doc(hidden)]
pub use crate::{
ani::asset::AnimatedCursor, builder::CustomCursorImageBuilder, cur::asset::StaticCursor,
hotspot::CursorHotspots, CursorAssetPlugin,
};
}
pub struct CursorAssetPlugin;
impl Plugin for CursorAssetPlugin {
fn build(&self, app: &mut App) {
if !app.is_plugin_added::<StaticCursorAssetPlugin>() {
app.add_plugins(StaticCursorAssetPlugin);
}
if !app.is_plugin_added::<AnimatedCursorAssetPlugin>() {
app.add_plugins(AnimatedCursorAssetPlugin);
}
}
}