aboutsummaryrefslogtreecommitdiff
path: root/src/preload/events.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/preload/events.rs')
-rw-r--r--src/preload/events.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/preload/events.rs b/src/preload/events.rs
new file mode 100644
index 0000000..7167d73
--- /dev/null
+++ b/src/preload/events.rs
@@ -0,0 +1,12 @@
+use bevy::prelude::*;
+
+/// Event used to trigger preload callbacks after the asset file has been pre-processed to extract
+/// the payload
+#[derive(Debug, Event, Clone)]
+pub struct DirworldPreload {
+ /// Entity with the `[DirworldEntity]` component corresponding to the entity being preloaded
+ pub entity: Entity,
+ /// The data portion of the file after being pre-processed
+ pub data: Option<Vec<u8>>,
+}
+