aboutsummaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
authorLemonzyy <lemonzy.pro@gmail.com>2022-11-14 12:04:23 +0100
committerLemonzyy <lemonzy.pro@gmail.com>2022-11-14 12:04:23 +0100
commitfc24c1b15071cf9fe44664bf9620d9dacd84154d (patch)
tree3e8313ba9a74de4fe31f9f0ab55dbf10c7ce17cd /src/lib.rs
parent82e2288afc91ac196295fa05796a925ed720c764 (diff)
Update Bevy to 0.9
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 180cae6..bfde4a6 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -1,3 +1,6 @@
+use bevy::prelude::{Deref, DerefMut, Resource};
+use tokio::runtime::Runtime;
+
pub const DEFAULT_MESSAGE_QUEUE_SIZE: usize = 150;
pub const DEFAULT_KILL_MESSAGE_QUEUE_SIZE: usize = 10;
pub const DEFAULT_KEEP_ALIVE_INTERVAL_S: u64 = 4;
@@ -7,6 +10,9 @@ pub mod server;
pub type ClientId = u64;
+#[derive(Resource, Deref, DerefMut)]
+pub(crate) struct AsyncRuntime(pub(crate) Runtime);
+
/// Enum with possibles errors that can occur in Bevy Quinnet
#[derive(thiserror::Error, Debug)]
pub enum QuinnetError {