mirror of
https://github.com/storytold/storyteller-bevy.git
synced 2026-10-28 08:58:07 +00:00
POC scene serialization
This commit is contained in:
@@ -83,6 +83,14 @@ macro_rules! read_buffer {
|
||||
}
|
||||
}
|
||||
}};
|
||||
($buffer:ident, |_| $stmt:stmt) => {{
|
||||
let buffer = crate::wasm::get_buffer!($buffer);
|
||||
if let Some(lock) = buffer.try_lock() {
|
||||
if lock.borrow_mut().take().is_some() {
|
||||
$stmt
|
||||
}
|
||||
}
|
||||
}};
|
||||
}
|
||||
|
||||
pub(crate) use get_buffer;
|
||||
|
||||
Reference in New Issue
Block a user