From 80ae56c9e28454cb351b0ad3217adc2484e67107 Mon Sep 17 00:00:00 2001 From: LLLL Colonq Date: Mon, 17 Feb 2025 22:42:26 -0500 Subject: Add set_shader --- crates/throwshade/src/lib.rs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'crates/throwshade/src') diff --git a/crates/throwshade/src/lib.rs b/crates/throwshade/src/lib.rs index 531fd5f..c20b5fb 100644 --- a/crates/throwshade/src/lib.rs +++ b/crates/throwshade/src/lib.rs @@ -53,5 +53,11 @@ cfg_if::cfg_if! { pub async fn main_js() { teleia::run(480, 270, teleia::Options::NORESIZE, Game::new).await; } + #[wasm_bindgen] + pub async fn set_shader(s: &str) { + contextualize(|ctx, st, g: &mut Game| { + log::info!("set shader: {}", s); + }); + } } } -- cgit v1.2.3